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

some ruff auto-fixes in schemes + error links in doc #36870

Merged
merged 1 commit into from
Dec 26, 2023

Conversation

fchapoton
Copy link
Contributor

Some fixes made by ruff in the schemes folder (codes C4, UP02, UP009)

plus adding manually some links to errors in the doc

📝 Checklist

  • The title is concise, informative, and self-explanatory.
  • The description explains in detail what this PR is about.

Copy link
Member

@mkoeppe mkoeppe left a comment

Choose a reason for hiding this comment

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

Otherwise LGTM

@mkoeppe
Copy link
Member

mkoeppe commented Dec 13, 2023

https://github.com/sagemath/sage/actions/runs/7195279189/job/19597658375?pr=36870#step:14:73

File "src/sage/schemes/curves/affine_curve.py", line 1840, in sage.schemes.curves.affine_curve.AffinePlaneCurve_field.braid_monodromy
Failed example:
    C.braid_monodromy()               # optional - sirocco
Exception raised:
    Traceback (most recent call last):
      File "/sage/src/sage/doctest/forker.py", line 709, in _run
        self.compile_and_execute(example, compiler, test.globs)
      File "/sage/src/sage/doctest/forker.py", line 1144, in compile_and_execute
        exec(compiled, globs)
      File "<doctest sage.schemes.curves.affine_curve.AffinePlaneCurve_field.braid_monodromy[2]>", line 1, in <module>
        C.braid_monodromy()               # optional - sirocco
        ^^^^^^^^^^^^^^^^^^^
      File "sage/misc/cachefunc.pyx", line 2329, in sage.misc.cachefunc.CachedMethodCallerNoArgs.__call__
        self.cache = f(self._instance)
      File "/sage/src/sage/schemes/curves/affine_curve.py", line 1[85](https://github.com/sagemath/sage/actions/runs/7195279189/job/19597658375?pr=36870#step:14:86)4, in braid_monodromy
        return braid_monodromy(f)[0]
               ^^^^^^^^^^^^^^^^^^
      File "/sage/src/sage/schemes/curves/zariski_vankampen.py", line 1206, in braid_monodromy
        disc = discrim(glist)
               ^^^^^^^^^^^^^^
      File "/sage/src/sage/schemes/curves/zariski_vankampen.py", line 214, in discrim
        h0 = u[1].radical()
             ^^^^^^^^^^^^
    AttributeError: 'str' object has no attribute 'radical'

Also:
sage -t --long --random-seed=286735480429121101562228604801325644303 sage/schemes/curves/zariski_vankampen.py # 15 doctests failed

Copy link

Documentation preview for this PR (built with commit a5cd340; changes) is ready! 🎉

Copy link
Member

@mkoeppe mkoeppe left a comment

Choose a reason for hiding this comment

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

LGTM

vbraun pushed a commit to vbraun/sage that referenced this pull request Dec 21, 2023
    
Some fixes made by ruff in the schemes folder (codes C4, UP02, UP009)

plus adding manually some links to errors in the doc

### 📝 Checklist

- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
    
URL: sagemath#36870
Reported by: Frédéric Chapoton
Reviewer(s): Matthias Köppe
vbraun pushed a commit to vbraun/sage that referenced this pull request Dec 22, 2023
    
Some fixes made by ruff in the schemes folder (codes C4, UP02, UP009)

plus adding manually some links to errors in the doc

### 📝 Checklist

- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
    
URL: sagemath#36870
Reported by: Frédéric Chapoton
Reviewer(s): Matthias Köppe
vbraun pushed a commit to vbraun/sage that referenced this pull request Dec 23, 2023
    
Some fixes made by ruff in the schemes folder (codes C4, UP02, UP009)

plus adding manually some links to errors in the doc

### 📝 Checklist

- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
    
URL: sagemath#36870
Reported by: Frédéric Chapoton
Reviewer(s): Matthias Köppe
vbraun pushed a commit to vbraun/sage that referenced this pull request Dec 24, 2023
    
Some fixes made by ruff in the schemes folder (codes C4, UP02, UP009)

plus adding manually some links to errors in the doc

### 📝 Checklist

- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
    
URL: sagemath#36870
Reported by: Frédéric Chapoton
Reviewer(s): Matthias Köppe
@vbraun vbraun merged commit bc7f8e7 into sagemath:develop Dec 26, 2023
23 checks passed
@fchapoton fchapoton deleted the ruff_auto_schemes branch December 26, 2023 13:15
@mkoeppe mkoeppe added this to the sage-10.3 milestone Dec 26, 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

3 participants