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

Generate class diagram from django models #3366

Open
jarlhengstmengel opened this issue Jan 24, 2025 · 2 comments
Open

Generate class diagram from django models #3366

jarlhengstmengel opened this issue Jan 24, 2025 · 2 comments
Assignees
Labels
infrastructure Issues related to the dev or production environment prio: low Not urgent, can be resolved in the distant future.
Milestone

Comments

@jarlhengstmengel
Copy link
Contributor

Motivation

We quite often run into the problem of losing the overview over our data structure. It can be quite time consuming figuring out the relations between different models, which are inheriting variables from others or what data is realized as cached properties.

Proposed Solution

Export django models as class diagram. This could be a possible starting point for realizing this.

Alternatives

Continue individually trying to get an overview for isolated parts when needed.

@jarlhengstmengel jarlhengstmengel added infrastructure Issues related to the dev or production environment prio: low Not urgent, can be resolved in the distant future. labels Jan 24, 2025
@jonbulz
Copy link
Contributor

jonbulz commented Jan 28, 2025

I use dbeaver-ce for thinks like this. It has a decent GUI to examine database connections. This is what an ER-diagram of our complete postgres looks like:

Image

Of course, it is possible to break it down further, and you can examine links between models better in the tool

@JoeyStk
Copy link
Contributor

JoeyStk commented Jan 28, 2025

Ideally we would choose an option where this diagram is updated automatically and this could be part of the docu-building jobs or of the CI/CD pipeline

@JoeyStk JoeyStk added this to the Backlog milestone Jan 28, 2025
@jarlhengstmengel jarlhengstmengel self-assigned this Jan 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Issues related to the dev or production environment prio: low Not urgent, can be resolved in the distant future.
Projects
None yet
Development

No branches or pull requests

3 participants