-
Notifications
You must be signed in to change notification settings - Fork 219
Don't require apiVersion/type for PersistentVolumeClaim
#2019
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
Merged
Conversation
This file contains hidden or 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
Related to dhall-lang/dhall-kubernetes#136 In the long-run I plan to fix all of the `dhall-kubernetes` special-case logic by undoing this logic: https://github.com/dhall-lang/dhall-haskell/blob/9dca2b8129bfec47afa069d5d1008448dcd2f873/dhall-openapi/src/Dhall/Kubernetes/Convert.hs#L44 … which would make `apiVersion`/`kind` `Optional` across the board. However, until then, this change makes them selectively `Optional` only for `PersistentVolumeClaim`.
german1608
approved these changes
Sep 2, 2020
Contributor
|
@Gabriel439 I am wondering if the fix is complete. It looks like the generated default file for and it does not match the associated type: |
Collaborator
Author
|
@PierreR: Yeah, it is a bug. I'm currently on vacation this week, but I'll fix it afterwards |
Contributor
|
@Gabriel439 Thanks. It is not urgent at all. |
Gabriella439
added a commit
that referenced
this pull request
Sep 21, 2020
… as caught by @PierreR in #2019 (comment) The issue was that the logic for generating the default for a type had a special case for the `apiVersion` / `kind` fields, which was overriding the correct `None` defaults. This change fixes that by switching the priority so that if the `None` defaults are present then they take precedence over the hard-coded defaults.
Collaborator
Author
Gabriella439
added a commit
that referenced
this pull request
Oct 2, 2020
… as caught by @PierreR in #2019 (comment) The issue was that the logic for generating the default for a type had a special case for the `apiVersion` / `kind` fields, which was overriding the correct `None` defaults. This change fixes that by switching the priority so that if the `None` defaults are present then they take precedence over the hard-coded defaults.
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.
Related to dhall-lang/dhall-kubernetes#136
In the long-run I plan to fix all of the
dhall-kubernetesspecial-caselogic by undoing this logic:
dhall-haskell/dhall-openapi/src/Dhall/Kubernetes/Convert.hs
Line 44 in 9dca2b8
… which would make
apiVersion/kindOptionalacross the board.However, until then, this change makes them selectively
Optionalonly for
PersistentVolumeClaim.