Issue installing ERPNext -'latin-1' codec can't encode character '\u2714' in position 6: ordinal not in range(256)

I have followed numerous install guides as well as the official install guides. My issues have been on both CentOS 7 as well as Ubuntu 20.04.

Currently, the issue that I am posting about is on Ubuntu 20.04. I am able to create the erpnext user, install all dependencies, and am able to successfully install frappe-bench. The issue occurs once I run the command:

bench init frappe-bench --verbose --frappe-branch version-13

This is what I get at the end:

$ bench build
Retrieving assets...
'latin-1' codec can't encode character '\u2714' in position 6: ordinal not in range(256)
Traceback (most recent call last):/frappe-bench/apps/frappe/node_modules to ./assets/frappe/node_modules 
  File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.8/runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "/home/erpnext/frappe-bench/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 110, in <module>
    main()
  File "/home/erpnext/frappe-bench/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 20, in main
    click.Group(commands=commands)(prog_name="bench")
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/erpnext/frappe-bench/frappe-bench/env/lib/python3.8/site-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/home/erpnext/frappe-bench/frappe-bench/apps/frappe/frappe/commands/utils.py", line 58, in build
    frappe.build.bundle(
  File "/home/erpnext/frappe-bench/frappe-bench/apps/frappe/frappe/build.py", line 230, in bundle
    make_asset_dirs(hard_link=hard_link)
  File "/home/erpnext/frappe-bench/frappe-bench/apps/frappe/frappe/build.py", line 420, in make_asset_dirs
    print(unstrip(f"{green('\u2714')} Application Assets Linked") + "\n")
UnicodeEncodeError: 'latin-1' codec can't encode character '\u2714' in position 5: ordinal not in range(256)
Traceback (most recent call last):
  File "/home/erpnext/.local/lib/python3.8/site-packages/bench/commands/make.py", line 70, in init
    init(
  File "/home/erpnext/.local/lib/python3.8/site-packages/bench/utils/render.py", line 95, in wrapper_fn
    return fn(*args, **kwargs)
  File "/home/erpnext/.local/lib/python3.8/site-packages/bench/utils/system.py", line 93, in init
    build_assets(bench_path=path)
  File "/home/erpnext/.local/lib/python3.8/site-packages/bench/utils/bench.py", line 308, in build_assets
    exec_cmd(command, cwd=bench_path, env={"BENCH_DEVELOPER": "1"})
  File "/home/erpnext/.local/lib/python3.8/site-packages/bench/utils/__init__.py", line 126, in exec_cmd
    raise CommandFailedError
bench.exceptions.CommandFailedError

ERROR: There was a problem while creating frappe-bench
Do you want to rollback these changes? [y/N]:

Please help me solve this. I am able to get the bench started, and I am able to get the site running on port 8000.

I have reimaged my server, ran through the steps again, and still get:

This is my 3rd entire day on this. Please help.

erpnext@server1:~$ bench --version
5.8.1
erpnext@server1:~$ bench init frappe-bench --frappe-branch version-13 --python /usr/bin/python3
$ /usr/local/bin/virtualenv --quiet env -p /usr/bin/python3
$ /home/erpnext/frappe-bench/env/bin/python -m pip install --quiet --upgrade pip
Getting frappe
$ git clone GitHub - frappe/frappe: Low code web framework for real world applications, in Python and Javascript --branch version-13 --depth 1 --origin upstream
Cloning into ‘frappe’…
remote: Enumerating objects: 2985, done.
remote: Counting objects: 100% (2985/2985), done.
remote: Compressing objects: 100% (2669/2669), done.
remote: Total 2985 (delta 433), reused 1150 (delta 244), pack-reused 0
Receiving objects: 100% (2985/2985), 16.34 MiB | 10.50 MiB/s, done.
Resolving deltas: 100% (433/433), done.
Installing frappe
$ /home/erpnext/frappe-bench/env/bin/python -m pip install --quiet --upgrade -e /home/erpnext/frappe-bench/apps/frappe
$ yarn install
yarn install v1.22.18
[1/4] Resolving packages…
[2/4] Fetching packages…
[3/4] Linking dependencies…
warning " > bootstrap@4.5.0" has unmet peer dependency “popper.js@^1.16.0”.
warning Workspaces can only be enabled in private projects.
[4/4] Building fresh packages…
$ yarn run snyk-protect
yarn run v1.22.18
$ snyk protect
Successfully applied Snyk patches

Done in 12.77s.
Done in 35.88s.
$ bench build
Retrieving assets…
‘latin-1’ codec can’t encode character ‘\u2714’ in position 6: ordinal not in range(256)
Traceback (most recent call last):/apps/frappe/node_modules to ./assets/frappe/node_modules
File “/usr/lib/python3.8/runpy.py”, line 194, in _run_module_as_main
return _run_code(code, main_globals, None,
File “/usr/lib/python3.8/runpy.py”, line 87, in _run_code
exec(code, run_globals)
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/bench_helper.py”, line 110, in
main()
File “/home/erpnext/frappe-bench/apps/frappe/frappe/utils/bench_helper.py”, line 20, in main
click.Group(commands=commands)(prog_name=“bench”)
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 829, in call
return self.main(*args, **kwargs)
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 782, in main
rv = self.invoke(ctx)
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/home/erpnext/frappe-bench/env/lib/python3.8/site-packages/click/core.py”, line 610, in invoke
return callback(*args, **kwargs)
File “/home/erpnext/frappe-bench/apps/frappe/frappe/commands/utils.py”, line 58, in build
frappe.build.bundle(
File “/home/erpnext/frappe-bench/apps/frappe/frappe/build.py”, line 230, in bundle
make_asset_dirs(hard_link=hard_link)
File “/home/erpnext/frappe-bench/apps/frappe/frappe/build.py”, line 420, in make_asset_dirs
print(unstrip(f"{green(‘\u2714’)} Application Assets Linked") + “\n”)
UnicodeEncodeError: ‘latin-1’ codec can’t encode character ‘\u2714’ in position 5: ordinal not in range(256)
Traceback (most recent call last):
File “/usr/local/lib/python3.8/dist-packages/bench/commands/make.py”, line 70, in init
init(
File “/usr/local/lib/python3.8/dist-packages/bench/utils/render.py”, line 95, in wrapper_fn
return fn(*args, **kwargs)
File “/usr/local/lib/python3.8/dist-packages/bench/utils/system.py”, line 93, in init
build_assets(bench_path=path)
File “/usr/local/lib/python3.8/dist-packages/bench/utils/bench.py”, line 308, in build_assets
exec_cmd(command, cwd=bench_path, env={“BENCH_DEVELOPER”: “1”})
File “/usr/local/lib/python3.8/dist-packages/bench/utils/init.py”, line 126, in exec_cmd
raise CommandFailedError
bench.exceptions.CommandFailedError

ERROR: There was a problem while creating frappe-bench
Do you want to rollback these changes? [y/N]: y
INFO: Rolling back Bench “frappe-bench”
erpnext@server1:~$

Hello, ran into the same issue. Sorry but my reply is very late, but hope it will help someone who runs through the same problem. The error is because your terminal output encoding does not support the tick character (:heavy_check_mark:) . Mine simply worked when ran the following commands in linux:

sudo update-locale LANG=en_US.UTF-8 LANGUAGE=en.UTF-8
sudo reboot