How do I prevent this error during building an extension for jupyter lab? - jupyter

I am finding a difficulty in the following extension tutorial for jupyter labs.
While building the tutorial using
pip install -ve
I have the following error
run(npm_cmd + ["run", build_cmd], cwd=str(abs_path))
File "/tmp/pip-build-env-4een4_o_/normal/lib/python3.10/site-packages/hatch_jupyter_builder/utils.py", line 225, in run
return subprocess.check_call(cmd, **kwargs)
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/tmp/pip-build-env-4een4_o_/overlay/bin/jlpm', 'run', 'install:extension']' returned non-zero exit status 1.
error: subprocess-exited-with-error
× Preparing editable metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
full command: /home/savakar/miniconda3/envs/jupyterlab-ext/bin/python3.10 /home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_editable /tmp/tmpnb1xd5vq
cwd: /home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01
Preparing editable metadata (pyproject.toml) ... error
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
The entire error file is also attached here:
pip install -ve .
Using pip 22.2.2 from /home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip (python 3.10)
Obtaining file:///home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01
Running command pip subprocess to install build dependencies
Collecting hatchling>=1.3.1
Using cached hatchling-1.11.0-py3-none-any.whl (73 kB)
Collecting jupyterlab<4.0.0,>=3.4.7
Using cached jupyterlab-3.4.8-py3-none-any.whl (8.8 MB)
Collecting hatch-nodejs-version
Using cached hatch_nodejs_version-0.3.0-py3-none-any.whl (8.3 kB)
Collecting editables>=0.3
Using cached editables-0.3-py3-none-any.whl (4.7 kB)
Collecting packaging>=21.3
Using cached packaging-21.3-py3-none-any.whl (40 kB)
Collecting pathspec>=0.10.1
Using cached pathspec-0.10.1-py3-none-any.whl (27 kB)
Collecting tomli>=1.2.2
Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting pluggy>=1.0.0
Using cached pluggy-1.0.0-py2.py3-none-any.whl (13 kB)
Collecting jupyter-server~=1.16
Using cached jupyter_server-1.19.1-py3-none-any.whl (346 kB)
Collecting jupyter-core
Using cached jupyter_core-4.11.1-py3-none-any.whl (88 kB)
Collecting ipython
Using cached ipython-8.5.0-py3-none-any.whl (752 kB)
Collecting jupyterlab-server~=2.10
Using cached jupyterlab_server-2.15.2-py3-none-any.whl (54 kB)
Collecting notebook<7
Using cached notebook-6.4.12-py3-none-any.whl (9.9 MB)
Collecting jinja2>=2.1
Using cached Jinja2-3.1.2-py3-none-any.whl (133 kB)
Collecting nbclassic
Using cached nbclassic-0.4.5-py3-none-any.whl (9.8 MB)
Collecting tornado>=6.1.0
Using cached tornado-6.2-cp37-abi3-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (423 kB)
Collecting MarkupSafe>=2.0
Using cached MarkupSafe-2.1.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (25 kB)
Collecting Send2Trash
Using cached Send2Trash-1.8.0-py3-none-any.whl (18 kB)
Collecting anyio<4,>=3.1.0
Using cached anyio-3.6.1-py3-none-any.whl (80 kB)
Collecting nbconvert>=6.4.4
Using cached nbconvert-7.2.1-py3-none-any.whl (271 kB)
Collecting prometheus-client
Using cached prometheus_client-0.14.1-py3-none-any.whl (59 kB)
Collecting pyzmq>=17
Using cached pyzmq-24.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.1 MB)
Collecting traitlets>=5.1
Using cached traitlets-5.4.0-py3-none-any.whl (107 kB)
Collecting terminado>=0.8.3
Using cached terminado-0.16.0-py3-none-any.whl (16 kB)
Collecting argon2-cffi
Using cached argon2_cffi-21.3.0-py3-none-any.whl (14 kB)
Collecting jupyter-client>=6.1.12
Using cached jupyter_client-7.3.5-py3-none-any.whl (132 kB)
Collecting nbformat>=5.2.0
Using cached nbformat-5.7.0-py3-none-any.whl (77 kB)
Collecting websocket-client
Using cached websocket_client-1.4.1-py3-none-any.whl (55 kB)
Collecting babel
Using cached Babel-2.10.3-py3-none-any.whl (9.5 MB)
Collecting jsonschema>=3.0.1
Using cached jsonschema-4.16.0-py3-none-any.whl (83 kB)
Collecting requests
Using cached requests-2.28.1-py3-none-any.whl (62 kB)
Collecting json5
Using cached json5-0.9.10-py2.py3-none-any.whl (19 kB)
Collecting nest-asyncio>=1.5
Using cached nest_asyncio-1.5.6-py3-none-any.whl (5.2 kB)
Collecting ipython-genutils
Using cached ipython_genutils-0.2.0-py2.py3-none-any.whl (26 kB)
Collecting ipykernel
Using cached ipykernel-6.16.0-py3-none-any.whl (138 kB)
Collecting pyparsing!=3.0.5,>=2.0.2
Using cached pyparsing-3.0.9-py3-none-any.whl (98 kB)
Collecting backcall
Using cached backcall-0.2.0-py2.py3-none-any.whl (11 kB)
Collecting pexpect>4.3
Using cached pexpect-4.8.0-py2.py3-none-any.whl (59 kB)
Collecting stack-data
Using cached stack_data-0.5.1-py3-none-any.whl (24 kB)
Collecting pickleshare
Using cached pickleshare-0.7.5-py2.py3-none-any.whl (6.9 kB)
Collecting decorator
Using cached decorator-5.1.1-py3-none-any.whl (9.1 kB)
Collecting matplotlib-inline
Using cached matplotlib_inline-0.1.6-py3-none-any.whl (9.4 kB)
Collecting prompt-toolkit<3.1.0,>3.0.1
Using cached prompt_toolkit-3.0.31-py3-none-any.whl (382 kB)
Collecting pygments>=2.4.0
Using cached Pygments-2.13.0-py3-none-any.whl (1.1 MB)
Collecting jedi>=0.16
Using cached jedi-0.18.1-py2.py3-none-any.whl (1.6 MB)
Collecting notebook-shim>=0.1.0
Using cached notebook_shim-0.1.0-py3-none-any.whl (13 kB)
Collecting sniffio>=1.1
Using cached sniffio-1.3.0-py3-none-any.whl (10 kB)
Collecting idna>=2.8
Using cached idna-3.4-py3-none-any.whl (61 kB)
Collecting parso<0.9.0,>=0.8.0
Using cached parso-0.8.3-py2.py3-none-any.whl (100 kB)
Collecting attrs>=17.4.0
Using cached attrs-22.1.0-py2.py3-none-any.whl (58 kB)
Collecting pyrsistent!=0.17.0,!=0.17.1,!=0.17.2,>=0.14.0
Using cached pyrsistent-0.18.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (115 kB)
Collecting python-dateutil>=2.8.2
Using cached python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting entrypoints
Using cached entrypoints-0.4-py3-none-any.whl (5.3 kB)
Collecting tinycss2
Using cached tinycss2-1.1.1-py3-none-any.whl (21 kB)
Collecting nbclient>=0.5.0
Using cached nbclient-0.7.0-py3-none-any.whl (71 kB)
Collecting beautifulsoup4
Using cached beautifulsoup4-4.11.1-py3-none-any.whl (128 kB)
Collecting pandocfilters>=1.4.1
Using cached pandocfilters-1.5.0-py2.py3-none-any.whl (8.7 kB)
Collecting bleach
Using cached bleach-5.0.1-py3-none-any.whl (160 kB)
Collecting defusedxml
Using cached defusedxml-0.7.1-py2.py3-none-any.whl (25 kB)
Collecting mistune<3,>=2.0.3
Using cached mistune-2.0.4-py2.py3-none-any.whl (24 kB)
Collecting jupyterlab-pygments
Using cached jupyterlab_pygments-0.2.2-py2.py3-none-any.whl (21 kB)
Collecting fastjsonschema
Using cached fastjsonschema-2.16.2-py3-none-any.whl (22 kB)
Collecting ptyprocess>=0.5
Using cached ptyprocess-0.7.0-py2.py3-none-any.whl (13 kB)
Collecting wcwidth
Using cached wcwidth-0.2.5-py2.py3-none-any.whl (30 kB)
Collecting argon2-cffi-bindings
Using cached argon2_cffi_bindings-21.2.0-cp36-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (86 kB)
Collecting pytz>=2015.7
Using cached pytz-2022.4-py2.py3-none-any.whl (500 kB)
Collecting psutil
Using cached psutil-5.9.2-cp310-cp310-manylinux_2_12_x86_64.manylinux2010_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (282 kB)
Collecting debugpy>=1.0
Using cached debugpy-1.6.3-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_12_x86_64.manylinux2010_x86_64.whl (1.8 MB)
Collecting charset-normalizer<3,>=2
Using cached charset_normalizer-2.1.1-py3-none-any.whl (39 kB)
Collecting certifi>=2017.4.17
Using cached certifi-2022.9.24-py3-none-any.whl (161 kB)
Collecting urllib3<1.27,>=1.21.1
Using cached urllib3-1.26.12-py2.py3-none-any.whl (140 kB)
Collecting executing
Using cached executing-1.1.1-py2.py3-none-any.whl (22 kB)
Collecting asttokens
Using cached asttokens-2.0.8-py2.py3-none-any.whl (23 kB)
Collecting pure-eval
Using cached pure_eval-0.2.2-py3-none-any.whl (11 kB)
Collecting six>=1.5
Using cached six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting cffi>=1.0.1
Using cached cffi-1.15.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (441 kB)
Collecting soupsieve>1.2
Using cached soupsieve-2.3.2.post1-py3-none-any.whl (37 kB)
Collecting webencodings
Using cached webencodings-0.5.1-py2.py3-none-any.whl (11 kB)
Collecting pycparser
Using cached pycparser-2.21-py2.py3-none-any.whl (118 kB)
Installing collected packages: webencodings, wcwidth, Send2Trash, pytz, pure-eval, ptyprocess, pickleshare, mistune, json5, ipython-genutils, fastjsonschema, executing, backcall, websocket-client, urllib3, traitlets, tornado, tomli, tinycss2, soupsieve, sniffio, six, pyzmq, pyrsistent, pyparsing, pygments, pycparser, psutil, prompt-toolkit, prometheus-client, pluggy, pexpect, pathspec, parso, pandocfilters, nest-asyncio, MarkupSafe, jupyterlab-pygments, idna, entrypoints, editables, defusedxml, decorator, debugpy, charset-normalizer, certifi, babel, attrs, terminado, requests, python-dateutil, packaging, matplotlib-inline, jupyter-core, jsonschema, jinja2, jedi, cffi, bleach, beautifulsoup4, asttokens, anyio, stack-data, nbformat, jupyter-client, hatchling, argon2-cffi-bindings, nbclient, ipython, hatch-nodejs-version, argon2-cffi, nbconvert, ipykernel, notebook, jupyter-server, notebook-shim, jupyterlab-server, nbclassic, jupyterlab
Successfully installed MarkupSafe-2.1.1 Send2Trash-1.8.0 anyio-3.6.1 argon2-cffi-21.3.0 argon2-cffi-bindings-21.2.0 asttokens-2.0.8 attrs-22.1.0 babel-2.10.3 backcall-0.2.0 beautifulsoup4-4.11.1 bleach-5.0.1 certifi-2022.9.24 cffi-1.15.1 charset-normalizer-2.1.1 debugpy-1.6.3 decorator-5.1.1 defusedxml-0.7.1 editables-0.3 entrypoints-0.4 executing-1.1.1 fastjsonschema-2.16.2 hatch-nodejs-version-0.3.0 hatchling-1.11.0 idna-3.4 ipykernel-6.16.0 ipython-8.5.0 ipython-genutils-0.2.0 jedi-0.18.1 jinja2-3.1.2 json5-0.9.10 jsonschema-4.16.0 jupyter-client-7.3.5 jupyter-core-4.11.1 jupyter-server-1.19.1 jupyterlab-3.4.8 jupyterlab-pygments-0.2.2 jupyterlab-server-2.15.2 matplotlib-inline-0.1.6 mistune-2.0.4 nbclassic-0.4.5 nbclient-0.7.0 nbconvert-7.2.1 nbformat-5.7.0 nest-asyncio-1.5.6 notebook-6.4.12 notebook-shim-0.1.0 packaging-21.3 pandocfilters-1.5.0 parso-0.8.3 pathspec-0.10.1 pexpect-4.8.0 pickleshare-0.7.5 pluggy-1.0.0 prometheus-client-0.14.1 prompt-toolkit-3.0.31 psutil-5.9.2 ptyprocess-0.7.0 pure-eval-0.2.2 pycparser-2.21 pygments-2.13.0 pyparsing-3.0.9 pyrsistent-0.18.1 python-dateutil-2.8.2 pytz-2022.4 pyzmq-24.0.1 requests-2.28.1 six-1.16.0 sniffio-1.3.0 soupsieve-2.3.2.post1 stack-data-0.5.1 terminado-0.16.0 tinycss2-1.1.1 tomli-2.0.1 tornado-6.2 traitlets-5.4.0 urllib3-1.26.12 wcwidth-0.2.5 webencodings-0.5.1 websocket-client-1.4.1
Installing build dependencies ... done
Running command Checking if build backend supports build_editable
Checking if build backend supports build_editable ... done
Running command Getting requirements to build editable
Getting requirements to build editable ... done
Running command pip subprocess to install backend dependencies
Collecting hatch-jupyter-builder>=0.5
Using cached hatch_jupyter_builder-0.8.0-py3-none-any.whl (17 kB)
Collecting hatchling
Using cached hatchling-1.11.0-py3-none-any.whl (73 kB)
Collecting pathspec>=0.10.1
Using cached pathspec-0.10.1-py3-none-any.whl (27 kB)
Collecting packaging>=21.3
Using cached packaging-21.3-py3-none-any.whl (40 kB)
Collecting tomli>=1.2.2
Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting pluggy>=1.0.0
Using cached pluggy-1.0.0-py2.py3-none-any.whl (13 kB)
Collecting editables>=0.3
Using cached editables-0.3-py3-none-any.whl (4.7 kB)
Collecting pyparsing!=3.0.5,>=2.0.2
Using cached pyparsing-3.0.9-py3-none-any.whl (98 kB)
Installing collected packages: tomli, pyparsing, pluggy, pathspec, editables, packaging, hatchling, hatch-jupyter-builder
Successfully installed editables-0.3 hatch-jupyter-builder-0.8.0 hatchling-1.11.0 packaging-21.3 pathspec-0.10.1 pluggy-1.0.0 pyparsing-3.0.9 tomli-2.0.1
Installing backend dependencies ... done
Running command Preparing editable metadata (pyproject.toml)
INFO:hatch_jupyter_builder.utils:Running jupyter-builder
INFO:hatch_jupyter_builder.utils:Building with hatch_jupyter_builder.npm_builder
INFO:hatch_jupyter_builder.utils:With kwargs: {'build_cmd': 'install:extension', 'npm': ['jlpm'], 'source_dir': 'src', 'build_dir': 'stockWhiz01/labextension'}
INFO:hatch_jupyter_builder.utils:Installing build dependencies with npm. This may take a while...
INFO:hatch_jupyter_builder.utils:> /tmp/pip-build-env-4een4_o_/overlay/bin/jlpm install
yarn install v1.21.1
info No lockfile found.
[1/4] Resolving packages...
warning #jupyterlab/application > #jupyterlab/apputils > url > querystring#0.2.0: The querystring API is considered Legacy. new code should use the URLSearchParams API instead.
warning #jupyterlab/application > #jupyterlab/ui-components > #blueprintjs/core > popper.js#1.16.1: You can find the new Popper v2 at #popperjs/core, this package is dedicated to the legacy v1
warning #jupyterlab/application > #jupyterlab/ui-components > #blueprintjs/core > react-popper > popper.js#1.16.1: You can find the new Popper v2 at #popperjs/core, this package is dedicated to the legacy v1
warning #jupyterlab/builder > #jupyterlab/buildutils > crypto#1.0.1: This package is no longer supported. It's now a built-in Node module. If you've depended on crypto, you should switch to the one that's built-in.
warning #jupyterlab/builder > #jupyterlab/buildutils > verdaccio > request#2.88.0: request has been deprecated, see https://github.com/request/request/issues/3142
warning #jupyterlab/builder > #jupyterlab/buildutils > verdaccio > request > har-validator#5.1.5: this library is no longer supported
warning #jupyterlab/builder > #jupyterlab/buildutils > verdaccio > request > 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.
warning #jupyterlab/testutils > jest-junit > 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.
warning #jupyterlab/testutils > jest > #jest/core > jest-haste-map > sane#4.1.0: some dependency vulnerabilities fixed, support for node < 10 dropped, and newer ECMAScript syntax/features added
warning #jupyterlab/testutils > jest > #jest/core > jest-haste-map > sane > micromatch > snapdragon > source-map-resolve#0.5.3: See https://github.com/lydell/source-map-resolve#deprecated
warning #jupyterlab/testutils > jest > #jest/core > jest-haste-map > sane > micromatch > snapdragon > source-map-resolve > resolve-url#0.2.1: https://github.com/lydell/resolve-url#deprecated
warning #jupyterlab/testutils > jest > #jest/core > jest-haste-map > sane > micromatch > snapdragon > source-map-resolve > urix#0.1.0: Please see https://github.com/lydell/urix#deprecated
warning #jupyterlab/testutils > jest > #jest/core > jest-haste-map > sane > micromatch > snapdragon > source-map-resolve > source-map-url#0.4.1: See https://github.com/lydell/source-map-url#deprecated
[2/4] Fetching packages...
info fsevents#2.3.2: The platform "linux" is incompatible with this module.
info "fsevents#2.3.2" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
warning "#jupyterlab/application > #jupyterlab/ui-components#3.4.8" has unmet peer dependency "react#^17.0.1".
warning "#jupyterlab/application > #lumino/coreutils#1.12.1" has unmet peer dependency "crypto#1.0.1".
warning "#jupyterlab/application > #jupyterlab/rendermime > #jupyterlab/codemirror > y-codemirror#3.0.1" has unmet peer dependency "yjs#^13.5.17".
warning "#jupyterlab/builder > #jupyterlab/buildutils > verdaccio > clipanion#3.1.0" has unmet peer dependency "typanion#*".
warning Workspaces can only be enabled in private projects.
warning Workspaces can only be enabled in private projects.
[4/4] Building fresh packages...
success Saved lockfile.
Done in 384.66s.
INFO:hatch_jupyter_builder.utils:> /tmp/pip-build-env-4een4_o_/overlay/bin/jlpm run install:extension
yarn run v1.21.1
$ jlpm build
$ jlpm build:lib && jlpm build:labextension:dev
$ tsc
$ jupyter labextension build --development True .
Building extension in .
/home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01/node_modules/typescript/lib/typescript.js:141092
changeTracker.replaceNode(propertyDeclarationSo
^^^^^^^^^^^^^^^^^^^^^
SyntaxError: missing ) after argument list
at Object.compileFunction (node:vm:360:18)
at wrapSafe (node:internal/modules/cjs/loader:1078:15)
at Module._compile (node:internal/modules/cjs/loader:1113:27)
at Module._extensions..js (node:internal/modules/cjs/loader:1203:10)
at Module.load (node:internal/modules/cjs/loader:1027:32)
at Module._load (node:internal/modules/cjs/loader:868:12)
at Module.require (node:internal/modules/cjs/loader:1051:19)
at require (node:internal/modules/cjs/helpers:103:18)
at Object.<anonymous> (/home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01/node_modules/#jupyterlab/buildutils/lib/ensure-package.js:32:25)
at Module._compile (node:internal/modules/cjs/loader:1149:14)
Node.js v18.10.0
An error occurred.
subprocess.CalledProcessError: Command '['node', '/home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01/node_modules/#jupyterlab/builder/lib/build-labextension.js', '--core-path', '/tmp/pip-build-env-4een4_o_/overlay/lib/python3.10/site-packages/jupyterlab/staging', '/home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01', '--development']' returned non-zero exit status 1.
See the log file for details: /tmp/jupyterlab-debug-logmwuri.log
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
Traceback (most recent call last):
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 177, in prepare_metadata_for_build_editable
hook = backend.prepare_metadata_for_build_editable
AttributeError: module 'hatchling.build' has no attribute 'prepare_metadata_for_build_editable'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 363, in <module>
main()
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 345, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 186, in prepare_metadata_for_build_editable
whl_basename = build_hook(metadata_directory, config_settings)
File "/tmp/pip-build-env-4een4_o_/overlay/lib/python3.10/site-packages/hatchling/build.py", line 61, in build_editable
return os.path.basename(next(builder.build(wheel_directory, ['editable'])))
File "/tmp/pip-build-env-4een4_o_/overlay/lib/python3.10/site-packages/hatchling/builders/plugin/interface.py", line 136, in build
build_hook.initialize(version, build_data)
File "/tmp/pip-build-env-4een4_o_/normal/lib/python3.10/site-packages/hatch_jupyter_builder/plugin.py", line 83, in initialize
raise e
File "/tmp/pip-build-env-4een4_o_/normal/lib/python3.10/site-packages/hatch_jupyter_builder/plugin.py", line 78, in initialize
build_func(self.target_name, version, **build_kwargs)
File "/tmp/pip-build-env-4een4_o_/normal/lib/python3.10/site-packages/hatch_jupyter_builder/utils.py", line 116, in npm_builder
run(npm_cmd + ["run", build_cmd], cwd=str(abs_path))
File "/tmp/pip-build-env-4een4_o_/normal/lib/python3.10/site-packages/hatch_jupyter_builder/utils.py", line 225, in run
return subprocess.check_call(cmd, **kwargs)
File "/home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/subprocess.py", line 369, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/tmp/pip-build-env-4een4_o_/overlay/bin/jlpm', 'run', 'install:extension']' returned non-zero exit status 1.
error: subprocess-exited-with-error
× Preparing editable metadata (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
full command: /home/savakar/miniconda3/envs/jupyterlab-ext/bin/python3.10 /home/savakar/miniconda3/envs/jupyterlab-ext/lib/python3.10/site-packages/pip/_vendor/pep517/in_process/_in_process.py prepare_metadata_for_build_editable /tmp/tmpnb1xd5vq
cwd: /home/savakar/Documents/PROJECTS/JupyterLabExtension/stockWhiz01
Preparing editable metadata (pyproject.toml) ... error
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Could you please direct me towards a solution.
--- edit
There is no mention of the hatchling file during pip freeze command.
flit_core # file:///home/conda/feedstock_root/build_artifacts/flit-core_1645629044586/work/source/flit_core
idna # file:///home/conda/feedstock_root/build_artifacts/idna_1663625384323/work
whereas during the the install command the first package collected is hatchling.

Related

How to fix this error for installing AutoGluon on Linux

I am trying to install AutoGluon on my university computer (Linux)
I followed the instruction given here https://auto.gluon.ai/stable/index.html
pip3 install -U pip
pip3 install -U setuptools wheel
# CPU version of pytorch has smaller footprint - see installation instructions in
# pytorch documentation - https://pytorch.org/get-started/locally/
pip3 install torch==1.12+cpu torchvision==0.13.0+cpu torchtext==0.13.0 -f https://download.pytorch.org/whl/cpu/torch_stable.html
pip3 install autogluon
all steps ended successfully except for the last one pip3 install autogluon
I am getting this error
user99#tinaroo1:~/autogluon> pip3 install autogluon
Keyring is skipped due to an exception: 'EntryPoints' object has no attribute 'get'
Defaulting to user installation because normal site-packages is not writeable
Collecting autogluon
Using cached autogluon-0.6.0-py3-none-any.whl (9.8 kB)
Collecting autogluon.multimodal==0.6.0
Using cached autogluon.multimodal-0.6.0-py3-none-any.whl (279 kB)
Collecting autogluon.timeseries[all]==0.6.0
Using cached autogluon.timeseries-0.6.0-py3-none-any.whl (101 kB)
Collecting autogluon.features==0.6.0
Using cached autogluon.features-0.6.0-py3-none-any.whl (59 kB)
Collecting autogluon.core[all]==0.6.0
Using cached autogluon.core-0.6.0-py3-none-any.whl (224 kB)
Collecting autogluon.vision==0.6.0
Using cached autogluon.vision-0.6.0-py3-none-any.whl (49 kB)
Collecting autogluon.tabular[all]==0.6.0
Using cached autogluon.tabular-0.6.0-py3-none-any.whl (285 kB)
Collecting autogluon.text==0.6.0
Using cached autogluon.text-0.6.0-py3-none-any.whl (62 kB)
Requirement already satisfied: numpy<1.24,>=1.21 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (1.21.5)
Requirement already satisfied: scipy<1.10.0,>=1.5.4 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (1.7.1)
Collecting autogluon.common==0.6.0
Using cached autogluon.common-0.6.0-py3-none-any.whl (41 kB)
Requirement already satisfied: matplotlib in /mnt/sw/legacy/sw1/RCC/Anaconda/2020.02/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (3.2.2)
Requirement already satisfied: tqdm>=4.38.0 in /mnt/sw/legacy/sw1/RCC/Anaconda/2020.02/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (4.47.0)
Requirement already satisfied: requests in /mnt/sw/legacy/sw1/RCC/Anaconda/2020.02/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (2.24.0)
Requirement already satisfied: scikit-learn<1.2,>=1.0.0 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (1.0.2)
Requirement already satisfied: pandas!=1.4.0,<1.6,>=1.2.5 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (1.3.5)
Requirement already satisfied: boto3 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (1.26.23)
Requirement already satisfied: dask<=2021.11.2,>=2021.09.1 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (2021.11.2)
Requirement already satisfied: distributed<=2021.11.2,>=2021.09.1 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (2021.11.2)
Requirement already satisfied: ray<2.1,>=2.0 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (2.0.1)
Requirement already satisfied: hyperopt<0.2.8,>=0.2.7 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.core[all]==0.6.0->autogluon) (0.2.7)
Requirement already satisfied: psutil<6,>=5.7.3 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.features==0.6.0->autogluon) (5.9.4)
Collecting seqeval<=1.2.2
Using cached seqeval-1.2.2.tar.gz (43 kB)
Preparing metadata (setup.py) ... done
Collecting omegaconf<2.2.0,>=2.1.1
Using cached omegaconf-2.1.2-py3-none-any.whl (74 kB)
Collecting scikit-image<0.20.0,>=0.19.1
Using cached scikit_image-0.19.3-cp37-cp37m-manylinux_2_12_x86_64.manylinux2010_x86_64.whl (13.5 MB)
Collecting sentencepiece<0.2.0,>=0.1.95
Using cached sentencepiece-0.1.97-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (1.3 MB)
Collecting torchmetrics<0.9.0,>=0.8.0
Using cached torchmetrics-0.8.2-py3-none-any.whl (409 kB)
Requirement already satisfied: torchvision<0.14.0 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.multimodal==0.6.0->autogluon) (0.13.0+cpu)
Collecting accelerate<0.14,>=0.9
Using cached accelerate-0.13.2-py3-none-any.whl (148 kB)
Collecting evaluate<=0.2.2
Using cached evaluate-0.2.2-py3-none-any.whl (69 kB)
Collecting nptyping<1.5.0,>=1.4.4
Using cached nptyping-1.4.4-py3-none-any.whl (31 kB)
Collecting defusedxml<=0.7.1,>=0.7.1
Using cached defusedxml-0.7.1-py2.py3-none-any.whl (25 kB)
Collecting openmim<=0.2.1,>0.1.5
Using cached openmim-0.2.1-py2.py3-none-any.whl (49 kB)
Requirement already satisfied: torchtext<0.14.0 in /home/user99/.local/lib/python3.7/site-packages (from autogluon.multimodal==0.6.0->autogluon) (0.13.0)
Collecting albumentations<=1.2.0,>=1.1.0
Using cached albumentations-1.2.0-py3-none-any.whl (113 kB)
Collecting pycocotools<2.0.7,>=2.0.5
Using cached pycocotools-2.0.6.tar.gz (24 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... error
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: -11
╰─> [35 lines of output]
OpenBLAS blas_thread_init: pthread_create: Resource temporarily unavailable
OpenBLAS blas_thread_init: RLIMIT_NPROC 50 current, 514567 max
OpenBLAS blas_thread_init: pthread_create: Resource temporarily unavailable
OpenBLAS blas_thread_init: RLIMIT_NPROC 50 current, 514567 max
OpenBLAS blas_thread_init: pthread_create: Resource temporarily unavailable
OpenBLAS blas_thread_init: RLIMIT_NPROC 50 current, 514567 max
OpenBLAS blas_thread_init: pthread_create: Resource temporarily unavailable
OpenBLAS blas_thread_init: RLIMIT_NPROC 50 current, 514567 max
OpenBLAS blas_thread_init: pthread_create: Resource temporarily unavailable
OpenBLAS blas_thread_init: RLIMIT_NPROC 50 current, 514567 max
Traceback (most recent call last):
File "/home/user99/.local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 351, in <module>
main()
File "/home/user99/.local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 333, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File "/home/user99/.local/lib/python3.7/site-packages/pip/_vendor/pep517/in_process/_in_process.py", line 118, in get_requires_for_build_wheel
return hook(config_settings)
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/setuptools/build_meta.py", line 338, in get_requires_for_build_wheel
return self._get_build_requires(config_settings, requirements=['wheel'])
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/setuptools/build_meta.py", line 320, in _get_build_requires
self.run_setup()
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/setuptools/build_meta.py", line 335, in run_setup
exec(code, locals())
File "<string>", line 7, in <module>
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/numpy/__init__.py", line 142, in <module>
from . import add_newdocs
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/numpy/add_newdocs.py", line 13, in <module>
from numpy.lib import add_newdoc
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/numpy/lib/__init__.py", line 8, in <module>
from .type_check import *
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/numpy/lib/type_check.py", line 11, in <module>
import numpy.core.numeric as _nx
File "/scratch/user/user99/tmp/pip-build-env-j7xhslnv/overlay/lib/python3.7/site-packages/numpy/core/__init__.py", line 16, in <module>
from . import multiarray
KeyboardInterrupt
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× Getting requirements to build wheel did not run successfully.
│ exit code: -11
╰─> See above for output.
note: This error originates from a subprocess, and is likely not a problem with pip.
user99#tinaroo1:~/autogluon>
I wonder if it makes sense to anyone and can help me fixing that.

AWS Elastic Beanstalk failed to install psycopg2 using requirements.txt Git Pip

I am trying to deploy an app using elasticbeanstalk with Python 3.8. I am using the following requirements.txt
click==8.0.1
Flask==1.1.2
Flask-SQLAlchemy==2.5.1
greenlet==1.1.0
itsdangerous==2.0.1
Jinja2==3.0.1
MarkupSafe==2.0.1
marshmallow==3.12.1
marshmallow-sqlalchemy==0.25.0
SQLAlchemy==1.4.15
Werkzeug==2.0.1
celery[redis]
psycopg2==2.9.3
Flask-JWT-Extended==4.3.1
Flask-RESTful==0.3.9
python-decouple==3.6
When I run the command eb create, I get the following error
2022-04-05 22:03:00 INFO Created security group named: sg-00b14485064e5e8ca
2022-04-05 22:03:16 INFO Created security group named: awseb-e-ekd3bw2bvf-stack-AWSEBSecurityGroup-1O3NAVBIRRK30
2022-04-05 22:03:31 INFO Created Auto Scaling launch configuration named: awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingLaunchConfiguration-HKjIVsa84E3U
2022-04-05 22:04:49 INFO Created Auto Scaling group named: awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingGroup-5FQOAWMGCR3W
2022-04-05 22:04:49 INFO Waiting for EC2 instances to launch. This may take a few minutes.
2022-04-05 22:04:49 INFO Created Auto Scaling group policy named: arn:aws:autoscaling:us-east-1:208357543212:scalingPolicy:ecfbbff0-4151-492f-a474-ba01535ad348:autoScalingGroupName/awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingGroup-5FQOAWMGCR3W:policyName/awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingScaleDownPolicy-CI2UIP6X023P
2022-04-05 22:04:49 INFO Created Auto Scaling group policy named: arn:aws:autoscaling:us-east-1:208357543212:scalingPolicy:d534189a-45e3-48f1-a206-720f202b4469:autoScalingGroupName/awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingGroup-5FQOAWMGCR3W:policyName/awseb-e-ekd3bw2bvf-stack-AWSEBAutoScalingScaleUpPolicy-1F0WVTUXXPFKF
2022-04-05 22:05:04 INFO Created CloudWatch alarm named: awseb-e-ekd3bw2bvf-stack-AWSEBCloudwatchAlarmLow-W8URMJEYBO3C
2022-04-05 22:05:04 INFO Created CloudWatch alarm named: awseb-e-ekd3bw2bvf-stack-AWSEBCloudwatchAlarmHigh-13J8QHI51MEBM
2022-04-05 22:06:09 INFO Created load balancer named: arn:aws:elasticloadbalancing:us-east-1:208357543212:loadbalancer/app/awseb-AWSEB-IXOR2Z0K0OJV/1fba4c6ff6122c55
2022-04-05 22:06:24 INFO Created Load Balancer listener named: arn:aws:elasticloadbalancing:us-east-1:208357543212:listener/app/awseb-AWSEB-IXOR2Z0K0OJV/1fba4c6ff6122c55/734b0cf960b6b8c4
2022-04-05 22:06:42 ERROR Instance deployment failed to install application dependencies. The deployment failed.
2022-04-05 22:06:42 ERROR Instance deployment failed. For details, see 'eb-engine.log'.
2022-04-05 22:06:44 ERROR [Instance: i-0368a7ba2157241f4] Command failed on instance. Return code: 1 Output: Engine execution has encountered an error..
2022-04-05 22:06:45 INFO Command execution completed on all instances. Summary: [Successful: 0, Failed: 1].
2022-04-05 22:07:48 ERROR Create environment operation is complete, but with errors. For more information, see troubleshooting documentation.
I look at the corresponding logs and I get the following error:
Collecting Werkzeug==2.0.1
Downloading Werkzeug-2.0.1-py3-none-any.whl (288 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 288.2/288.2 KB 35.6 MB/s eta 0:00:00
Collecting celery[redis]
Downloading celery-5.2.6-py3-none-any.whl (405 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 405.6/405.6 KB 54.7 MB/s eta 0:00:00
Collecting psycopg2==2.9.3
Downloading psycopg2-2.9.3.tar.gz (380 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 380.6/380.6 KB 52.2 MB/s eta 0:00:00
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'error'
2022/04/05 22:06:42.952376 [INFO] error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [23 lines of output]
running egg_info
creating /tmp/pip-pip-egg-info-v0aygozt/psycopg2.egg-info
writing /tmp/pip-pip-egg-info-v0aygozt/psycopg2.egg-info/PKG-INFO
writing dependency_links to /tmp/pip-pip-egg-info-v0aygozt/psycopg2.egg-info/dependency_links.txt
writing top-level names to /tmp/pip-pip-egg-info-v0aygozt/psycopg2.egg-info/top_level.txt
writing manifest file '/tmp/pip-pip-egg-info-v0aygozt/psycopg2.egg-info/SOURCES.txt'
Error: pg_config executable not found.
pg_config is required to build psycopg2 from source. Please add the directory
containing pg_config to the $PATH or specify the full executable path with the
option:
python setup.py build_ext --pg-config /path/to/pg_config build ...
or with the pg_config option in 'setup.cfg'.
If you prefer to avoid building psycopg2 from source, please install the PyPI
'psycopg2-binary' package instead.
For further information please check the 'doc/src/install.rst' file (also at
<https://www.psycopg.org/docs/install.html>).
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
I am not quite familiar with the requirements of AWS, but I could run the app locally and without any problem. I just wonder what would be a right configuration for the requirements.txt file in order to avoid the bug.
Thanks in advance.
You have to install postgresql-devel first before you can use psycopg2. You can add the installation instructions to your ebextentions:
packages:
yum:
postgresql-devel: []
or
commands:
command1:
command: yum install -y postgresql-devel
I could solve the error. I have to change psycopg2 by psycopg2-binary as it was suggested by the AWS logs:
If you prefer to avoid building psycopg2 from source, please install the PyPI
'psycopg2-binary' package instead.
This issue has to be with the particular configuration of the libraries and the specific Linux machines used in AWS.

ESP32 JTAG Programming fails at Verification

The code is working. I can build it and to mention. it was working, i could upload it to my custom made ESP32 board. From all of a sudden it stopped working. Tried with different PCB boards also different cables.
I somehow resolved my problem so i can program it, but now i get a verification error after Programming Finished
Here is my complete log from terminal.
Processing esp32dev (platform: espressif32; board: esp32dev; framework: espidf)
-----------------------------------------------------------------------------------------------------------
Verbose mode can be enabled via `-v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32dev.html
PLATFORM: Espressif 32 (3.4.0) > Espressif ESP32 Dev Module
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
- framework-espidf 3.40301.0 (4.3.1)
- tool-cmake 3.16.4
- tool-esptoolpy 1.30100.210531 (3.1.0)
- tool-mkspiffs 2.230.0 (2.30)
- tool-ninja 1.9.0
- tool-openocd-esp32 2.1000.20210721 (10.0)
- toolchain-esp32ulp 1.22851.191205 (2.28.51)
- toolchain-riscv32-esp 8.4.0+2021r1
- toolchain-xtensa-esp32 8.4.0+2021r1
- toolchain-xtensa-esp32s2 8.4.0+2021r1
Reading CMake configuration...
LDF: Library Dependency Finder ->
LDF Modes: Finder ~ chain, Compatibility ~ soft
Found 0 compatible libraries
Scanning dependencies...
No dependencies
Building in debug mode
Retrieving maximum program size .pio/build/esp32dev/firmware.elf
Checking size .pio/build/esp32dev/firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [= ] 10.1% (used 32992 bytes from 327680 bytes)
Flash: [======== ] 75.7% (used 794197 bytes from 1048576 bytes)
Configuring upload protocol...
AVAILABLE: esp-prog, espota, esptool, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa
CURRENT: upload_protocol = esp-prog
Uploading .pio/build/esp32dev/firmware.bin
Open On-Chip Debugger v0.10.0-esp32-20210721 (2021-07-21-13:34)
Licensed under GNU GPL v2
For bug reports, read
http://openocd.org/doc/doxygen/bugs.html
debug_level: 1
adapter speed: 20000 kHz
WARNING: boards/esp-wroom-32.cfg is deprecated, and may be removed in a future release.
adapter speed: 2000 kHz
** Programming Started **
** Programming Finished **
** Verify Started **
Error: **** Verification failure! ****
Error: target_hash cbc6a9...992065
Error: file_hash: 773d62...93803f
embedded:startup.tcl:449: Error: ** Verify Failed **
in procedure 'program_esp'
in procedure 'program_error' called at file "/Users/USER/.platformio/packages/tool-openocd-esp32/share/openocd/scripts/target/esp_common.cfg", line 135
at file "embedded:startup.tcl", line 449
*** [upload] Error 1

gatsby new [site] failing: Cannot find module 'gatsby/dist/commands/develop'

I'm pretty green here. I've run gatsby on this (macosx) before. It has stopped working - presumably due to an install or environment variable somewhere?
First noticed with Module build failed: Error: Couldn't find preset "flow" relative to directory "/Users/3Legs"
Then after installing babel presets:
npm install --global --save-dev babel-preset-flow
I get the above message:
gatsby develop
... Cannot find module 'gatsby/dist/commands/develop'
FULL TRAIL BELOW + babelrc
Michaels-MacBook-Air:mggatsby 3Legs$
gatsby new test
-bash: /usr/local/bin/gatsby: No such file or directory
Michaels-MacBook-Air:mggatsby 3Legs$
npm install --global gatsby-cli
WARN registry Unexpected warning for registry.npmjs.org: Miscellaneous Warning EINTEGRITY: sha1-xRn2KfhrOlvtuliojTETCe7Al/k= integrity checksum failed when using sha1: wanted sha1-xRn2KfhrOlvtuliojTETCe7Al/k= but got sha512-vE2hT1D0HLZCLLclfBSfkfTTedhVj0fubHpJBHKwwUWX0nSbhPAfk+SG9rTX95BYNmau8rGFfCeaT6T5OW1C2A==. (455516 bytes)
WARN registry Using stale package data from registry.npmjs.org/ due to a request error during revalidation.
WARN registry Unexpected warning for registry.npmjs.org/: Miscellaneous Warning EINTEGRITY: sha1-buxr+wdCHiFIx1xrunJCH4UwqCY= integrity checksum failed when using sha1: wanted sha1-buxr+wdCHiFIx1xrunJCH4UwqCY= but got sha512-+ktMAh1Jwas+TnGodfCfjUbJKoANqPaJFN0z0iqh41eqD8dvguNzcitVSBSVK1pidz0AqGbLKcoVuVLRVZ/aVg==. (42903 bytes)
WARN registry Using stale package data from registry.npmjs.org/ due to a request error during revalidation.
/usr/local/bin/gatsby -> /usr/local/lib/node_modules/gatsby-cli/lib/index.js
+ gatsby-cli#1.1.1
added 153 packages, removed 5 packages and updated 1 package in 10.573s
Michaels-MacBook-Air:mggatsby 3Legs$
gatsby new test
info Creating new site from git: git://github.com/gatsbyjs/gatsby-starter-default.git
Cloning into 'test'...
remote: Counting objects: 566, done.
remote: Total 566 (delta 0), reused 0 (delta 0), pack-reused 566
Receiving objects: 100% (566/566), 358.35 KiB | 187.00 KiB/s, done.
Resolving deltas: 100% (316/316), done.
success Created starter directory layout
info Installing packages...
yarn install v0.27.5
info No lockfile found.
[1/4] Resolving packages...
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning "eslint-config-fbjs#1.1.1" has unmet peer dependency "babel-eslint#^6.1.2".
warning "eslint-config-fbjs#1.1.1" has unmet peer dependency "eslint#^3.0.0".
warning "eslint-config-fbjs#1.1.1" has unmet peer dependency "eslint-plugin-babel#^3.3.0".
warning "eslint-config-fbjs#1.1.1" has unmet peer dependency "eslint-plugin-flowtype#^2.15.0".
warning "eslint-config-fbjs#1.1.1" has unmet peer dependency "eslint-plugin-react#^5.2.2".
[4/4] Building fresh packages...
success Saved lockfile.
Done in 47.94s.
Michaels-MacBook-Air:mggatsby 3Legs$
cd test
Michaels-MacBook-Air:test 3Legs$
gatsby develop
success delete html files from previous builds — 0.010 s
success open and validate gatsby-config.js — 0.006 s
success copy gatsby files — 0.028 s
success source and transform nodes — 0.045 s
success building schema — 0.134 s
success createLayouts — 0.039 s
success createPages — 0.016 s
success createPagesStatefully — 0.016 s
success extract queries from components — 0.118 s
success run graphql queries — 0.030 s
success write out page data — 0.006 s
success update schema — 0.094 s
info bootstrap finished - 3.856 s
error There was an error compiling the html.js component for the development server.
See our docs page on debugging HTML builds for help ...
Error: Module build failed: Error: Couldn't find preset "flow" relative to directory "/Users/3Legs"
Michaels-MacBook-Air:test 3Legs$
npm install --save-dev babel-preset-flow
npm WARN gentlyRm not removing /Users/3Legs/react/mggatsby/test/node_modules/.bin/gatsby as it wasn't installed by /Users/3Legs/react/mggatsby/test/node_modules/gatsby
npm WARN gentlyRm not removing /Users/3Legs/react/mggatsby/test/node_modules/.bin/semver as it wasn't installed by /Users/3Legs/react/mggatsby/test/node_modules/semver
npm WARN gentlyRm not removing /Users/3Legs/react/mggatsby/test/node_modules/jspm-registry/node_modules/.bin/semver as it wasn't installed by /Users/3Legs/react/mggatsby/test/node_modules/jspm-registry/node_modules/semver
npm WARN gentlyRm not removing /Users/3Legs/react/mggatsby/test/node_modules/.bin/browserslist as it wasn't installed by /Users/3Legs/react/mggatsby/test/node_modules/browserslist
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN gatsby-starter-default#1.0.0 No repository field.
+ babel-preset-flow#6.23.0
removed 1375 packages and updated 6 packages in 17.729s
Michaels-MacBook-Air:test 3Legs$
gatsby develop
/usr/local/bin/gatsby develop
Options:
-h, --help Show help [boolean]
-H, --host Set host. Defaults to localhost [string]
-p, --port Set port. Defaults to 8000 [string] [default: "8000"]
-o, --open Open the site in your browser for you. [boolean]
-v, --version Show version number [boolean]
error There was a problem loading the local develop command. Gatsby may not be installed.
Error: Cannot find module 'gatsby/dist/commands/develop'
- index.js:17 resolveFileName
[lib]/[gatsby-cli]/[resolve-from]/index.js:17:39
- index.js:31 resolveFrom
[lib]/[gatsby-cli]/[resolve-from]/index.js:31:9
- index.js:34 module.exports
[lib]/[gatsby-cli]/[resolve-from]/index.js:34:41
- index.js:4 module.exports.moduleId
[lib]/[gatsby-cli]/[resolve-cwd]/index.js:4:30
- create-cli.js:35 resolveLocalCommand
[lib]/[gatsby-cli]/lib/create-cli.js:35:22
- create-cli.js:66 Object.handler
[lib]/[gatsby-cli]/lib/create-cli.js:66:7
- command.js:233 Object.self.runCommand
[lib]/[gatsby-cli]/[yargs]/lib/command.js:233:22
- yargs.js:990 Object.Yargs.self._parseArgs
[lib]/[gatsby-cli]/[yargs]/yargs.js:990:30
- yargs.js:532 Object.Yargs.self.parse
[lib]/[gatsby-cli]/[yargs]/yargs.js:532:23
- create-cli.js:163 module.exports
[lib]/[gatsby-cli]/lib/create-cli.js:163:154
- index.js:122 Object.<anonymous>
[lib]/[gatsby-cli]/lib/index.js:122:1
Michaels-MacBook-Air:~ 3Legs$
cat .babelrc
{
"presets": ["flow"]
}
NPM seems to be removing modules because there isn't a package-lock.json. Not sure if this is new behavior but it's been hitting a lot of people in past few days.
All you need to do is delete node_modules and any lock file there and run npm install.

Install Jupyter on Centos

so I've got Python 2.7 properly install on CentOS, with pip configured to install packages on a custom location.
Everything has worked so far, but now I'm installing Jupyter like so:
pip install jupyter
And I get this output:
Collecting jupyter
/usr/local/lib/python2.7/site-packages/pip-7.1.2-py2.7.egg/pip/_vendor/requests/packages/urllib3/util/ssl_.py:90: InsecurePlatformWarning: A true SSLContext object is not available. This prevents urllib3 from configuring SSL appropriately and may cause certain SSL connections to fail. For more information, see https://urllib3.readthedocs.org/en/latest/security.html#insecureplatformwarning.
InsecurePlatformWarning
Using cached jupyter-1.0.0-py2.py3-none-any.whl
Collecting notebook (from jupyter)
Using cached notebook-4.1.0-py2.py3-none-any.whl
Collecting ipywidgets (from jupyter)
Using cached ipywidgets-4.1.1-py2.py3-none-any.whl
Collecting nbconvert (from jupyter)
Using cached nbconvert-4.1.0-py2.py3-none-any.whl
Collecting ipykernel (from jupyter)
Using cached ipykernel-4.3.1-py2.py3-none-any.whl
Collecting jupyter-console (from jupyter)
Using cached jupyter_console-4.1.1-py2.py3-none-any.whl
Collecting qtconsole (from jupyter)
Using cached qtconsole-4.2.0-py2.py3-none-any.whl
Collecting traitlets (from notebook->jupyter)
Using cached traitlets-4.1.0-py2.py3-none-any.whl
Collecting tornado>=4 (from notebook->jupyter)
Collecting jupyter-client (from notebook->jupyter)
Using cached jupyter_client-4.2.1-py2.py3-none-any.whl
Collecting nbformat (from notebook->jupyter)
Using cached nbformat-4.0.1-py2.py3-none-any.whl
Collecting jupyter-core (from notebook->jupyter)
Using cached jupyter_core-4.1.0-py2.py3-none-any.whl
Collecting terminado>=0.3.3 (from notebook->jupyter)
Collecting ipython-genutils (from notebook->jupyter)
Using cached ipython_genutils-0.1.0-py2.py3-none-any.whl
Collecting jinja2 (from notebook->jupyter)
Using cached Jinja2-2.8-py2.py3-none-any.whl
Collecting ipython>=4.0.0dev0 (from ipywidgets->jupyter)
Using cached ipython-4.1.2-py2-none-any.whl
Collecting pygments (from nbconvert->jupyter)
Using cached Pygments-2.1.3-py2.py3-none-any.whl
Collecting mistune!=0.6 (from nbconvert->jupyter)
Using cached mistune-0.7.2-py2.py3-none-any.whl
Collecting decorator (from traitlets->notebook->jupyter)
Using cached decorator-4.0.9-py2.py3-none-any.whl
Collecting certifi (from tornado>=4->notebook->jupyter)
Using cached certifi-2016.2.28-py2.py3-none-any.whl
Collecting backports-abc>=0.4 (from tornado>=4->notebook->jupyter)
Using cached backports_abc-0.4-py2.py3-none-any.whl
Collecting backports.ssl-match-hostname (from tornado>=4->notebook->jupyter)
Collecting singledispatch (from tornado>=4->notebook->jupyter)
Using cached singledispatch-3.4.0.3-py2.py3-none-any.whl
Collecting pyzmq>=13 (from jupyter-client->notebook->jupyter)
Collecting jsonschema!=2.5.0,>=2.0 (from nbformat->notebook->jupyter)
Using cached jsonschema-2.5.1-py2.py3-none-any.whl
Collecting ptyprocess (from terminado>=0.3.3->notebook->jupyter)
Using cached ptyprocess-0.5.1-py2.py3-none-any.whl
Collecting MarkupSafe (from jinja2->notebook->jupyter)
Collecting pickleshare (from ipython>=4.0.0dev0->ipywidgets->jupyter)
Using cached pickleshare-0.6-py2.py3-none-any.whl
Collecting simplegeneric>0.8 (from ipython>=4.0.0dev0->ipywidgets->jupyter)
Collecting setuptools>=18.5 (from ipython>=4.0.0dev0->ipywidgets->jupyter)
Using cached setuptools-20.2.2-py2.py3-none-any.whl
Collecting pexpect (from ipython>=4.0.0dev0->ipywidgets->jupyter)
Collecting six (from singledispatch->tornado>=4->notebook->jupyter)
Using cached six-1.10.0-py2.py3-none-any.whl
Collecting functools32 (from jsonschema!=2.5.0,>=2.0->nbformat->notebook->jupyter)
Collecting path.py>=6.2 (from pickleshare->ipython>=4.0.0dev0->ipywidgets->jupyter)
Using cached path.py-8.1.2-py2.py3-none-any.whl
Installing collected packages: decorator, ipython-genutils, traitlets, certifi, backports-abc, backports.ssl-match-hostname, six, singledispatch, tornado, jupyter-core, pyzmq, jupyter-client, functools32, jsonschema, nbformat, pygments, mistune, MarkupSafe, jinja2, nbconvert, path.py, pickleshare, simplegeneric, setuptools, ptyprocess, pexpect, ipython, ipykernel, terminado, notebook, ipywidgets, jupyter-console, qtconsole, jupyter
Successfully installed MarkupSafe-0.23 backports-abc-0.4 backports.ssl-match-hostname-3.5.0.1 certifi-2016.2.28 decorator-4.0.9 functools32-3.2.3.post2 ipykernel-4.3.1 ipython-4.1.2 ipython-genutils-0.1.0 ipywidgets-4.1.1 jinja2-2.8 jsonschema-2.5.1 jupyter jupyter-client-4.2.1 jupyter-console-4.1.1 jupyter-core-4.0.6 mistune-0.7.2 nbconvert-4.1.0 nbformat-4.0.1 notebook-4.1.0 path.py-8.1.2 pexpect-4.0.1 pickleshare-0.6 ptyprocess-0.5.1 pygments-2.1.3 pyzmq-15.2.0 qtconsole-4.2.0 setuptools-20.2.2 simplegeneric-0.8.1 singledispatch-3.4.0.3 six-1.10.0 terminado-0.6 tornado-4.3 traitlets-4.1.0
But my problem is that even though pip says everything went well with the install, I don't get the jupyter command line tool. If I run jupyter from the command line, I get "command not found".
Any ideas why this might be happening?
Edit with more info
Shell used: bash
Output from type jupyter:
bash: type: jupyter: not found
Results from find / -name jupyter: nothing found