Repository navigation
Fix missing default during pytest_configure - #5435
josePhoenix wants to merge 2 commits into
Conversation
|
@josePhoenix From what I've seen are the test failures not because of this PR. So you don't need to worry (yet) about these. I think someone (just semi-randomly pinging @pllim) will restart those tests soon. |
|
Restarted. |
|
Travis passed but coverage decreased 0.4% (probably unrelated to this PR but due to #5418). |
|
It is kinda a bug fix but not a very visible one. Does this need change log? |
|
👍 from me too - thanks @josePhoenix! I think it should get a changelog entry, though, as @josePhoenix's case is not necessarily that unique. @josePhoenix, can you add this to the 1.2.2 section of (aside: @pllim or maybe @astrofrog - do you know if there's any way I can add files with github's new "edit a PR branch" feature? If there was I could just add the changelog entry myself... I thought someone mentioned this on the astropy-dev thread but don't see a way to do it?) |
|
@eteq apparently you can now commit directly to this PR branch. So that's how you add the entry. I tried that feature only once but it failed miserably because i had to rebase and it won't let me push forcefully. |
|
Cheers! I'd forgotten I needed to do that. |
|
Oh, whoa, that did work! Of course now the changelog conflicts... but still. Neat! @josePhoenix - one other question before I try to merge this fixing the conflicts: can you confirm making this change get py.test working in your package? Or is there something else that needs changing? (Which it would make sense to bundle in with this). |
|
Turns out, there are a bunch more unchecked exception cases in this plugin. This PR needs more attention than I can give it at the moment, I'm afraid. There are also calls to deprecated methods in pytest that need to be updated. |
|
Yes, these other exceptions are a known issue (see #5277). I was under the impression that you only needed this one-liner change to make your own package using Astropy template work. |
|
By "unchecked exception cases" I mean cases where the code could raise an exception and the exception is not checked. For example, the one I fixed in the first commit in this PR. It turns out that there are a lot more of these in |
|
I've opened #5446 instead, as the docs are currently misleading. Fixing |
|
Addendum: in an offline chat w/ @josePhoenix it looks like this might actually be due to a change to how options are set as defaults. So this might be a new aspect of #5277 after all: options now may have to specify defaults, which would be why this change was needed if you try to invoke it from py.test 3.x ... |
|
Why, pytest? Why?! 😱 |
Addresses #5402.