aws-amplify / aws-amplify/amplify-cli

add support for overrides on `amplify export`

Open
#10,235 3 comments 0 reactions 0 assignees View on GitHub
extensibility feature-request p3
Dominant language
TypeScript
Stars
2.9k
Forks
825
Avg merge
11d 23h
Merged PRs (30d)
2

Description

### Before opening, please confirm:

- [X] I have installed the latest version of the Amplify CLI (see above), and confirmed that the issue still persists.
- [X] I have [searched for duplicate or closed issues](https://github.com/aws-amplify/amplify-cli/issues?q=is%3Aissue+).
- [X] I have read the guide for [submitting bug reports](https://github.com/aws-amplify/amplify-cli/blob/master/CONTRIBUTING.md#bug-reports).
- [X] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
- [X] I have removed any sensitive information from my code snippets and submission.

### How did you install the Amplify CLI?

npm install -g @aws-amplify/cli

### If applicable, what version of Node.js are you using?

v16.14.0

### Amplify CLI Version

8.0.1

### What operating system are you using?

Ubuntu

### Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.

No manual changes made

### Amplify Categories

Not applicable

### Amplify Commands

export

### Describe the bug

I tell you a problem I have with a project created with AWS Amplify, I have with several resolvers in the preLoadData stage, unfortunately I did not find an elegant solution to place them `dataSourceName `until I used the overwrite strategy in the API, when I deploy with the CLI it works great, the problem comes when I try to export my project to CDK the overrider does not work, in the build stage when exporting it does not make this call, you can even try to execute the `amplify build` command and you will see that if the overrider file is executed, it does not work when I execute `amplify export`.

### Expected behavior

That replaces all the dataSourceName as it does when I run `amplify push`

### Reproduction steps

`amplify export --out folder-export`

### GraphQL schema(s)

```graphql
# Put schemas below this line

```

### Log output

```
# Put your logs below this line

```

### Additional information

_No response_

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the issue with `amplify export --out folder-export` and compare it with `amplify push` or `amplify build`, where the override is reported to work. Trace the export command's handling of resolver `dataSourceName` overrides and confirm that exported CDK output contains the replacements.】【。}_久久爱? Wait malformed? Need valid JSON and character weird. Fix.cken. Ensure under 600. No mention files. Good. Let's final. һөкүмити. Geen. Need only JSON. The draft had extra. We'll provide.、】【. Actually researchDirection 2 sentences. fine. Estimated time maybe 3-5. final. 七星彩. Wait JSON string uses backticks okay. Let's output.orlutik. Need no weird.娱乐主管. final now. 天天中彩票彩金. Hold, exact shape all fields. yes. final.ablytyped.ուգ. Let's ensure score under 60 due stale, no logs and old issue. Good. only JSON.(visitor. final.burugburu. final._俺去也. Done. Need avoid

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, typescript
Domain
api, cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.