Skip to content
This repository has been archived by the owner on Sep 14, 2022. It is now read-only.

swagger project edit cannot get / #581

Open
mohitmutha opened this issue Feb 10, 2019 · 13 comments
Open

swagger project edit cannot get / #581

mohitmutha opened this issue Feb 10, 2019 · 13 comments

Comments

@mohitmutha
Copy link

mohitmutha commented Feb 10, 2019

Running swagger version 0.7.5

Steps to reproduce

  1. Create a new project with swagger project create profiles
  2. Select express as the framework
  3. Project is created successfully
  4. Run swagger project edit profiles
  5. Browser page opens up with message Cannot GET /

Other way to reproduce
After step 3
4. Run command cd profiles to browse into the project dir
5. Run swagger project edit
6. Browser page opens up with message Cannot GET /

@mohitmutha
Copy link
Author

Have tried to install the swagger-editor both locally in the project and globally but getting the same result as above.

@MasaakiYAMADA
Copy link

Since there is no swagger-editor, an error may be occurring.
Please install it globally and try it.

nom - g install swagger-editor

or

yarn global add swagger-editor

@mohitmutha
Copy link
Author

I have already tried adding the swagger-editor locally as well as globally. Still getting the same error.

@MasaakiYAMADA
Copy link

Windows users

For some versions of npm on Windows will have problems on the npm install step of swagger project create. They are related to a debug module on npm not being managed properly. The following steps should resolve this issue:

  1. In the project directory, execute the following commands:
  2. npm install yamljs
  3. npm install debug
  4. npm install swagger-tools

@MasaakiYAMADA
Copy link

There is also a way to edit YAML with provided docker.

docker run --rm - d - p 80: 8080 swaggerapi / swagger - editor

This image also comes with the swagger-codegen function.
I gave up on building locally because desired JAVASE8 in the setting of swagger-codegen.

@mwallnoefer
Copy link

I faced the same issue, the problem is that config/default.yaml doesn't contain the item - swagger_params_parser under the section swagger_controllers:.
Adding it there fixed the issue for me.

@mwallnoefer
Copy link

mwallnoefer commented Feb 18, 2019

It turns out that the current node release 0.7.5 doesn't provide the following patch 70846a6#diff-28fe2e29ccfb9685861115a451ee1626 yet, although it is two years old.
Very odd...all in all manual patching seems to be the only work-around for now.

Also the docs lack this line, so I have created an apposite pull request: #582

@mohitmutha
Copy link
Author

3\. npm install debug

This did not work for me. I am using a Mac

@mohitmutha
Copy link
Author

mohitmutha commented Feb 22, 2019

I faced the same issue, the problem is that config/default.yaml doesn't contain the item - swagger_params_parser under the section swagger_controllers:.
Adding it there fixed the issue for me.

Did not fix it for me.

@mohitmutha
Copy link
Author

Is this project maintained anymore ?

@mwallnoefer
Copy link

Any news on this?

@JaimeSalas
Copy link

Hi I face this issue. In my case I have solved by installing node v8.17.0 via nvm. I hope can help any one.

@lena-A-Al
Copy link

I still have the same issue, I am a mac user.

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

5 participants