Can not update Website_Theme, Missing Node...
See original GitHub issueDescription of the issue
Node.js problems to perform style generation. Edit, update or create a website theme style is not working. FileNotFound: [Error2] No such file or directory ‘node’:‘node’
Context information (for bug reports)
frappe_docker installed version12 New site install
Steps to reproduce the issue
- Use a clean frappe_docker setup
- Create new site
- Go to Website module, and edit standard theme. Save changes. Or create new theme and try to save changes.
Observed result RIGHT IMAGE
Message error: Node not found. Some tools running on node might not be working.
Expected result LEFT IMAGE
Changes are saved as in a bench install without docker.
Stacktrace / full error message if available
Log from <project>_erpnext-python_1 container
Traceback (most recent call last):
File "/home/frappe/frappe-bench/apps/frappe/frappe/desk/form/save.py", line 22, in savedocs
doc.save()
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 273, in save
return self._save(*args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 296, in _save
self.insert()
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 230, in insert
self.run_before_save_methods()
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 893, in run_before_save_methods
self.run_method("validate")
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 794, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 1064, in composer
return composed(self, method, *args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 1047, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File "/home/frappe/frappe-bench/apps/frappe/frappe/model/document.py", line 788, in <lambda>
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File "/home/frappe/frappe-bench/apps/frappe/frappe/website/doctype/website_theme/website_theme.py", line 13, in validate
self.validate_theme()
File "/home/frappe/frappe-bench/apps/frappe/frappe/website/doctype/website_theme/website_theme.py", line 43, in validate_theme
self.generate_bootstrap_theme()
File "/home/frappe/frappe-bench/apps/frappe/frappe/website/doctype/website_theme/website_theme.py", line 66, in generate_bootstrap_theme
process = Popen(command, cwd=frappe.get_app_path('frappe', '..'), stdout=PIPE, stderr=PIPE)
File "/opt/bitnami/python/lib/python3.7/subprocess.py", line 800, in __init__
restore_signals, start_new_session)
File "/opt/bitnami/python/lib/python3.7/subprocess.py", line 1551, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'node': 'node'
Issue Analytics
- State:
- Created 3 years ago
- Comments:15
Top Results From Across the Web
how to change website theme and save this theme so it ...
and when i refresh the page the theme doesn't reset. I was wondering how can i do that , or can someone put...
Read more >Themes disabled during update
I've noticed sometimes when viewing the themes selection page that all the themes are disabled even the default theme when several themes ...
Read more >theming - Node form – self changing theme - Drupal Answers
What is disturbing.. it changes theme from admin to regular. Instead of Seven Theme I see regular website theme. Am I missing some...
Read more >[Solved] New v12 install cannot get to login screen
Ok, so today I finally got a successful install using the easy install method described here: However, when I attempt to get to...
Read more >HubSpot CMS for Developers Local Issues
... and run "npx /create-cms-project test-theme", the cloning always fails and the. ... If you success installing Node.js then type next command and...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This happens when node is installed via nvm
Check
$ /usr/bin/node
Gives output :-bash: /usr/bin/node: No such file or directory
It should give:Solution: Make a symbolic link
$ sudo ln -s $(which node) /usr/bin/
I think you’re right.
yarn add node-sass
only happens in frappe-nginxI sent a pr to frappe https://github.com/frappe/frappe/pull/11220
Generally in nodejs projects node-sass happens in development and only css assets are packed and served in production. In frappe theme changes happen with node-sass in production.
snyk shows there are security issues in node-sass to be kept in production.
@MarekPikula send a PR here that adds node-sass even in erpnext-nginx I’ll merge.