Multiple ways to install frappe-ui? #69
Unanswered
charleslcso
asked this question in
Q&A
Replies: 1 comment
-
Both ways are correct. Doppio makes it very simple to set up frappe-ui. The instructions in the docs involve more steps but you understand the structure of your project better. In any case, you will get similar setups. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello Hussain,
I am following your video on #BuildWithHussain number 1. At 00:27:09, you mentioned we use:
bench add-frappe-ui --app [your-app] --name [frontend]
I issued this command the first time, I get
$ bench add-frappe-ui
Usage: bench [OPTIONS] COMMAND [ARGS]...
Try 'bench --help' for help.
Error: No such command 'add-frappe-ui'.
It seems that I need to install doppio first? This is what I do, and here is the error:
$ bench get-app https://github.com/NagariaHussain/doppio
Getting doppio
$ git clone https://github.com/NagariaHussain/doppio --depth 1 --origin upstream
Cloning into 'doppio'...
remote: Enumerating objects: 40, done.
remote: Counting objects: 100% (40/40), done.
remote: Compressing objects: 100% (34/34), done.
remote: Total 40 (delta 0), reused 24 (delta 0), pack-reused 0
Receiving objects: 100% (40/40), 35.65 KiB | 936.00 KiB/s, done.
Ignoring dependencies of https://github.com/NagariaHussain/doppio. To install dependencies use --resolve-deps
Installing doppio
$ /opt/frappe/frappe-bench/env/bin/python -m pip install --quiet --upgrade -e /opt/frappe/frappe-bench/apps/doppio
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
frappe 13.51.3 requires Click~=7.1.2, but you have click 8.1.3 which is incompatible.
[notice] A new release of pip is available: 23.0.1 -> 23.1.2
[notice] To update, run: pip install --upgrade pip
$ yarn install
yarn install v1.22.19
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/4] 🔍 Resolving packages...
[2/4] 🚚 Fetching packages...
[3/4] 🔗 Linking dependencies...
[4/4] 🔨 Building fresh packages...
✨ Done in 8.41s.
$ bench build --app doppio
Traceback (most recent call last):
File "/opt/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 73, in get_app_commands
app_command_module = importlib.import_module(app + ".commands")
File "/opt/homebrew/Cellar/[email protected]/3.10.11/Frameworks/Python.framework/Versions/3.10/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 119, in
commands = get_commands()
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 112, in get_commands
from .site import commands as site_commands
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/site.py", line 665, in
def uninstall(context, app, dry_run, yes, no_backup, force):
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 308, in decorator
_param_memo(f, OptionClass(param_decls, **option_attrs))
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2495, in init
super().init(param_decls, type=type, multiple=multiple, **attrs)
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2112, in init
raise ValueError(
ValueError: 'default' must be a list when 'multiple' is true.
Traceback (most recent call last):
File "/opt/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 73, in get_app_commands
app_command_module = importlib.import_module(app + ".commands")
File "/opt/homebrew/Cellar/[email protected]/3.10.11/Frameworks/Python.framework/Versions/3.10/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "/opt/frappe/frappe-bench/apps/erpnext/erpnext/commands/init.py", line 6, in
from frappe.commands import get_site, pass_context
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 119, in
commands = get_commands()
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 112, in get_commands
from .site import commands as site_commands
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/site.py", line 665, in
def uninstall(context, app, dry_run, yes, no_backup, force):
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 308, in decorator
_param_memo(f, OptionClass(param_decls, **option_attrs))
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2495, in init
super().init(param_decls, type=type, multiple=multiple, **attrs)
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2112, in init
raise ValueError(
ValueError: 'default' must be a list when 'multiple' is true.
Usage: bench [OPTIONS] COMMAND [ARGS]...
Try 'bench --help' for help.
Error: No such command 'build'.
ERROR:
subprocess.CalledProcessError: Command 'bench build --app doppio' returned non-zero exit status 2.
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/opt/homebrew/bin/bench", line 8, in
sys.exit(cli())
File "/opt/homebrew/lib/python3.10/site-packages/bench/cli.py", line 127, in cli
bench_command()
File "/Users/administrator/Library/Python/3.10/lib/python/site-packages/click/core.py", line 1130, in call
return self.main(*args, **kwargs)
File "/Users/administrator/Library/Python/3.10/lib/python/site-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
File "/Users/administrator/Library/Python/3.10/lib/python/site-packages/click/core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/administrator/Library/Python/3.10/lib/python/site-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/Users/administrator/Library/Python/3.10/lib/python/site-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "/opt/homebrew/lib/python3.10/site-packages/bench/commands/make.py", line 159, in get_app
get_app(
File "/opt/homebrew/lib/python3.10/site-packages/bench/app.py", line 444, in get_app
app.install(verbose=verbose, skip_assets=skip_assets, restart_bench=restart_bench)
File "/opt/homebrew/lib/python3.10/site-packages/bench/utils/render.py", line 126, in wrapper_fn
return fn(*args, **kwargs)
File "/opt/homebrew/lib/python3.10/site-packages/bench/app.py", line 242, in install
install_app(
File "/opt/homebrew/lib/python3.10/site-packages/bench/app.py", line 586, in install_app
build_assets(bench_path=bench_path, app=app)
File "/opt/homebrew/lib/python3.10/site-packages/bench/utils/bench.py", line 351, in build_assets
exec_cmd(command, cwd=bench_path, env={"BENCH_DEVELOPER": "1"})
File "/opt/homebrew/lib/python3.10/site-packages/bench/utils/init.py", line 158, in exec_cmd
raise CommandFailedError from subprocess.CalledProcessError(return_code, cmd)
bench.exceptions.CommandFailedError
(env) Charles-MBA:frappe-bench administrator$ bench add-frappe-ui
Traceback (most recent call last):
File "/opt/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 73, in get_app_commands
app_command_module = importlib.import_module(app + ".commands")
File "/opt/homebrew/Cellar/[email protected]/3.10.11/Frameworks/Python.framework/Versions/3.10/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 119, in
commands = get_commands()
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 112, in get_commands
from .site import commands as site_commands
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/site.py", line 665, in
def uninstall(context, app, dry_run, yes, no_backup, force):
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 308, in decorator
_param_memo(f, OptionClass(param_decls, **option_attrs))
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2495, in init
super().init(param_decls, type=type, multiple=multiple, **attrs)
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2112, in init
raise ValueError(
ValueError: 'default' must be a list when 'multiple' is true.
Traceback (most recent call last):
File "/opt/frappe/frappe-bench/apps/frappe/frappe/utils/bench_helper.py", line 73, in get_app_commands
app_command_module = importlib.import_module(app + ".commands")
File "/opt/homebrew/Cellar/[email protected]/3.10.11/Frameworks/Python.framework/Versions/3.10/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "/opt/frappe/frappe-bench/apps/erpnext/erpnext/commands/init.py", line 6, in
from frappe.commands import get_site, pass_context
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 119, in
commands = get_commands()
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/init.py", line 112, in get_commands
from .site import commands as site_commands
File "/opt/frappe/frappe-bench/apps/frappe/frappe/commands/site.py", line 665, in
def uninstall(context, app, dry_run, yes, no_backup, force):
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/decorators.py", line 308, in decorator
_param_memo(f, OptionClass(param_decls, **option_attrs))
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2495, in init
super().init(param_decls, type=type, multiple=multiple, **attrs)
File "/opt/frappe/frappe-bench/env/lib/python3.10/site-packages/click/core.py", line 2112, in init
raise ValueError(
ValueError: 'default' must be a list when 'multiple' is true.
Dashboard Name [frontend]: ^C
However, I complete all 4 steps in this page https://frappeui.com/getting-started.html, and can start the Vite server at 8080.
Which instruction is correct? I am afraid I deviated from your video, and hence I can't proceed... may be?
Beta Was this translation helpful? Give feedback.
All reactions