Skip to content
This repository has been archived by the owner on Nov 13, 2023. It is now read-only.

Bug in UpdateImpConfig.js (?) #859

Closed
Yuliya-Kirkorava opened this issue Jul 28, 2022 · 7 comments · Fixed by #860
Closed

Bug in UpdateImpConfig.js (?) #859

Yuliya-Kirkorava opened this issue Jul 28, 2022 · 7 comments · Fixed by #860
Assignees

Comments

@Yuliya-Kirkorava
Copy link

Hi,
I got an error when I tried to install @zowe/zos-make-for-zowe-cli:
image

In the Imperative.log file there are some additional messages:
msg: 'Install Failed',
causeErrors: ImperativeError: profiles is not iterable
at Object. (C:\Users\Kirkorava_Y\AppData\Roaming\nvm\v18.7.0\node_modules@zowe\cli\node_modules@zowe\imperative\lib\imperative\src\plugins\utilities\npm-interface\install.js:134:19)
at Generator.next ()
at fulfilled (C:\Users\Kirkorava_Y\AppData\Roaming\nvm\v18.7.0\node_modules@zowe\cli\node_modules@zowe\imperative\lib\imperative\src\plugins\utilities\npm-interface\install.js:15:58) {
mDetails: {
msg: 'profiles is not iterable',
causeErrors: TypeError: profiles is not iterable
at UpdateImpConfig.addProfiles (C:\Users\Kirkorava_Y\AppData\Roaming\nvm\v18.7.0\node_modules@zowe\cli\node_modules@zowe\imperative\lib\imperative\src\UpdateImpConfig.js:54:40)
at Object. (C:\Users\Kirkorava_Y\AppData\Roaming\nvm\v18.7.0\node_modules@zowe\cli\node_modules@zowe\imperative\lib\imperative\src\plugins\utilities\npm-interface\install.js:127:51)
at Generator.next ()
at fulfilled (C:\Users\Kirkorava_Y\AppData\Roaming\nvm\v18.7.0\node_modules@zowe\cli\node_modules@zowe\imperative\lib\imperative\src\plugins\utilities\npm-interface\install.js:15:58)
},
mMessage: 'profiles is not iterable'

I try to change this plugin to run it with Zowe V2, and seems UpdateImpConfig.js is a potential place for the bug.

Thanks!

@t1m0thyj
Copy link
Member

What is the command you used to install the zos-make plug-in?

@Yuliya-Kirkorava
Copy link
Author

I cloned this project and use npm script "installPlugin":
"npm install && npm run clean && npm run build && zowe plugins install ."
But the same error was when I used :
zowe plugins install @zowe/zos-make-for-zowe-cli@latest
from README file.

@t1m0thyj
Copy link
Member

For the zos-make plug-in, the master branch on GitHub and @latest tag on NPM are for the Zowe v1 version.

To use the Zowe v2 beta or prerelease version of the plug-in, you'd want to install either from the @next tag on NPM:
zowe plugins install @zowe/zos-make-for-zowe-cli@next

Or to install from source, use the next branch:
git checkout next && npm install && npm run build && zowe plugins install .

@Yuliya-Kirkorava
Copy link
Author

image

@t1m0thyj
Copy link
Member

Thanks for reporting 🙂 I investigated this some more and found there is a bug in Imperative and Zowe CLI that prevents you from installing plug-ins that don't define profiles.

@t1m0thyj
Copy link
Member

This should be fixed in the latest version of Zowe CLI (7.4.1).

To update your Zowe CLI version, you can reinstall with the command npm install -g @zowe/cli@zowe-v2-lts

Then you should be able to install the zos-make plug-in without any errors (there may still be warnings but that is expected).

@Yuliya-Kirkorava
Copy link
Author

After reinstallation @zowe/cli the plugin was installed without any problems!
Thank you for fixing this problem.

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

Successfully merging a pull request may close this issue.

2 participants