-
Notifications
You must be signed in to change notification settings - Fork 199
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
fix: add granular read ops enum #2720
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,6 +22,12 @@ public enum ModelOperation { | |
case update | ||
case delete | ||
case read | ||
// granular read access | ||
case `get` | ||
case list | ||
case sync | ||
case listen | ||
case search | ||
} | ||
Comment on lines
+25
to
31
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we start off by attaching the generated Model swift types that utilizes these new granular read access cases? By doing so, we can update the source schema that we use to reference the generated types. Is there an sort of relevant API calls that we can write, either in the unit or integration tests, utilizing these models, and asserting the expected behavior? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The example schema using it is
The model files can be generated by the current version of modelgen, which has the following line generated
|
||
|
||
/// - Warning: Although this has `public` access, it is intended for internal use and should not be used directly | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I bet a lot of logic is determined by checking if the operation is
.read
and does something. Now that we allow compiling the more granular "read" types, that means all logic based on "read" should now be updated to