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

Reading configuration file in Windows #67

Closed
kaleabmelkie opened this issue May 20, 2022 · 3 comments · Fixed by #68
Closed

Reading configuration file in Windows #67

kaleabmelkie opened this issue May 20, 2022 · 3 comments · Fixed by #68

Comments

@kaleabmelkie
Copy link

kaleabmelkie commented May 20, 2022

Following the basic steps from the Getting Started section of the docs errors with the following message on Windows when trying to run generate:

> npx @magidoc/cli@latest generate
Only URLs with a scheme in: file, data are supported by the default ESM loader. On Windows, absolute paths must be valid file:// URLs. Received protocol 'c:'

My "magidoc.mjs" file:

export default {
  introspection: {
    type: "url",
    url: "https://graphiql-test.netlify.app/.netlify/functions/schema-demo",
  },
  website: {
    template: "carbon-multi-page",
  },
};
@pelletier197
Copy link
Collaborator

Hi, thanks for raising the issue.

Could you tell me what version of NodeJS you are on? Also, could provide me with the output of running:

 npx @magidoc/cli@latest generate --stacktrace

Thanks in advance!

I see that the issue was raised by many people on different projects. I will hop on my windows machine today and try to reproduce this issue.

@kaleabmelkie
Copy link
Author

kaleabmelkie commented May 20, 2022

The stack trace has the same exact output:

image

I'm on Node.js v16.15.0 and npm v8.9.0

@pelletier197 pelletier197 linked a pull request May 20, 2022 that will close this issue
@pelletier197
Copy link
Collaborator

pelletier197 commented May 20, 2022

I closed this issue, it should be resolved in the latest version. I get another issue with the deployed version when using powershell, related to peer dependencies. I'll open another issue for it. Thanks for raising the issue. I'll need to improve testing on Windows.

Edit: it's fixed as well! Thanks again!

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 a pull request may close this issue.

2 participants