Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation instructions don't work, build instructions missing. #817

Closed
SomeoneElseOSM opened this issue Sep 7, 2023 · 2 comments
Closed

Comments

@SomeoneElseOSM
Copy link

Maputnik version:
n/a; I'm not getting that far. I'm starting by trying to follow https://github.com/maputnik/editor/wiki/Maputnik-CLI#install .

Browser:
n/a; I'm not getting that far.

OS:
Debian 12, Linux h8-debian-4gb-fsn1-2 6.1.0-10-arm64

Description of the bug:

  1. Installation fails.
    https://github.com/maputnik/editor/wiki/Maputnik-CLI says "The Maputnik CLI is a Golang based cross platform executable.".
    However, after downloading
    $ ./maputnik
    -bash: ./maputnik: cannot execute binary file: Exec format error
    "file ./maputnik" says "./maputnik: ELF 64-bit LSB executable, x86-64" so this is not surprising.

  2. Build from source fails.
    I'm guessing here because the nearest thing to build instructions is the section at https://github.com/maputnik/editor/blob/master/README.md#develop that merely says "npm install..."

If I download and unzip https://github.com/maputnik/editor/archive/refs/tags/v1.7.0.zip, and then:
sudo apt install npm
npm install

that fails with
npm ERR! code 1
npm ERR! path /home/ajtown/src/maputnik/editor-1.7.0/node_modules/fibers
npm ERR! command failed
npm ERR! command sh -c node build.js || nodejs build.js
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@18.13.0 | linux | arm64
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Can't find Python executable "python", you can set the PYTHON env variable.

(Python 3.11.2 is installed; no Python 2 version is installed)

if I do this:
export PYTHON=/usr/bin/python3
npm install

that fails with
npm ERR! code 1
npm ERR! path /home/ajtown/src/maputnik/editor-1.7.0/node_modules/fibers
npm ERR! command failed
npm ERR! command sh -c node build.js || nodejs build.js
npm ERR! gyp info it worked if it ends with ok
npm ERR! gyp info using node-gyp@3.8.0
npm ERR! gyp info using node@18.13.0 | linux | arm64
npm ERR! gyp ERR! configure error
npm ERR! gyp ERR! stack Error: Command failed: /usr/bin/python3 -c import sys; print "%s.%s.%s" % sys.version_info[:3];
npm ERR! gyp ERR! stack File "", line 1
npm ERR! gyp ERR! stack import sys; print "%s.%s.%s" % sys.version_info[:3];
npm ERR! gyp ERR! stack ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
npm ERR! gyp ERR! stack SyntaxError: Missing parentheses in call to 'print'. Did you mean print(...)?
npm ERR! gyp ERR! stack
npm ERR! gyp ERR! stack at ChildProcess.exithandler (node:child_process:419:12)

Steps to reproduce the behavior:
(see above)

Style file or style URL:
n/a

Screenshots:
n/a

@HarelM
Copy link
Member

HarelM commented Dec 18, 2023

Can you try the latest code now?

npm install
npm run start

and open localhost:8888.

I would also recommend using a docker image instead of the CLI tool as docker is cross platform by nature.

@HarelM
Copy link
Member

HarelM commented Jan 12, 2024

Closing as I believe the question was answered.

@HarelM HarelM closed this as completed Jan 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants