I am trying to install raven in frappe-bench and it installed succesfully but when assigning raven to a site then getting this error
File "apps/frappe/frappe/modules/utils.py", line 254, in load_doctype_module
raise ImportError(msg) from e
doctype = 'Raven Channel'
module = 'Core'
prefix = ''
suffix = ''
app = 'frappe'
key = ********
module_name = 'frappe.core.doctype.raven_channel.raven_channel'
msg = "Module import failed for Raven Channel, the DocType you're trying to open might be deleted.<br> Error: No module named 'frappe.core.doctype.raven_channel'"
builtins.ImportError: Module import failed for Raven Channel, the DocType you're trying to open might be deleted.<br> Error: No module named 'frappe.core.doctype.raven_channel'
I am wondering that in above error, it is looking for raven_channel doctype
in frappe.core but the doctypes of raven are present in raven app and not in frappe.core, so did I made a mistake or is this an issue in raven installation process?
this is my installation process
first, i got the app into frappe-bench
bench get-app https://github.com/The-Commit-Company/Raven.git
then installed the app to the site
bench --site yoursite.name install-app raven
getting error for second command
should i migrate the bench after getting the app? ie., after executing below command
bench get-app https://github.com/The-Commit-Company/Raven.git
hey @manal_erpnext
i uninstalled the app from site and again installed it, it installed sucessfully
1 Like
Based on the error message and your installation steps, it seems that there might be an issue with how the Raven app’s Doctypes are being referenced or loaded. To help resolve this, it’s important to ensure that all necessary migrations are applied and that the app’s assets and configurations are properly set up.
Here are the steps to follow after you’ve run the bench get-app
command:
-
Get the Raven app:
bench get-app https://github.com/The-Commit-Company/Raven.git
-
Install the Raven app on your site:
bench --site yoursite.name install-app raven
-
Run migrations to ensure all database changes are applied:
bench --site yoursite.name migrate
-
Clear the cache and restart the bench:
bench clear-cache
bench restart
-
Check for additional setup steps:
- Ensure that your
site_config.json
is correctly configured for developer mode and other settings as mentioned in the documentation.
- Make sure there are no pending changes in your Frappe site that might interfere with the installation.
Here is the complete process in sequence:
# Get the Raven app
bench get-app https://github.com/The-Commit-Company/Raven.git
# Install the Raven app on your site
bench --site yoursite.name install-app raven
# Run migrations
bench --site yoursite.name migrate
# Clear cache and restart bench
bench clear-cache
bench restart
If the issue persists after following these steps, it could be useful to check the following:
-
Verify the Doctype files:
- Ensure that the Doctype files for
Raven Channel
and other necessary Doctypes are present in the raven
app directory and not mistakenly placed in the frappe
core directory.
-
Check the site_config.json
:
- Ensure that
developer_mode
is set to 1 and that other configurations like ignore_csrf
and allow_cors
are appropriately set if you’re working in a development environment.
-
Look for any custom scripts or settings:
- Verify if there are any custom scripts or configurations that might be interfering with the Raven installation.
Yes, that did the trick ! Thanks. Not sure how but it works after a reinstall ![:slight_smile: :slight_smile:](https://discuss.frappe.io/images/emoji/twitter/slight_smile.png?v=12)
1 Like