Environment details
Google cloud pubsub
window 10
Python version: 3.6.3
google-cloud-pubsub version: 0.39.1
Steps to reproduce
I used google-cloud-pubsub in Odoo module. I tried to explain the issue in step by step.
Added 'google-cloud-pubsub' in external_dependencies in python manifest file:
"external_dependencies": { 'python': ['google-cloud-pubsub'] },
Expected result:
Actually, I don't know why this error occurs. Normally it will be work.
Actual result:
When I published python module to Odoo server its threw below error:
odoo.exceptions.UserError: ('Unable to install module "caliva_wsp" because an
external dependency is not met: No module named google-cloud-pubsub', '')
How to solve this issue? I already stuck at this point around 3 days.
Thanks!
This error message is the expected result if you have not installed the dependency. Odoo module manifest external dependencies only check that the external module is available from Odoo code. It does not install the module.
Install google pubsub pip module on your Odoo server with command pip3 install google-cloud-pubsub before installing your own Odoo module. After that your module should be installable.
You can also automate the installation of dependency by putting it in module requirements.txt file. More information on this can be found at https://www.odoo.com/documentation/user/12.0/odoo_sh/getting_started/first_module.html#use-an-external-python-library.
Related
I'am learning Linux Ubuntu 18.4 Odoo 10 by following this link and link. But upon after setting up to my pycharm I encounter this error Module Not Found Error : No module named 'loglevels'. Earlier I got an error also no module named .. But I already fixed it. This time even I use the command pip3 install config or pip install config the error still there. BTW I'm using python 2.7
You need to install loglevel library.
pip install loglevel
PyPi documentation
I am trying to use airflow on databricks.
I have installed apache-airflow 1.10.6 from https://pypi.org/project/apache-airflow/.
I am using python3.6 on databricks.
But, I got error:
import airflow
ModuleNotFoundError: No module named 'werkzeug.wrappers.json'; 'werkzeug.wrappers' is not a package
I have tried the followings:
Apache Airflow : airflow initdb results in "ImportError: No module named json"
Apache Airflow : airflow initdb throws ModuleNotFoundError: No module named 'werkzeug.wrappers.json'; 'werkzeug.wrappers' is not a package error
But, I still got the same problem.
Thanks
Note: By default, "Airflow" and its dependency is not installed on the databricks.
You need to install the package explicitly.
Dependency installation: Using Databricks library utilities.
dbutils.library.installPyPI("Werkzeug")
You can install the packages in different methods.
Method1: Installing external packages using pip cmdlet.
Syntax: %sh /databricks/python3/bin/pip install <packagename>
%sh
/databricks/python3/bin/pip install apache-airflow
Method2: Using Databricks library utilities
Syntax:
dbutils.library.installPyPI("pypipackage", version="version", repo="repo", extras="extras")
dbutils.library.restartPython() # Removes Python state, but some libraries might not work without calling this function
To install apache-airflow using databricks library utilities use the below command.
dbutils.library.installPyPI("apache-airflow")
Method3: GUI Method
Go to Clusters => Select Cluster => Libraries => Install New => Library Source "PyPI" => Package "apache-airflow" => Install
Hope this helps. Do let us know if you any further queries.
Do click on "Mark as Answer" and Upvote on the post that helps you, this can be beneficial to other community members.
I am using windows subsystem for linux and I have set a virtual environment in my workspace.
I tried installing apache-airflow in the virtual environment and it got installed. But when I am trying to start the airflow webserver, I am getting the error
ImportError- no module named json
I am not being able to resolve the issue. Please help. I am following the guide Get started developing workflows with Apache Airflow
Your problem is because of version compatibility.
You should try compatible version of werkzeug using like "pip install werkzeug==0.15.4" or try to change version of flask.
Also you can refer some below link for reference.
Apache Airflow : airflow initdb throws ModuleNotFoundError: No module named 'werkzeug.wrappers.json'; 'werkzeug.wrappers' is not a package error
https://forum.astronomer.io/t/importerror-no-module-named-werkzeug-wrappers-json-werkzeug-wrappers-is-not-a-package/280
I'm trying to run a Python module for a school project and I am getting this error ModuleNotFoundError: No module named 'win32crypt' at line import win32crypt.
I've search the website for solution and encountered a post that states pywin32 is required. So I installed it with pip. I also tried installing pypiwin32. None of these installs worked. Now I've tried Dependency Walker to see if there are any dependencies missing and I see at least 100 DLLs that are. How can I fix the issue?
win32cryrpt is a part of the Windows Extensions for Python or pywin32. It is a wrapper around the Windows crypto API. It doesn't make sense to try and install it without pywin32 and if your install of that has failed then that is the problem you have to solve.
Please try pip install pypiwin32 again, being sure to execute it in the correct folder, which is the Scripts subfolder of the Python environment you want to install it in. You may have more than one Python installation without realizing it, and if you run pip from outside that folder, you may get a different instance of pip. The standard location for Python installations is C:\Program Files\Python3x. If the pip install doesn't complete as expected then edit your question to include the messages from the failed install. Did not work isn't enough to go on.
I'm working with Flask following Miguel Grinberg's book at the moment. i've reached the part where i need to interact with MySQL. i've checked everything and yet when i try to create the actual database with the command:
db.create_all()
i get an error saying "No module named 'MySQLdb'". i've tried installing mySQL-python in my virtual environment and i get another error - "No module named 'ConfigParser'". i tried installing that module with pip, but the same error occurs like i didn't install the ConfigParser module at all. any advice? i'm using python version 3.4. i've read a couple of times that MySQLdb doesn't work with python 3, a statement which contradicts what was written in Miguels book, that Flask is compatible both with python 2 and 3.
solved it. needed to install mysqlclient via pip in the virtual environment. mySQL-python apparently doesn't work with python3