Skip to content
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: keeps hooks intact when attaching backend #11179

Merged
merged 6 commits into from
Oct 21, 2022

Conversation

akshbhu
Copy link
Contributor

@akshbhu akshbhu commented Oct 13, 2022

Description of changes

  • Since from v10.0.0 hooks aren't maintained by amplify. During amplify pill operation when attaching backend , hooks pulled from git are getting deleted by amplify when doing a pull in an empty folder or running headless pull command
    amplify pull --envName dev
    Fix here is to keeps the hooks back into amplify folder when attaching backend.

Issue #11050

Description of how you validated changes

Checklist

  • PR description included
  • yarn test passes
  • Tests are changed or added
  • Relevant documentation is changed or added (and PR referenced)
  • New AWS SDK calls or CloudFormation actions have been added to relevant test and service IAM policies
  • Pull request labels are added

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@akshbhu akshbhu requested a review from a team as a code owner October 13, 2022 17:10
packages/amplify-cli/src/attach-backend.ts Outdated Show resolved Hide resolved
packages/amplify-cli/src/attach-backend.ts Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Oct 13, 2022

Codecov Report

Merging #11179 (0618e9b) into dev (9a1c725) will increase coverage by 0.00%.
The diff coverage is n/a.

@@           Coverage Diff           @@
##              dev   #11179   +/-   ##
=======================================
  Coverage   49.49%   49.49%           
=======================================
  Files         682      682           
  Lines       32861    32861           
  Branches     6708     6708           
=======================================
+ Hits        16263    16264    +1     
+ Misses      15118    15117    -1     
  Partials     1480     1480           
Impacted Files Coverage Δ
...li/src/domain/amplify-usageData/getUsageDataUrl.ts 100.00% <0.00%> (+12.50%) ⬆️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

sobolk
sobolk previously approved these changes Oct 13, 2022
pavellazar
pavellazar previously approved these changes Oct 13, 2022
yarn.lock Outdated Show resolved Hide resolved
@hackmajoris
Copy link

Waiting for this PR to be merged. I hope it will fix this: #11021

@akshbhu akshbhu dismissed stale reviews from pavellazar and sobolk via 5c3d6be October 19, 2022 17:28
@akshbhu akshbhu force-pushed the fix/hooks_deletetion branch from 8e81b40 to 5c3d6be Compare October 19, 2022 17:28
Copy link
Contributor

@aws-eddy aws-eddy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have few nits but otherwise looks good to merge

packages/amplify-e2e-tests/src/__tests__/hooks-b.test.ts Outdated Show resolved Hide resolved
aws-eddy
aws-eddy previously approved these changes Oct 19, 2022
sobolk
sobolk previously approved these changes Oct 19, 2022
@akshbhu akshbhu dismissed stale reviews from sobolk and aws-eddy via 0618e9b October 19, 2022 18:12
@hackmajoris
Copy link

@akshbhu any idea when this fixed will be released?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants