bagseye / barcadia

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Initial Getting Started fails on a clean install

jerdog opened this issue · comments

Running this command from README returns errors on a clean install

gatsby new my-barcadia-starter https://github.com/bagseye/barcadia

DEPENDENCY ERRORS:

success Created starter directory layout
info Installing packages...

npm WARN old lockfile
npm WARN old lockfile The package-lock.json file was created with an old version of npm,
npm WARN old lockfile so supplemental metadata must be fetched from the registry.
npm WARN old lockfile
npm WARN old lockfile This is a one-time fix-up, please be patient...
npm WARN old lockfile
npm WARN deprecated async-cache@1.1.0: No longer maintained. Use lru-cache version 7.6 or higher, and provide an asynchronous fetchMethod option.
npm WARN deprecated stable@0.1.8: Modern JS already guarantees Array#sort() is a stable sort, so this library is deprecated. See the compatibility table on MDN: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/sort#browser_compatibility
npm WARN deprecated source-map-url@0.4.1: See https://github.com/lydell/source-map-url#deprecated
npm WARN deprecated @hapi/bourne@1.3.2: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated source-map-resolve@0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
npm WARN deprecated querystring@0.2.1: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
npm WARN deprecated multer@1.4.4: Multer 1.x is affected by CVE-2022-24434. This is fixed in v1.4.4-lts.1 which drops support for versions of Node.js before 6. Please upgrade to at least Node.js 6 and version 1.4.4-lts.1 of Multer. If you need support for older versions of Node.js, we are open to accepting patches that would fix the CVE on the main 1.x release line, whilst maintaining compatibility with Node.js 0.10.
npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated devcert@1.2.0: critical regex denial of service bug fixed in 1.2.1 patch
npm WARN deprecated subscriptions-transport-ws@0.9.19: The subscriptions-transport-ws package is no longer maintained. We recommend you use graphql-ws instead. For help migrating Apollo software to graphql-ws, see https://www.apollographql.com/docs/apollo-server/data/subscriptions/#switching-from-subscriptions-transport-ws For general help using graphql-ws, see https://github.com/enisdenjo/graphql-ws/blob/master/README.md
npm WARN deprecated @hapi/joi@15.1.1: Switch to 'npm install joi'
npm WARN deprecated svgo@1.3.2: This SVGO version is no longer supported. Upgrade to v2.x.x.
npm WARN deprecated core-js-pure@3.21.1: core-js-pure@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js-pure.
npm WARN deprecated core-js@3.21.1: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.

ERRORS:

npm ERR! code 1
npm ERR! path /Users/jerdog/dev/personal/jerdog-me-barcadia/node_modules/lmdb
npm ERR! command failed
npm ERR! command sh -c node-gyp-build
npm ERR! CXX(target) Release/obj.target/lmdb/src/lmdb-js.o
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@9.3.1
npm ERR! gyp info using node@19.3.0 | darwin | arm64
npm ERR! gyp info find Python using Python version 3.10.9 found at "/opt/homebrew/opt/python@3.10/bin/python3.10"
npm ERR! gyp info spawn /opt/homebrew/opt/python@3.10/bin/python3.10
npm ERR! gyp info spawn args [
npm ERR! gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/@npmcli/run-script/node_modules/node-gyp/gyp/gyp_main.py',
npm ERR! gyp info spawn args 'binding.gyp',
npm ERR! gyp info spawn args '-f',
npm ERR! gyp info spawn args 'make',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/jerdog/dev/personal/jerdog-me-barcadia/node_modules/lmdb/build/config.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/opt/homebrew/lib/node_modules/npm/node_modules/@npmcli/run-script/node_modules/node-gyp/addon.gypi',
npm ERR! gyp info spawn args '-I',
npm ERR! gyp info spawn args '/Users/jerdog/Library/Caches/node-gyp/19.3.0/include/node/common.gypi',
npm ERR! gyp info spawn args '-Dlibrary=shared_library',
npm ERR! gyp info spawn args '-Dvisibility=default',
npm ERR! gyp info spawn args '-Dnode_root_dir=/Users/jerdog/Library/Caches/node-gyp/19.3.0',
npm ERR! gyp info spawn args '-Dnode_gyp_dir=/opt/homebrew/lib/node_modules/npm/node_modules/@npmcli/run-script/node_modules/node-gyp',
npm ERR! gyp info spawn args '-Dnode_lib_file=/Users/jerdog/Library/Caches/node-gyp/19.3.0/<(target_arch)/node.lib',
npm ERR! gyp info spawn args '-Dmodule_root_dir=/Users/jerdog/dev/personal/jerdog-me-barcadia/node_modules/lmdb',
npm ERR! gyp info spawn args '-Dnode_engine=v8',
npm ERR! gyp info spawn args '--depth=.',
npm ERR! gyp info spawn args '--no-parallel',
npm ERR! gyp info spawn args '--generator-output',
npm ERR! gyp info spawn args 'build',
npm ERR! gyp info spawn args '-Goutput_dir=.'
npm ERR! gyp info spawn args ]
npm ERR! gyp info spawn make
npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
npm ERR! In file included from ../src/lmdb-js.cpp:1:
npm ERR! In file included from ../src/lmdb-js.h:32:
npm ERR! In file included from ../../nan/nan.h:178:
npm ERR! ../../nan/nan_callbacks.h:55:23: error: no member named 'AccessorSignature' in namespace 'v8'
npm ERR! typedef v8::Localv8::AccessorSignature Sig;
npm ERR! ~~~~^
npm ERR! In file included from ../src/lmdb-js.cpp:1:
npm ERR! In file included from ../src/lmdb-js.h:32:
npm ERR! ../../nan/nan.h:2544:8: error: no matching member function for call to 'SetAccessor'
npm ERR! tpl->SetAccessor(
npm ERR! ~~~~~^~~~~~~~~~~
npm ERR! /Users/jerdog/Library/Caches/node-gyp/19.3.0/include/node/v8-template.h:814:8: note: candidate function not viable: no known conversion from 'imp::Sig' (aka 'int') to 'v8::SideEffectType' for 7th argument
npm ERR! void SetAccessor(
npm ERR! ^
npm ERR! /Users/jerdog/Library/Caches/node-gyp/19.3.0/include/node/v8-template.h:807:8: note: candidate function not viable: no known conversion from 'imp::NativeGetter' (aka 'void ()(v8::Localv8::Name, const v8::PropertyCallbackInfov8::Value &)') to 'v8::AccessorGetterCallback' (aka 'void ()(Localv8::String, const PropertyCallbackInfov8::Value &)') for 2nd argument
npm ERR! void SetAccessor(
npm ERR! ^
npm ERR! 2 errors generated.
npm ERR! make: *** [Release/obj.target/lmdb/src/lmdb-js.o] Error 1
npm ERR! gyp ERR! build error
npm ERR! gyp ERR! stack Error: make failed with exit code: 2
npm ERR! gyp ERR! stack at ChildProcess.onExit (/opt/homebrew/lib/node_modules/npm/node_modules/@npmcli/run-script/node_modules/node-gyp/lib/build.js:203:23)
npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28)
npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:293:12)
npm ERR! gyp ERR! System Darwin 22.2.0
npm ERR! gyp ERR! command "/opt/homebrew/Cellar/node/19.3.0/bin/node" "/opt/homebrew/lib/node_modules/npm/node_modules/@npmcli/run-script/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
npm ERR! gyp ERR! cwd /Users/jerdog/dev/personal/jerdog-me-barcadia/node_modules/lmdb
npm ERR! gyp ERR! node -v v19.3.0
npm ERR! gyp ERR! node-gyp -v v9.3.1
npm ERR! gyp ERR! not ok

npm ERR! A complete log of this run can be found in:

ERROR UNKNOWN

Command failed with exit code 1: npm install

Error: Command failed with exit code 1: npm install

  • error.js:60 makeError
    [lib]/[gatsby-cli]/[execa]/lib/error.js:60:11

  • index.js:118 handlePromise
    [lib]/[gatsby-cli]/[execa]/index.js:118:26

  • task_queues:95 processTicksAndRejections
    node:internal/process/task_queues:95:5

  • init-starter.js:135 install
    [lib]/[gatsby-cli]/lib/init-starter.js:135:7

  • init-starter.js:202 clone
    [lib]/[gatsby-cli]/lib/init-starter.js:202:3

  • init-starter.js:343 initStarter
    [lib]/[gatsby-cli]/lib/init-starter.js:343:5

  • create-cli.js:458
    [lib]/[gatsby-cli]/lib/create-cli.js:458:9

This template / starter pack looks to be out of date. Any reasonably quick resolutions? Is this still supported?

The last build was completed using Node 14 so you will need to use that and the associated NPM version. The package is being maintained, but only when I have the free time to do it.

@bagseye do you happen to know the full NPM version you used? I'll put together a PR to make sure the NPM version is declared and deps are correct, but knowing the NPM version would be helpful.

i ran this on an earlier node version and got the following errors:

ERROR

(node:1506) ExperimentalWarning: The Fetch API is an experimental feature. This feature could
change at any time
(Use node --trace-warnings ... to show where the warning was created)

ERROR #gatsby-plugin-page-creator_12103 PLUGIN

PageCreator: Tried to create pages from the collection builder.
Unfortunately, the query came back empty. There may be an error in your query:

Cannot query field "allContentfulPage" on type "Query". Did you mean "allContentfulAsset",
"allContentfulEntry", "allContentfulTigerEye", or "contentfulAsset"?

ERROR

(node:1506) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 end
listeners added to [PassThrough]. Use emitter.setMaxListeners() to increase limit

I'm using node v - 18.0.0

Well, I know barcadia is on its last breath but I just used it for a project, so lets resolve this. It's pretty simple.
For node 18 installation, do this:

  1. remove package-lock.json
  2. if you have globally installed gatsby 5, you have to downgrade to 4.8ish
  3. instead of npm i, do npm i gatsby-plugin-robots-txt@1.6.14

the issue is that, for some reason, npm is pushing gatsby 5 + robots plugin 1.8 for node 18 which causes some compatiblity issue.

The OP error is just laziness - did not even try to remove package-lock.json:-)

This is quite old, and just needs closed since I moved on to something that worked and was updated, but I'll answer 😜

I did in fact remove the package-lock file, multiple times and multiple variations of things as a part of normal testing, but nothing worked. Appreciate the effort to get this working though.