question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Errors in setting up local dev

See original GitHub issue

To setup the development environment, I’ve followed the steps in README.md. The command yarn returns the following errors.

yarn install v0.27.5
[1/4] Resolving packages...
[2/4] Fetching packages...
warning fsevents@1.1.2: The platform "linux" is incompatible with this module.
info "fsevents@1.1.2" is an optional dependency and failed compatibility check. Excluding it from installation.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
[-/5] ⠠ waiting...
[2/5] ⠠ uws
[3/5] ⠠ phantomjs-prebuilt
[4/5] ⠠ node-sass
error /media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs: Command failed.
Exit code: 1
Command: sh
Arguments: -c node install.js
Directory: /media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs
Output:
PhantomJS not found on PATH
Phantom installation failed TypeError: Path must be a string. Received undefined
    at assertPath (path.js:28:11)
    at Object.join (path.js:1251:7)
    at findSuitableTempDirectory (/media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs/install.js:127:30)
    at /media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs/install.js:476:19
    at nextTickCallback (/media/ajayns/Projects/Code/xPR/plone-react/node_modules/kew/kew.js:47:28)
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickCallback (internal/process/next_tick.js:180:9) TypeError: Path must be a string. Received undefined
    at assertPath (path.js:28:11)
    at Object.join (path.js:1251:7)
    at findSuitableTempDirectory (/media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs/install.js:127:30)
    at /media/ajayns/Projects/Code/xPR/plone-react/node_modules/phantomjs/install.js:476:19
    at nextTickCallback (/media/ajayns/Projects/Code/xPR/plone-react/node_modules/kew/kew.js:47:28)
    at _combinedTickCallback (internal/process/next_tick.js:131:7)
    at process._tickCallback (internal/process/next_tick.js:180:9)
info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.

The backend setup also seems to return a few errors. Running ./bin/buildout

Getting distribution for 'mr.developer==1.34'.
Got mr.developer 1.34.
Getting distribution for 'zc.buildout==2.5.2'.
While:
  Installing.
  Loading extensions.
  Getting distribution for 'zc.buildout==2.5.2'.

An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/buildout.py", line 2123, in main
    getattr(buildout, command)(args)
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/buildout.py", line 637, in install
    self._load_extensions()
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/buildout.py", line 1163, in _load_extensions
    newest=self.newest, allow_hosts=self._allow_hosts)
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/easy_install.py", line 920, in install
    return installer.install(specs, working_set)
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/easy_install.py", line 721, in install
    for dist in self._get_dist(req, ws):
  File "/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg/zc/buildout/easy_install.py", line 577, in _get_dist
    dist = self._env.best_match(requirement, ws)
  File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 1111, in best_match
    dist = working_set.find(req)
  File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 715, in find
    raise VersionConflict(dist, req)
VersionConflict: (zc.buildout 2.10.0 (/media/ajayns/Projects/Code/xPR/plone-react/api/eggs/zc.buildout-2.10.0-py2.7.egg), Requirement.parse('zc.buildout==2.5.2'))

This error also meants the ./bin/instance is never created only.

Still running the dev server with all these errors shows this: (Just added this more info for debug)

Something went wrong: Invalid token specified: Cannot read property 'replace' of undefined

@tisto Please help me out here!

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:21 (15 by maintainers)

github_iconTop GitHub Comments

2reactions
tistocommented, Jan 16, 2018

@tulikavijay we should remove phantomjs altogether. This dependency is not needed any longer.

1reaction
tistocommented, Jan 23, 2018

The tutorial was aimed at Plone developers who know the details about buildout.

Here is what you need to do:

Am 22.01.2018 um 21:57 schrieb Ajay NS:

@tisto https://github.com/tisto After updating yarn when I run ‘yarn’ to install packages, it seems to show my version of node is incompatible and it requires ‘6.11’. Shouldn’t plone-react be updated to support the latest LTS version of Node? Or right now I’ll just downgrade my Node locally for it to work?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/plone/plone-react/issues/60#issuecomment-359562102, or mute the thread https://github.com/notifications/unsubscribe-auth/AAmlKbUd-8m2av3j7i5YWnNMfES4Y86aks5tNPZHgaJpZM4Rd50J.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error while installing lwc local server? Here is how to resolve it!!
In case you face some permission issues while running the above command, I have already given the resolution above. In windows, run cmd...
Read more >
Don't be stuck at dev environment setup! | Rookie's Lab
Don't be stuck at dev environment setup! One of the worst feelings as a developer is not able to work on what you...
Read more >
yarn add lwc-dev-server@latest --non-interactive
facing the following error while trying to setup local development server Error: yarn add lwc-dev-server@latest --non-interactive.
Read more >
Automate Your Local Development Practices for Less Errors ...
Step 2: Using Local Development Practices and a Local Development Environment First for All Changes. Before you can make a change to a...
Read more >
Local Dev Server error: GET /local-assets/site.css -- 500
Hi there, I'm a software engineer that is just messing around in Squarespace for the first time, and I just set up my...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found