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

io.misc.asdf: skip modeling doctest that requires removed features in asdf (v5.3.x) #14797

Merged
merged 1 commit into from
May 9, 2023

Conversation

braingram
Copy link
Contributor

@braingram braingram commented May 9, 2023

Description

2 modeling doctests (like the following):

>>> from asdf import AsdfFile
>>> from astropy.modeling import models
>>> rotation = models.Rotation2D(angle=23.7)
>>> f = AsdfFile()
>>> f.tree['model'] = rotation
>>> f.write_to('rotation.asdf')

should have been skipped in #14516

It has since been updated in main: #14668

and requires a manual backport to fix this failing test as described:
#14795

@github-actions
Copy link

github-actions bot commented May 9, 2023

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 "When to rebase and squash commits".
  • 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

github-actions bot commented May 9, 2023

👋 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?

@braingram
Copy link
Contributor Author

It appears I do not have the ability to set labels so could not follow
Apply "skip-basebranch-check" label **before** you open the PR!
@pllim Does this need to be applied before the PR is brought out of draft or is it already too late for this PR?

@WilliamJamieson WilliamJamieson added skip-basebranch-check Skip base branch check for direct backports no-changelog-entry-needed labels May 9, 2023
@WilliamJamieson
Copy link
Contributor

Close-reopen for the skip-basebranch-check to become effective.

@pllim pllim added this to the v5.3 milestone May 9, 2023
@@ -942,7 +942,7 @@ format. This can be useful in many contexts, one of which is the implementation

Serializing a model to disk is possible by assigning the object to ``AsdfFile.tree``:

.. doctest-requires:: asdf
.. doctest-requires:: asdf<3.0.0.dev
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this is supported. Would be nice if it does though. Let's see...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

modeling passed: https://github.com/astropy/astropy/actions/runs/4929120049/jobs/8808352373?pr=14797#step:10:1646

However coodinates index.rst failed:

346 .. doctest-remote-data::
347 
348     >>> EarthLocation.of_address('1002 Holy Grail Court, St. Louis, MO')  # doctest: +FLOAT_CMP
349     <EarthLocation (-26769.86528679, -4997007.71191864, 3950273.57633915) m>
350     >>> EarthLocation.of_address('Danbury, CT')  # doctest: +FLOAT_CMP
Expected:
    <EarthLocation (1362610.66896362, -4590755.48088484, 4198817.69912853) m>
Got:
    <EarthLocation (1364606.6451165, -4593292.9428273, 4195415.93695139) m>

/home/runner/work/astropy/astropy/docs/coordinates/index.rst:350: DocTestFailure

Is this a known issue?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing 5.2.2 I get the 'Got' result:

In [22]: import astropy.coordinates

In [23]: astropy.coordinates.EarthLocation.of_address('Danbury, CT')
Out[23]: <EarthLocation (1364606.6451165, -4593292.9428273, 4195415.93695139) m>

In [24]: astropy.__version__
Out[24]: '5.2.2'

Did someone move Danbury?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The EarthLocation look-up been flaky lately, just ignore it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@saimn and @bsipocz , I didn't know we can specify version comparison in .. doctest-requires::. When did this happen? 😸

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure(I'm afk), is it not listed in the changelog?

Copy link
Member

@pllim pllim May 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't comb through the change log. Maybe I should. The README didn't mention.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you mind opening a quick PR then? We should be more diligent with requiring the readme updates with the enhancements, but afaik we're not insistent enough

This comment was marked as resolved.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@braingram braingram marked this pull request as ready for review May 9, 2023 18:33
@braingram braingram requested a review from a team as a code owner May 9, 2023 18:33
@pllim
Copy link
Member

pllim commented May 9, 2023

@braingram , are you able to open similar PRs to v5.2.x and v5.0.x ? 🙏

@braingram
Copy link
Contributor Author

@braingram , are you able to open similar PRs to v5.2.x and v5.0.x ? 🙏

@pllim I opened similar PRs against v5.0.x and v5.2.x. As I am unable to set labels they will require a similar set of steps as @WilliamJamieson performed on this PR.

@pllim pllim changed the title io.misc.asdf: skip modeling doctest that requires removed features in asdf io.misc.asdf: skip modeling doctest that requires removed features in asdf (v5.3.x) May 9, 2023
Copy link
Member

@pllim pllim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@pllim pllim merged commit f1de7ff into astropy:v5.3.x May 9, 2023
41 of 45 checks passed
@braingram braingram deleted the skip_modeling_asdf_docest branch May 9, 2023 19:36
pllim added a commit that referenced this pull request May 9, 2023
pllim added a commit that referenced this pull request May 9, 2023
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.

None yet

4 participants