Skip to content
This repository has been archived by the owner on Feb 22, 2024. It is now read-only.

Difficulty getting the sample config #12

Open
hhouchard opened this issue Mar 8, 2017 · 16 comments
Open

Difficulty getting the sample config #12

hhouchard opened this issue Mar 8, 2017 · 16 comments

Comments

@hhouchard
Copy link

Please help me understand why I am getting the following when I try to get the sample configuration. Thanks.

Isabella-Houchards-iMac:~ isabellahouchard$ npm install -g canvas-data-cli
/usr/local/bin/canvasDataCli -> /usr/local/lib/node_modules/canvas-data-cli/bin/canvasDataCli
/usr/local/lib
└── [email protected]

Isabella-Houchards-iMac:~ isabellahouchard$ canvasDataCli sampleConfig
module.js:471
throw err;
^

Error: Cannot find module './lib/Api'
at Function.Module._resolveFilename (module.js:469:15)
at Function.Module._load (module.js:417:25)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object. (/usr/local/lib/node_modules/canvas-data-cli/index.js:2:8)
at Module._compile (module.js:570:32)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
Isabella-Houchards-iMac:~ isabellahouchard$

@Mythra
Copy link
Contributor

Mythra commented Apr 9, 2017

👋 ,

We've seen this happen occasionally when an incorrect installation has happened. If this is still happening we've seen it be fixed by running:

npm uninstall -g canvas-data-cli && npm cache clean && npm install -g canvas-data-cli

In the terminal.

@hhouchard
Copy link
Author

hhouchard commented Apr 10, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 10, 2017

Hey,

Do you still have node installed? NPM Comes with nodejs, and it looks like you had it at one point based on your initial issue:

Isabella-Houchards-iMac:~ isabellahouchard$ npm install -g canvas-data-cli
/usr/local/bin/canvasDataCli -> /usr/local/lib/node_modules/canvas-data-cli/bin/canvasDataCli
/usr/local/lib
└── [email protected]

If you didn't uninstall node then it sounds like it didn't get added to your PATH. This should generally happen when you install node itself. Do you mind if I ask how you installed Node?

@hhouchard
Copy link
Author

hhouchard commented Apr 10, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 10, 2017

Hey,

So the canvas support agent you were talking to was me. Small world. If you can execute npm right now, and get some output then I'd say don't worry about uninstall/reinstalling node.

If you can't I'd do two things (since it looks like you have brew.)

  • run brew doctor in order to clean up anything that it can detect.
  • run brew install node in order to clean things up/add node to your path.

After that close your terminal and open it again. You may need to reinstall the CLI Globally (npm install -g canvas-data-cli), but it should be good.

@hhouchard
Copy link
Author

hhouchard commented Apr 10, 2017 via email

@hhouchard
Copy link
Author

hhouchard commented Apr 10, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 10, 2017

Heh, I think I'm the only one who still uses that account (though we have multiple people using the queue) as a reply email. Everyone else has had their accounts associated to the correct email.

@hhouchard
Copy link
Author

hhouchard commented Apr 10, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 10, 2017

Awesome, glad to hear!

@Mythra Mythra closed this as completed Apr 10, 2017
@hhouchard
Copy link
Author

hhouchard commented Apr 23, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 23, 2017

@hhouchard it appears you have a syntax error in your configuration. Do you mind posting it here, and I'd be happy to shine light as to what it is.

@Mythra Mythra reopened this Apr 23, 2017
@hhouchard
Copy link
Author

hhouchard commented Apr 23, 2017 via email

@Mythra
Copy link
Contributor

Mythra commented Apr 23, 2017

@hhouchard I'd rotate those credentials right away. (this can be done in the portal by regenerating credentials). Anyone with those would have complete access to your schools data. I should've mentioned that in my first comment. We will never need it from a support perspective.

Second off it appears you're mac is performing what's known as "smart quotes". (You'll notice the quotes appear curly e.g.:

Normal quote: '
Smart quote: ‘
Normal quote: "
Smart Quote: ‘’
).

There's a guide to turn it off globally HERE if you want to never deal with it again. If not you can copy the normal quote from my response here.

@hhouchard
Copy link
Author

hhouchard commented Apr 23, 2017 via email

@wbuchanan
Copy link

@securityinsanity
Any idea what could be leading to the connection problems reported in issue #15?

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

No branches or pull requests

3 participants