-
Notifications
You must be signed in to change notification settings - Fork 0
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 Python dataclasses from Go status structs #2
Open
benhoyt
wants to merge
26
commits into
main
Choose a base branch
from
status-dataclasses-4.0
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Basically some metering stuff was removed. I think we probably want to use the 4.0 branch for the Jubilant types, so these extra fields don't show up in autocomplete -- just the ones common to 3.6 and 4.
This was referenced Feb 14, 2025
Annoying that Ruff doesn't do a better job of this by default.
benhoyt
added a commit
to benhoyt/jubilant
that referenced
this pull request
Feb 16, 2025
These come from the Go generator in: benhoyt/juju#2
There's one anomaly on the Go side, "Attachments", that doesn't have a JSON field name specified.
Currently it serializes as "Attachments", but it should be "attachments" like all the other fields. This is a breaking change, but we're considering it a bug fix, and it's very unlikely to break anyone. Fixed in Juju in juju#18931
benhoyt
added a commit
to canonical/jubilant
that referenced
this pull request
Feb 19, 2025
These come from the Go generator in: benhoyt/juju#2
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To generate
structs.py
, run:This is the same as #1, but against the Juju
main
(4.0) branch.Basically some metering stuff was removed. I think we probably want to use the 4.0 branch for the Jubilant types, so these extra fields don't show up in autocomplete -- just the ones common to 3.6 and 4.
This commit shows the diff of the generated
structs.py
.