Skip to content

TST: Fix test_ignore_sigint for pytest 8#15817

Closed
pllim wants to merge 2 commits intoastropy:mainfrom
pllim:fix-ignore-sigint-predeps
Closed

TST: Fix test_ignore_sigint for pytest 8#15817
pllim wants to merge 2 commits intoastropy:mainfrom
pllim:fix-ignore-sigint-predeps

Conversation

@pllim
Copy link
Copy Markdown
Member

@pllim pllim commented Jan 6, 2024

Description

Maybe because maybe you cannot use pytest.warns inside a function sent to pytest.raises anymore in some cases; not sure. After merge, devdeps that was failing in #15809 no longer fails (though it still picks up pytest 8.0rc) but predeps still fails. This is all very confusing.

Locally, I had to install [all] and [test_all], pytest 8.0rc, and run pytest astropy/io/fits/tests/ --remote-data for the error to show up. Running pytest astropy/io/fits/tests/test_util.py -k test_ignore_sigint --remote-data does not trigger the error.

I guess this is what happens when we play with fire that is called os.kill.

This is a direct follow-up of #15809 to fix #15807 .

  • By checking this box, the PR author has requested that maintainers do NOT use the "Squash and Merge" button. Maintainers should respect this when possible; however, the final decision is at the discretion of the maintainer that merges the PR.

because maybe you cannot use pytest.warns inside a function sent to pytest.raises anymore
in some cases; not sure.
@pllim pllim added this to the v6.0.1 milestone Jan 6, 2024
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jan 6, 2024

Thank you for your contribution to Astropy! 🌌 This checklist is meant to remind the package maintainers who will review this pull request of some common things to look for.

  • Do the proposed changes actually accomplish desired goals?
  • Do the proposed changes follow the Astropy coding guidelines?
  • Are tests added/updated as required? If so, do they follow the Astropy testing guidelines?
  • Are docs added/updated as required? If so, do they follow the Astropy documentation guidelines?
  • Is rebase and/or squash necessary? If so, please provide the author with appropriate instructions. Also see instructions for rebase and squash.
  • Did the CI pass? If no, are the failures related? If you need to run daily and weekly cron jobs as part of the PR, please apply the "Extra CI" label. Codestyle issues can be fixed by the bot.
  • Is a change log needed? If yes, did the change log check pass? If no, add the "no-changelog-entry-needed" label. If this is a manual backport, use the "skip-changelog-checks" label unless special changelog handling is necessary.
  • Is this a big PR that makes a "What's new?" entry worthwhile and if so, is (1) a "what's new" entry included in this PR and (2) the "whatsnew-needed" label applied?
  • Is a milestone set? Milestone must be set but we cannot check for it on Actions; do not let the green checkmark fool you.
  • At the time of adding the milestone, if the milestone set requires a backport to release branch(es), apply the appropriate "backport-X.Y.x" label(s) before merge.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Jan 6, 2024

👋 Thank you for your draft pull request! Do you know that you can use [ci skip] or [skip ci] in your commit messages to skip running continuous integration tests until you are ready?

@pllim
Copy link
Copy Markdown
Member Author

pllim commented Jan 6, 2024

pre-commit.ci autofix

@pllim
Copy link
Copy Markdown
Member Author

pllim commented Jan 6, 2024

Hmm @nstarman or @eerovaher or @WilliamJamieson , do you know why linkcheck job is failing with typing related warnings?

modeling/bounding_box.py:docstring of astropy.modeling.bounding_box.CompoundBoundingBox.validate:1: WARNING: py:class reference target not found: Self

modeling/bounding_box.py:docstring of astropy.modeling.bounding_box.ModelBoundingBox.validate:1: WARNING: py:class reference target not found: Self

@pllim
Copy link
Copy Markdown
Member Author

pllim commented Jan 6, 2024

Wow, this is crazy. If I fix it for the predeps job, other jobs fail but not all of them.

@pllim pllim closed this Jan 6, 2024
@pllim pllim deleted the fix-ignore-sigint-predeps branch January 6, 2024 03:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Test failures in predeps job (pre-release dependencies)

1 participant