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: change upgrade-project command to track skill-id in ask-states.json #90

Merged
merged 3 commits into from
Mar 31, 2020

Conversation

RonWang
Copy link
Contributor

@RonWang RonWang commented Mar 31, 2020

No description provided.

@RonWang RonWang requested a review from Chih-Ying March 31, 2020 01:38
Copy link
Contributor

@Chih-Ying Chih-Ying left a comment

Choose a reason for hiding this comment

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

The changes looks good, but I found two issues:

  1. the first one is a following issue, in git-credentials-helper getSkillId via ResourcesConfig is undefined (https://github.com/alexa-labs/ask-cli/blob/fix_ahs_skillid_not_in_state/lib/commands/util/git-credentials-helper/index.js#L40), so get git-credentials is always failed. I looked into a upgraded skill, skillId only exists in ask-resources.json, but ResourcesConfig get skillId from ask-states.json (https://github.com/alexa-labs/ask-cli/blob/fix_ahs_skillid_not_in_state/lib/model/resources-config/index.js#L66), should we change it back to ask-resources.json?
  2. the second issue is not related to this PR, we should add ask-resources.json into .gitignore while upgrading project, I can create another PR to fix it?

@RonWang
Copy link
Contributor Author

RonWang commented Mar 31, 2020

The changes looks good, but I found two issues:

  1. the first one is a following issue, in git-credentials-helper getSkillId via ResourcesConfig is undefined (https://github.com/alexa-labs/ask-cli/blob/fix_ahs_skillid_not_in_state/lib/commands/util/git-credentials-helper/index.js#L40), so get git-credentials is always failed. I looked into a upgraded skill, skillId only exists in ask-resources.json, but ResourcesConfig get skillId from ask-states.json (https://github.com/alexa-labs/ask-cli/blob/fix_ahs_skillid_not_in_state/lib/model/resources-config/index.js#L66), should we change it back to ask-resources.json?
  2. the second issue is not related to this PR, we should add ask-resources.json into .gitignore while upgrading project, I can create another PR to fix it?

The first point is actually not an issue. Not sure if you have tested but on my side it calls git-credential correctly. ResourcesConfig is a hub which is comprised of ask-states and ask-resources. Its getSkillId is from ask-states.json. SkillId is the state value thus we should not change it back to ask-resources.json.

And for the second one that's a good call, I will add it into postUpgradeGitSetup section.

@Chih-Ying Chih-Ying merged commit 97e986e into develop Mar 31, 2020
@RonWang RonWang deleted the fix_ahs_skillid_not_in_state branch March 31, 2020 20:31
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.

2 participants