Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ImportError: No module named 'mass' #1

Open
shrx opened this issue Dec 3, 2014 · 10 comments
Open

ImportError: No module named 'mass' #1

shrx opened this issue Dec 3, 2014 · 10 comments

Comments

@shrx
Copy link

shrx commented Dec 3, 2014

If I want to import periodic with import periodic, I get an error:

Traceback (most recent call last):
  File "/home/marting/PycharmProjects/simple/3d_test.py", line 4, in <module>
    import periodic
  File "/usr/local/lib/python3.4/dist-packages/periodic/__init__.py", line 1, in <module>
    import mass
ImportError: No module named 'mass'

I installed periodic with sudo pip3 install periodic.

@kalvdans
Copy link

This bug will be fixed by pull request #2.

@Pyxidatol-C
Copy link

Pyxidatol-C commented Mar 9, 2018

The distribution on https://pypi.python.org/pypi/periodic still has the import problem:

Python 3.6.4 |Anaconda, Inc.| (default, Jan 16 2018, 12:04:33) 
[GCC 4.2.1 Compatible Clang 4.0.1 (tags/RELEASE_401/final)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from periodic import element
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/yjj/anaconda3/lib/python3.6/site-packages/periodic/__init__.py", line 1, in <module>
    import mass
ModuleNotFoundError: No module named 'mass'

@mdommett
Copy link

I am also seeing this problem, is there a fix that could be worked on ? Thanks

@42force
Copy link

42force commented Mar 23, 2019

Yes, was there an answer for this specific issue?

@u-gajera
Copy link

Still same problem

@Br0Fi
Copy link

Br0Fi commented Feb 18, 2020

In case more people run into this problem and just want a quick fix for themselves, I recommend the following:
Go to /usr/lib/python3.8/site-packages/periodic (or wherever the package manager put your python and periodic installation) and edit the __init__.py to reflect the changes made in the following pull request:
29b131d

@ravivemagiri
Copy link

Error: File "/Users//anaconda3/lib/python3.6/site-packages/periodic/init.py", line 1, in
open the path which is shown in console with init.py
example pico "/Users/
/
********/............./init.py"

open this path using pico and vim editor and update the two lines in the file to below two lines

from . import mass
from .table import *

IT worked for me.

@sajidislam-cyber
Copy link

Facing the same problem

@sudarshanDudhe
Copy link

sudarshanDudhe commented Oct 4, 2020

found the issue... its with the imports in init.py in the package. Made changes to the init.py in stored or installed package by adding .(dot) before importing and it worked.
new init.py ==>
from . import mass from .table import *

@Gerardwx
Copy link

I pushed the updated code to pypi as periodic2023 https://pypi.org/project/periodic2023/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests