Client generator fail to generate scaffold for greeting resource
See original GitHub issueAPI Platform version(s) affected: 2.6.1
Description
When I run: docker-compose exec pwa npx @api-platform/client-generator https://localhost . --generator next --resource greeting
I have the following error stack trace
internal/modules/cjs/loader.js:883
throw err;
^
Error: Cannot find module '/root/.npm/_npx/152/lib/node_modules/@api-platform/client-generator/node_modules/highlight.js/deprecated.js'
at Function.Module._resolveFilename (internal/modules/cjs/loader.js:880:15)
at Function.Module._load (internal/modules/cjs/loader.js:725:27)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:72:12)
at internal/main/run_main_module.js:17:47 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! highlight.js@9.18.5 postinstall: `node deprecated.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the highlight.js@9.18.5 postinstall script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /root/.npm/_logs/2021-02-06T17_51_05_067Z-debug.log
Install for [ '@api-platform/client-generator@latest' ] failed with code 1
How to reproduce
1: Install api-platform 2.6.1
2: run docker-compose exec pwa npx @api-platform/client-generator https://localhost . --generator next --resource greeting
Additional context
I don’t know if the endpoint https://localhost
is the good value to put there. And I don’t know if this is expected that I run this generation from pwa
container.But I didn’t find an example in the documentation related to the Api-Platform default setup with Docker.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:5
Top Results From Across the Web
goagen, the goa Tool · goa :: Design-first API Generation
goagen is a tool that generates various artifacts from a goa design package. Install it with: go install github.com/goadesign/goa/goagen.
Read more >Rails: How to run `rails generate scaffold` when the model ...
I tried to generate the scaffolding but I got an error saying a migration file with the same name already exists. Agree with...
Read more >Localize SharePoint Framework client-side web parts
In the project folder, run the SharePoint Framework Yeoman generator to scaffold a new SharePoint Framework project. sh. Copy. yo @microsoft/ ...
Read more >Using Genie Plugins · Genie - The Highly Productive Julia Web ...
The installation will add a new hello resource in app/resources/hello/ in the ... provides an efficient scaffold for creating a new Genie plugin...
Read more >Creating Your First Application - Quarkus
In this guide, we create a straightforward application serving a hello endpoint. ... GreetingResource resource exposed on /hello. an associated unit test.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@gusdecool many thanks for your comment. I should have carefully read your former comment 😉
use versioned package. Looks like latest version are unstable.
try this, add the api platform into your local dependencies
the run
btw, you may want to use
http://
in case your certificate self signed.