4

I already sort of asked this question but there doesn't seem to be a solution for it. So I figured I would ask a new question about work arounds people have done.

When running any form of sfdx commands in the CLI I encounter an error:

Error: Cannot find module '@oclif/config'

See examples below:

Olivias-MBP:DX oliviaporter$ sfdx force:org:open
Error: Cannot find module '@oclif/config'
    at Function._load (/usr/local/lib/node_modules/sfdx-cli/node_modules/@salesforce/lazy-require/lib/LazyLoader.js:89:24)
    at require (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
    at Object.<anonymous> (~/.local/share/sfdx/node_modules/@oclif/command/lib/command.js:6:16)
    at Module._compile (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:178:30)
Olivias-MBP:DX oliviaporter$ sfdx force:org:list
Error: Cannot find module '@oclif/config'
    at Function._load (/usr/local/lib/node_modules/sfdx-cli/node_modules/@salesforce/lazy-require/lib/LazyLoader.js:89:24)
    at require (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
    at Object.<anonymous> (~/.local/share/sfdx/node_modules/@oclif/command/lib/command.js:6:16)
    at Module._compile (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:178:30)
Olivias-MBP:DX oliviaporter$ sfdx force:user:password:generate
Error: Cannot find module '@oclif/config'
    at Function._load (/usr/local/lib/node_modules/sfdx-cli/node_modules/@salesforce/lazy-require/lib/LazyLoader.js:89:24)
    at require (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:159:20)
    at Object.<anonymous> (~/.local/share/sfdx/node_modules/@oclif/command/lib/command.js:6:16)
    at Module._compile (/usr/local/lib/node_modules/sfdx-cli/node_modules/v8-compile-cache/v8-compile-cache.js:178:30)
Olivias-MBP:DX oliviaporter$ 

Some of the files exist, some do not. I am not sure if I should uninstall and reinstall the cli and sfdx (I have done updates and this did not work). I feel like I almost need to roll back to V6 but I am also not sure if this will cause more issues then good.

My last question someone suggested that this was an known issue with sfdx v7 which was automatically updated as of yesterday. I am very stuck and have resorted to SourceTree to push and pull scratch orgs but am limited on being able to open the scratch org in the browser or reset passwords etc...

I would appreciate any direction or work arounds people have found for the sfdx bug.

Thank you.

ERROR running force:source:push: No org configuration found for name

  • I've seen three variants of this now, and it seems that running sfdx update followed by sfdx plugins:install salesforcedx@latest seems to fix it. Have you tried that specific combination of commands? – sfdcfox Mar 29 at 17:20
  • Deleting the sourcePathInfos.json (and pushing all the code again) worked for me – shmuels Mar 29 at 17:30
  • @sfdcfox I did try that and a number of other commands and nothing worked except for uninstalling and reinstalling. – Olivia Mar 29 at 17:31
3

I ended up having to uninstall sfdx and reinstall it with the help of these two articles:

https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_uninstall.htm

https://developer.salesforce.com/docs/atlas.en-us.sfdx_setup.meta/sfdx_setup/sfdx_setup_install_cli.htm

All seems to be working now.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.