-
-
Notifications
You must be signed in to change notification settings - Fork 523
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
src/tox.ini: Add validation of docstrings using flake8-rst-docstrings #30448
Comments
This comment has been minimized.
This comment has been minimized.
Dependencies: #29651 |
This comment has been minimized.
This comment has been minimized.
comment:5
There are also linters for rst files: rstcheck or doc8 |
comment:6
Yes, see also my comments in #30415 |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
comment:11
As a first stab at docstring validation, I have added Last 10 new commits:
|
Commit: |
comment:14
For the automated check, it's also a problem that Sage uses a custom doc style and not one of the more standardized ones like pep257, numpy or google. Are there any plans to migrate to one of these standards? |
comment:15
I'm not aware of migration plans |
comment:16
Replying to @mkoeppe:
Nor am I, but it's something to consider. |
comment:17
I've created #31044 for this. |
comment:18
Also if the decision is made to migrate, to do the actual migration we will certainly need a parser for the sage-style doc. |
comment:19
Sage development has entered the release candidate phase for 9.3. Setting a new milestone for this ticket based on a cursory review of ticket status, priority, and last modification date. |
Changed author from Matthias Koeppe to Matthias Koeppe, ... |
New commits:
|
comment:57
Okay. I will open a separate ticket. |
comment:59
Here is the meta ticket: #34157 |
comment:60
Done. It is a ticket party. Whet your appetite. |
comment:61
Perhaps diff --git a/src/sage/graphs/domination.py b/src/sage/graphs/domination.py
index 25ac512233..8cc1e57de9 100644
--- a/src/sage/graphs/domination.py
+++ b/src/sage/graphs/domination.py
@@ -513,7 +513,7 @@ def _cand_ext_enum(G, to_dom, u_next):
.. WARNING::
- The same output may be output several times (up to ``H`` times).
+ The same output may be output several times (up to `|H|` times).
In order to later remove duplicates, we here output pairs ``(ext, i)``
where ``ext`` is the output candidate extension and ``i`` counts how
@@ -593,7 +593,7 @@ def minimal_dominating_sets(G, to_dominate=None, work_on_copy=True):
- ``work_on_copy`` -- boolean (default: ``True``); whether or not to work on
a copy of the input graph; if set to ``False``, the input graph will be
modified (relabeled).
-
+
OUTPUT:
An iterator over the inclusion-minimal sets of vertices of ``G``. |
comment:62
Thanks for catching this, please push it to the ticket |
Changed branch from u/mkoeppe/src_tox_ini__add_validation_of_rst_files_and_docstrings to public/30448 |
Changed commit from |
Branch pushed to git repo; I updated commit sha1. Last 10 new commits:
|
Commit: |
comment:65
Otherwise, it looks good to me. |
Changed author from Matthias Koeppe, ... to Matthias Koeppe |
Reviewer: Kwankyu Lee |
This comment has been minimized.
This comment has been minimized.
comment:67
Thanks! |
comment:68
A bug in |
comment:69
Or maybe we're just sloppy in how we use reStructuredText, and we should add explicit titles our files, like diff --git a/src/sage/categories/category_with_axiom.py b/src/sage/categories/category_with_axiom.py
index 237ad5dfed..d11bf0fe8a 100644
--- a/src/sage/categories/category_with_axiom.py
+++ b/src/sage/categories/category_with_axiom.py
@@ -1,5 +1,7 @@
r"""
+======
Axioms
+======
This documentation covers how to implement axioms and proceeds with an
overview of the implementation of the axiom infrastructure. It assumes I don't know |
comment:70
I can't get the syntax
to compile: it yields an error. At #34168 we've diagnosed what looks like a bug in |
Changed branch from public/30448 to |
Short of running a single-file docbuild (which needs fixing - #30475), there are several options for validating rst files and docstrings:
Here we add a tox environment using https://pypi.org/project/flake8-rst-docstrings.
Usage:
We also run it as part of the Lint workflow on GH Actions (see badge).
Continued in the meta ticket: #34157
Depends on #30503
CC: @tobiasdiez @jhpalmieri @dimpase @fchapoton @DaveWitteMorris @Etn40ff @tscrim @kwankyu
Component: documentation
Author: Matthias Koeppe
Branch/Commit:
0677319
Reviewer: Kwankyu Lee
Issue created by migration from https://trac.sagemath.org/ticket/30448
The text was updated successfully, but these errors were encountered: