Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Undo pytest<6 pin #455

Merged
merged 1 commit into from
Aug 3, 2020
Merged

Undo pytest<6 pin #455

merged 1 commit into from
Aug 3, 2020

Conversation

pllim
Copy link
Member

@pllim pllim commented Jul 31, 2020

Undo #453 because pytest-doctestplus 0.8.0 is out on PyPI.

@pllim
Copy link
Member Author

pllim commented Jul 31, 2020

Appveyor failures are unrelated.

@pllim
Copy link
Member Author

pllim commented Jul 31, 2020

astropy/astropy#10620 using pytest 6.0.1 and pytest-doctestplus 0.8.0 looks promising. There are some warnings but they don't turn into failures.

=============================== warnings summary ===============================
/home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148
  /home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148: PytestConfigWarning: Unknown config ini key: asdf_schema_root
  
    self._warn_or_fail_if_strict("Unknown config ini key: {}\n".format(key))
/home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148
  /home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148: PytestConfigWarning: Unknown config ini key: asdf_schema_tests_enabled
  
    self._warn_or_fail_if_strict("Unknown config ini key: {}\n".format(key))
/home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148
  /home/travis/build/astropy/astropy/.tox/py37-test/lib/python3.7/site-packages/_pytest/config/__init__.py:1148: PytestConfigWarning: Unknown config ini key: qt_no_exception_capture
  
    self._warn_or_fail_if_strict("Unknown config ini key: {}\n".format(key))
-- Docs: https://docs.pytest.org/en/stable/warnings.html
=== 13461 passed, 1027 skipped, 104 xfailed, 3 warnings in 257.86s (0:04:17) ===

@pllim
Copy link
Member Author

pllim commented Jul 31, 2020

p.s. As far as I can dig into pytest code, there is no simple way to turn off those warnings. I tried ignoring them in setup.cfg but that didn't work. We can either just live with it or ask @nicoddemus

@nicoddemus
Copy link

Hey!

Hmm those warnings mean that those options are not not registered and are being ignored. asdf_schema_root and asdf_schema_tests_enabled I don't recognize, but qt_no_exception_capture is from pytest-qt and should not be appearing if pytest-qt is installed.

Can I see the pytest header from that run? (I did take a quick look at the AppVeyor build but couldn't find it)

I think those filters can be ignored by using the filterwarnings option, but because they are configuration warnings that might not work (the reason is complicated, but mainly because the warnings plugin might not have registered at that point yet to capture/filter out the warning).

@bsipocz
Copy link
Member

bsipocz commented Jul 31, 2020

@nicoddemus - ignore appveyor, we're ditching it, it's failing with unrelated stuff.

@pllim
Copy link
Member Author

pllim commented Jul 31, 2020

Hello, @nicoddemus ! Thanks for the reply. Yes, those are set in https://github.com/astropy/astropy/blob/ab3577da3377e9c488a294755e641496be57f235/setup.cfg#L92 (starting from that line) and the example log is at https://travis-ci.org/github/astropy/astropy/jobs/713837307

  • The asdf stuff is optional, so it is not always installed for all the jobs.
  • We don't do qt but we added it because someone complained that the test broke without the setting when they have pytest-qt installed.

@nicoddemus
Copy link

I see, thanks @bsipocz and @pllim.

@pllim can you please add this line to your filterwarnings list

  ignore:Unknown config ini key

But as I said, that might not work (we really should look into fixing that).

@pllim
Copy link
Member Author

pllim commented Aug 3, 2020

Re: #455 (comment) -- Did not work. Same warnings still show.

@nicoddemus
Copy link

Yeah unfortunately as I suspected, the cause is due to pytest-dev/pytest#6681. Not much that can be done at this time, I'm afraid. 😕

@pllim
Copy link
Member Author

pllim commented Aug 3, 2020

Thank you very much for your help, @nicoddemus ! I've added a comment to that pytest issue.

@pllim
Copy link
Member Author

pllim commented Aug 3, 2020

For ci-helpers maintainers, please merge this.

@bsipocz bsipocz merged commit 6dd7fdd into astropy:master Aug 3, 2020
@pllim pllim deleted the undo-pytest-6-pin branch August 3, 2020 17:40
@nicoddemus
Copy link

Hey folks,

FTR, pytest-dev/pytest#7649 should make that warning possible to filter out. 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants