Skip to content

test_never_update is flaky #18246

Closed

Description

@QuLogic

Bug report

So far, I've only seen this on macOS CI. test_never_update crashes and thus fails.

On #18235, I had to restart macOS on Azure 4 times to pass. In #18243 it failed on Travis and Azure, but only macOS.

cc @richardsheridan

Matplotlib version

  • Operating system: macOS, mostly
  • Matplotlib version: master-ish
  • Matplotlib backend (print(matplotlib.get_backend())): TkAgg
  • Python version: 3.7.8 / 3.8.5

Activity

  1. added this to the v3.4.0 milestone on Aug 13, 2020
  2. QuLogic commented on Aug 13, 2020

    @QuLogic
    MemberAuthor

    Here is the log from #18235; if you click Show Previous Attempts on the side bar, you can find logs from the crashing runs. Apparently someone else also restarted it 3 more times, too.

  3. richardsheridan commented on Aug 13, 2020

    @richardsheridan
    Contributor

    I don't have access to macOS to test so I might not be much help. Re-running the full test suite on my local machine, I did notice that the test leaves two windows hanging around after. This doesn't happen on a partial run of test_backends_interactive.py, so there might be some spooky interaction at a distance. Perhaps we could try running the test in a subprocess?

  4. tacaswell commented on Aug 14, 2020

    @tacaswell
    Member

    Thanks for looking at this @richardsheridan !

  5. richardsheridan commented on Aug 15, 2020

    @richardsheridan
    Contributor

    Learned two things from these PRs:

    1. Subprocess isolation works to keep the test worker from crashing at least. In the stderr of those tests on macos it seems it can't find configure_subplots even though it's clearly part of the declared interface.
    2. Taking a little care to destroy tkinter when you're done is enough to fix the weird long-lived windows when I run the full test suite locally, but it doesn't fix the crashes on macos. Unless we're prepared to go full cpython test suite on it, I'd say the subprocess strategy is the way to go.

    I think we'll need someone with a mac and some experience with _macosx.m to debug missing attribute problem.

  6. QuLogic commented on Aug 15, 2020

    @QuLogic
    MemberAuthor

    You should not be seeing NavigationToolbar2Mac if you are running with TkAgg. The subprocess is using the default backend, so it's not testing what you think it's testing. Set 'MPLBACKEND': 'TkAgg' in env to force it to use TkAgg.

  7. dopplershift commented on Aug 15, 2020

    @dopplershift
    Contributor

    On my mac, running 10.15.6 and Python 3.8, I can't get test_never_update to fail. I also can't get test_interactive_backend[toolbar2-macosx] ever to pass...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions