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
Add an UML class diagram to the collections.abc module documentation #76652
Comments
From python-ideas: https://mail.python.org/pipermail/python-ideas/2017-December/048492.html In this page of the documentation: The table could be difficult to understand, a diagram help visualize things. I'm joining the last version of my work, and the .puml I used to generate it. Opinions about details (fonts, displaying...) are being discussed on the mailist right now. |
Here is the .puml |
I brought this up on python-ideas, but I think discussing it here may be better: I think we may need to use a data file format that has an open source implementation. The tool Yahya used (plantuml) doesn't appear to be open source, which is a problem for the long-term maintainability of the diagram. If I'm wrong about open source tools for reading .puml files to generate SVG files then my worries are alleviated, but if there aren't any then something like a dot file may be better long-term. |
I should mention that over on python-ideas people found the open source code to plantuml, so I think the format is acceptable for use in the docs. |
This is a nice looking diagram. Nice work. The existing table is great when you care about knowing what a particular ABC does, but the diagram nicely gives an overview of whole ecosystem all at once. If the collections.abc module continues its unabated growth, the diagram will become a spaghetti bowl. But for now, it reads nicely. |
I have generated SVG files. Here is the rest of the ABCs present in the module: https://gitlab.com/yahya-abou-imran/collections-abc-uml/blob/master/plantuml/other_collections.svg And here is the full version with all ABCs: https://gitlab.com/yahya-abou-imran/collections-abc-uml/blob/master/plantuml/full.svg What do you prefer? I'm gonna submit a PR with the full version right now. I will correct it if you think it's too big. But I don't know how to run the server of the documentation locally, so I can't test it to see... |
I succeed in submitting a PR and building the doc locally. But there is a little problem of consistency with the abstract methods: So I don't not what to show and what to hide. I opened an other issue for this: |
See the rationale in the closed PR. I rather liked this idea but it didn't prove to be a net win during user testing. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: