Comments (7)
@chrisjsewell You introduced the typed interface for that one so perhaps you could take that one?
from sphinx.
you introduced the typed interface for that one so perhaps you could take that one?
Well, that's one of the reasons I introduced it; because for a long time I had no idea env_version
was even an option 😅
But indeed thank you for detailing this @mgeier, it would be good to make the documentation around it clearer
alternatively, a Domain could be used to store data in the environment.
I would note here, that I feel the purpose of a domain is more around handling referencing, and then the storage of data here is more of a "side-effect" of that; to store pointers to targets, etc
I don't believe you should use it to store arbitrary data.
from sphinx.
I don't believe you should use it to store arbitrary data.
This kinda says the opposite: #9003 (comment)
Would you suggest adding arbitrary attributes to app.env
instead?
Or do you have something even better?
And it's not only about storing data, it's also about making it work with parallel builds, which is actually hard, see e.g. #12251.
And to be fancy, it's about removing the appropriate data if a source file is removed (which the "todo" extension does but the "recipe" extension doesn't, AFAICT).
For a concrete example, see mgeier/sphinx-last-updated-by-git#66. I'm not sure if that's better or worse, BTW!
from sphinx.
This kinda says the opposite
well that is not consistent with what the actual source says:
sphinx/sphinx/domains/__init__.py
Lines 159 to 180 in 6fd8b30
And it's not only about storing data, it's also about making it work with parallel builds, which is actually hard
We deal with this in sphinx-needs with parallel builds for large documentation sets, and it works quite well: https://github.com/useblocks/sphinx-needs/blob/0f71ecde47a3f7c3245c5bcf545ef5281376768c/sphinx_needs/needs.py#L266-L270
But I agree that it would be nice to have a "consistent" workflow for storing data (outside of references)
from sphinx.
Related Issues (20)
- Typing `pending_xref` node attrributes (and maybe all `addnodes`) HOT 5
- Plan for docutils 0.21 release HOT 7
- Role-based cross referencing for non-Sphinx API documentation HOT 4
- Template translations (sphinx.po) are not used for English language
- Incomplete documentation for add_js_file() and add_css_file()
- HTML search: allow grouping results from the same page
- Enable navigation_with_keys by default in themes with responsive design HOT 13
- Attribute's are considered undocumented if described in the header HOT 3
- [i18n] check translations before release HOT 2
- ubuntu 22.04 & python 3.10: cannot import name union from types - installing sphinx debian corrupted python install HOT 3
- 7.3.0 release plan HOT 12
- make public & private interface more explicit HOT 8
- Enable linkcheck for Excalidraw rooms
- Sphinx does not work with docutils 0.21.1 HOT 1
- Missing documentation of python class with decorators. HOT 1
- `sphinx.ext.autosummary` does not process a subpackage, even though it imports without errors HOT 5
- sphinx.ext.autodoc' has no attribute 'startswith HOT 2
- Text builder can't handle all tables HOT 1
- Remote image download: consider using a packaged dependency to provide content caching. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sphinx.