-
Notifications
You must be signed in to change notification settings - Fork 265
fix(api): model helpers use targetNames in schemas with CPK enabled #2559
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
dnys1
merged 4 commits into
aws-amplify:main
from
ragingsquirrel3:feat/codegen-update-2548
Jan 12, 2023
Merged
fix(api): model helpers use targetNames in schemas with CPK enabled #2559
dnys1
merged 4 commits into
aws-amplify:main
from
ragingsquirrel3:feat/codegen-update-2548
Jan 12, 2023
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
dnys1
reviewed
Jan 9, 2023
HuiSF
previously approved these changes
Jan 9, 2023
packages/api/amplify_api/lib/src/graphql/graphql_request_factory.dart
Outdated
Show resolved
Hide resolved
HuiSF
previously approved these changes
Jan 9, 2023
dnys1
previously approved these changes
Jan 9, 2023
dnys1
approved these changes
Jan 12, 2023
HuiSF
approved these changes
Jan 12, 2023
dnys1
pushed a commit
to dnys1/amplify-flutter
that referenced
this pull request
Jan 12, 2023
…ws-amplify#2559) * fix(api): model helpers can use targetNames in schemas with CPK enabled * address some comments
dnys1
pushed a commit
to dnys1/amplify-flutter
that referenced
this pull request
Jan 12, 2023
- fix(datastore): prevent unhandled exception crashing App rebuilding sync expression (aws-amplify#2549) - fix(datastore): Upgrading from Datastore 0.6.1 to 0.6.8 causes Android app to crash (aws-amplify#2556) - fix(api): model helpers use targetNames in schemas with CPK enabled (aws-amplify#2559) - 160674d - 7121ebc - 957d6b4 - 5ec55b9 - 33df283 - 5ec023b - 51f5e56 - fab55ae - 6bd4182 - 6464555 - 2a7caae - 809190c
Merged
dnys1
pushed a commit
that referenced
this pull request
Jan 12, 2023
…2559) * fix(api): model helpers can use targetNames in schemas with CPK enabled * address some comments
dnys1
pushed a commit
that referenced
this pull request
Jan 12, 2023
- fix(datastore): prevent unhandled exception crashing App rebuilding sync expression (#2549) - fix(datastore): Upgrading from Datastore 0.6.1 to 0.6.8 causes Android app to crash (#2556) - fix(api): model helpers use targetNames in schemas with CPK enabled (#2559) - 160674d - 7121ebc - 957d6b4 - 5ec55b9 - 33df283 - 5ec023b - 51f5e56 - fab55ae - 6bd4182 - 6464555 - 2a7caae - 809190c
ragingsquirrel3
pushed a commit
that referenced
this pull request
Jan 13, 2023
…2559) * fix(api): model helpers can use targetNames in schemas with CPK enabled * address some comments
dnys1
pushed a commit
that referenced
this pull request
Jan 24, 2023
…2559) * fix(api): model helpers can use targetNames in schemas with CPK enabled * address some comments
dnys1
pushed a commit
to Jordan-Nelson/amplify-flutter
that referenced
this pull request
Jan 30, 2023
- fix(auth)!: Fetch Auth Session offline behavior ([aws-amplify#2585](aws-amplify#2585)) - fix(api): do not include null values in ModelMutations.create ([aws-amplify#2504](aws-amplify#2504)) - fix(api): model helpers use targetNames in schemas with CPK enabled ([aws-amplify#2559](aws-amplify#2559)) - fix(auth): Clear credentials before redirect on Web ([aws-amplify#2603](aws-amplify#2603)) - fix(auth): Refresh token in non-state machine calls ([aws-amplify#2572](aws-amplify#2572)) - fix(authenticator): ARB syntax ([aws-amplify#2560](aws-amplify#2560)) - fix(aws_common): AWSFile contentType getter should not throw exception - fix(datastore): prevent unhandled exception crashing App rebuilding sync expression - fix(storage): incorrect transferred bytes emitted from upload task - feat(analytics): Legacy data migration of Pinpoint Endpoint ID ([aws-amplify#2489](aws-amplify#2489)) - feat(smithy_aws): add copyWith to S3ClientConfig - feat(storage): allow configuring transfer acceleration Updated-Components: Amplify Flutter, Amplify Dart, Amplify UI, DB Common, Secure Storage, AWS Common, Smithy, Worker Bee
dnys1
pushed a commit
to Jordan-Nelson/amplify-flutter
that referenced
this pull request
Jan 30, 2023
- fix(auth)!: Fetch Auth Session offline behavior ([aws-amplify#2585](aws-amplify#2585)) - fix(api): do not include null values in ModelMutations.create ([aws-amplify#2504](aws-amplify#2504)) - fix(api): model helpers use targetNames in schemas with CPK enabled ([aws-amplify#2559](aws-amplify#2559)) - fix(auth): Clear credentials before redirect on Web ([aws-amplify#2603](aws-amplify#2603)) - fix(auth): Refresh token in non-state machine calls ([aws-amplify#2572](aws-amplify#2572)) - fix(authenticator): ARB syntax ([aws-amplify#2560](aws-amplify#2560)) - fix(aws_common): AWSFile contentType getter should not throw exception - fix(datastore): prevent unhandled exception crashing App rebuilding sync expression - fix(storage): incorrect transferred bytes emitted from upload task - feat(analytics): Legacy data migration of Pinpoint Endpoint ID ([aws-amplify#2489](aws-amplify#2489)) - feat(smithy_aws): add copyWith to S3ClientConfig - feat(storage): allow configuring transfer acceleration Updated-Components: Amplify Flutter, Amplify Dart, Amplify UI, DB Common, Secure Storage, AWS Common, Smithy, Worker Bee
Jordan-Nelson
added a commit
that referenced
this pull request
Jan 30, 2023
* chore(repo): Update component definition Adds `amplify_api_dart` to the mix and creates components for DB Common, Secure Storage, and AWS Common * fix(aft): Update changelog logic For the version commit message changelog, only include publishable packages. Also updates base ref logic to ensure packages can be moved in and out of components. * chore(version): Bump version - fix(auth)!: Fetch Auth Session offline behavior ([#2585](#2585)) - fix(api): do not include null values in ModelMutations.create ([#2504](#2504)) - fix(api): model helpers use targetNames in schemas with CPK enabled ([#2559](#2559)) - fix(auth): Clear credentials before redirect on Web ([#2603](#2603)) - fix(auth): Refresh token in non-state machine calls ([#2572](#2572)) - fix(authenticator): ARB syntax ([#2560](#2560)) - fix(aws_common): AWSFile contentType getter should not throw exception - fix(datastore): prevent unhandled exception crashing App rebuilding sync expression - fix(storage): incorrect transferred bytes emitted from upload task - feat(analytics): Legacy data migration of Pinpoint Endpoint ID ([#2489](#2489)) - feat(smithy_aws): add copyWith to S3ClientConfig - feat(storage): allow configuring transfer acceleration Updated-Components: Amplify Flutter, Amplify Dart, Amplify UI, DB Common, Secure Storage, AWS Common, Smithy, Worker Bee --------- Co-authored-by: Dillon Nys <[email protected]>
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.
Addresses #2548
With the latest version of the CLI, new backends have CPK enabled by default. This changes the output of codegen in a way that breaks model helpers. Model helpers look for a field
.targetName
on schema fields in a few places when getting info from related models.This PR does not add full support for CPK, just keeps model helpers working with new versions of CLI.
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.