ImportError: No module named 'baseapi' - python

I can`t use the pyfcm module because of bellow error message.
How do I fix this error??
>>> from pyfcm import FCMNotification
Traceback (most recent call last):
File "<pyshell#0>", line 1, in <module>
from pyfcm import FCMNotification
File "C:\Anaconda3\lib\site-packages\pyfcm\__init__.py", line 6, in <module>
from .fcm import FCMNotification
File "C:\Anaconda3\lib\site-packages\pyfcm\fcm.py", line 1, in <module>
from baseapi import BaseAPI
ImportError: No module named 'baseapi'

If you are running Linux, try running this command in the shell: pip install baseapi.
If you are using an IDE, look for a prompt asking if you want to install this package.

Related

Mingus/lilypond on python

I can import mingus but sublibraries such as mingus.extra.lilypond give me an error:
import mingus.core.notes
Traceback (most recent call last):
File "<pyshell#4>", line 1, in <module>
import mingus.core.notes
File "C:\Users\PharaohZz\AppData\Local\Programs\Python\Python36\lib\site-packages\mingus\core\notes.py", line 29, in <module>
from mt_exceptions import NoteFormatError, RangeError, FormatError
ModuleNotFoundError: No module named 'mt_exceptions'
or
import mingus.extra.lilypond
Traceback (most recent call last):
File "<pyshell#2>", line 1, in <module>
import mingus.extra.lilypond
File "C:\Users\PharaohZz\AppData\Local\Programs\Python\Python36\lib\site-packages\mingus\extra\__init__.py", line 20, in <module>
import lilypond
ModuleNotFoundError: No module named 'lilypond'
You can fix this problem by first uninstalling mingus (pip uninstall mingus).
Then build the library from it's source. To do this:
Download the files from git hub using the command git clone https://github.com/bspaans/python-mingus .
Enter the directory using cd python-mingus.
Finally install it using the command python setup.py install.
This fixed the problem for me.

Distributed package cannot find import

I'm trying to distribute this code through git+pip . I was able to properly create the setup.py file for deployment but after installing the package with:
https://github.com/EKami/kaggle-data-downloader
Running this import gives me an error:
>>> from kaggle_data_downloader import KaggleDataDownloader
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/Ekami/Programs/anaconda/envs/tensorflow/lib/python3.6/site-packages/kaggle_data_downloader/KaggleDataDownloader.py", line 3, in <module>
import utils
ModuleNotFoundError: No module named 'utils'
But with:
>>> import kaggle_data_downloader.utils
It works. It seems KaggleDataDownloader cannot find kaggle_data_downloader.utils. I think I missed something in the setup.py file. Any idea?
Thanks.

ImportError: No module named _winreg python2.7

I tried to install wmi in my system which is running with python2.7.12.
installed WMI using pip : pip install wmi
But it shows below error
>>> import wmi
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.7/dist-packages/wmi.py", line 88, in <module>
from win32com.client import GetObject, Dispatch
ImportError: No module named win32com.client
>>>
Then, I tried to install win32 python module. But its failed with "ImportError: No module named _winreg".
Full error message:
root#srv1:/home/srv1/Downloads/pywin32-220# python setup.py install
Traceback (most recent call last):
File "setup.py", line 82, in <module>
import _winreg
ImportError: No module named _winreg
root#srv1:/home/srv1/Downloads/pywin32-220#

ImportError: No module named 'version' during installation

I'm trying to install SMOP on Anaconda3 (Python 3.5.1), but it fails due to the following error:
[Anaconda3] C:\Users\IanHacker\Downloads\smop-0.29>python setup.py install
Traceback (most recent call last):
File "setup.py", line 4, in <module>
from smop.version import __version__
File "C:\Users\IanHacker\Downloads\smop-0.29\smop\__init__.py", line 4, in <module>
import version
ImportError: No module named 'version'
"pip install smop" and "easy_install smop" return the same error.
I referred to ImportError: No module named 'version', so I changed the content of __init__.py:
import version
import parse,resolve,backend,main
from version import __version__
to:
__version__ = '0.29'
import parse,resolve,backend,main
... then, I got:
[Anaconda3] C:\Users\IanHacker\Downloads\smop-0.29>python setup.py install
Traceback (most recent call last):
File "setup.py", line 4, in <module>
from smop.version import __version__
File "C:\Users\IanHacker\Downloads\smop-0.29\smop\__init__.py", line 6, in <module>
import parse,resolve,backend,main
ImportError: No module named 'parse'
I don't even know if the __version__ issue has been solved.
Even if it has been solved, I don't know what to replace "parse" with.
And ... do I have to keep replacing until this works? Is there any better way to solve this?
*For those who installed Anaconda, could you try to run the command and check if the same error happens? Am I the only one who gets this error?

ImportError: No module named 'jsonconv'

I am running Python 3.4
Did pip install json2html with no errors.
However, when I execute "import json2html" I got:
>>> import json2html
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Python34\lib\site-packages\json2html-0.3-py3.4.egg\json2html\__init__.py", line 6, in <module>
ImportError: No module named 'jsonconv'
>>>
please help suggest..
It seems this library is not python3-compatible.
Error was caused by this line in the __init__.py file:
from jsonconv import *
While, instead, it should be:
from .jsonconv import *
Try this fork instead: https://github.com/YAmikep/json2html

Categories