-
-
Notifications
You must be signed in to change notification settings - Fork 601
Turn some doctests in ell_rational_field.py
into long tests
#38824
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
Conversation
Documentation preview for this PR (built with commit aeb512f; changes) is ready! 🎉 |
probably a side-effect of #38461 |
I can't reproduce the timeout of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, thanks
sagemathgh-38824: Turn some doctests in `ell_rational_field.py` into long tests Fixes sagemath#38813 Some of the doctests in `ell_rational_field.py` ran into RuntimeErrors and couldn't compute generators in time, causing tests to fail. Turning them into long tests (which is necessary since they have to run longer in some cases) fixes that problem. Also added some missing spaces. URL: sagemath#38824 Reported by: Sebastian A. Spindler Reviewer(s): Frédéric Chapoton, Sebastian A. Spindler
sagemathgh-39567: Make test deterministic to fix CI Apparently the test is introduced in sagemath#38824 and it's basically copied from another test below that is marked `random` ``` sage: E = EllipticCurve([-127^2,0]) sage: E.gens(use_database=False, algorithm='pari', pari_effort=4) # long time, random [(611429153205013185025/9492121848205441 : 15118836457596902442737698070880/924793900700594415341761 : 1)] ``` I don't know why this one isn't marked `# random` but I choose to keep checking the output but does it more carefully. Basically it has rank 1 so the generator is determined up to `± 1` and modulo torsion, so we just need to check `l[0] - a` or `l[0] + a` is in torsion. It's not clear why the test starts failing now. Maybe it's just random after all. ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> - [ ] The title is concise and informative. - [ ] The description explains in detail what this PR is about. - [ ] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation and checked the documentation preview. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - sagemath#12345: short description why this is a dependency --> <!-- - sagemath#34567: ... --> URL: sagemath#39567 Reported by: user202729 Reviewer(s): Frédéric Chapoton
sagemathgh-39567: Make test deterministic to fix CI Apparently the test is introduced in sagemath#38824 and it's basically copied from another test below that is marked `random` ``` sage: E = EllipticCurve([-127^2,0]) sage: E.gens(use_database=False, algorithm='pari', pari_effort=4) # long time, random [(611429153205013185025/9492121848205441 : 15118836457596902442737698070880/924793900700594415341761 : 1)] ``` I don't know why this one isn't marked `# random` but I choose to keep checking the output but does it more carefully. Basically it has rank 1 so the generator is determined up to `± 1` and modulo torsion, so we just need to check `l[0] - a` or `l[0] + a` is in torsion. It's not clear why the test starts failing now. Maybe it's just random after all. ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> - [ ] The title is concise and informative. - [ ] The description explains in detail what this PR is about. - [ ] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation and checked the documentation preview. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - sagemath#12345: short description why this is a dependency --> <!-- - sagemath#34567: ... --> URL: sagemath#39567 Reported by: user202729 Reviewer(s): Frédéric Chapoton
sagemathgh-39567: Make test deterministic to fix CI Apparently the test is introduced in sagemath#38824 and it's basically copied from another test below that is marked `random` ``` sage: E = EllipticCurve([-127^2,0]) sage: E.gens(use_database=False, algorithm='pari', pari_effort=4) # long time, random [(611429153205013185025/9492121848205441 : 15118836457596902442737698070880/924793900700594415341761 : 1)] ``` I don't know why this one isn't marked `# random` but I choose to keep checking the output but does it more carefully. Basically it has rank 1 so the generator is determined up to `± 1` and modulo torsion, so we just need to check `l[0] - a` or `l[0] + a` is in torsion. It's not clear why the test starts failing now. Maybe it's just random after all. ### 📝 Checklist <!-- Put an `x` in all the boxes that apply. --> - [ ] The title is concise and informative. - [ ] The description explains in detail what this PR is about. - [ ] I have linked a relevant issue or discussion. - [ ] I have created tests covering the changes. - [ ] I have updated the documentation and checked the documentation preview. ### ⌛ Dependencies <!-- List all open PRs that this PR logically depends on. For example, --> <!-- - sagemath#12345: short description why this is a dependency --> <!-- - sagemath#34567: ... --> URL: sagemath#39567 Reported by: user202729 Reviewer(s): Frédéric Chapoton
Fixes #38813
Some of the doctests in
ell_rational_field.py
ran into RuntimeErrors and couldn't compute generators in time, causing tests to fail. Turning them into long tests (which is necessary since they have to run longer in some cases) fixes that problem.Also added some missing spaces.