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

Python 3.6 install error #12

Open
woj-evan opened this issue Sep 23, 2017 · 9 comments
Open

Python 3.6 install error #12

woj-evan opened this issue Sep 23, 2017 · 9 comments

Comments

@woj-evan
Copy link

Hello,
I was recently trying to install this package in Python 3.6 but was running into some minor errors when installing. Looking into the issue I found that it was due to a change in distutils over previous versions, where ConfigParser (in older distutils) was renamed into RawConfigParser. All I did was locally change the following lines in setup.py

Original:

conf = config.ConfigParser()

Changed:

try:
    conf = config.ConfigParser()
except:
    conf = config.RawConfigParser()

This fixed my issue; not sure if any others have had this same issue, but it is a fairly simple fix and if you could fix it now in the raw it would be appreciated. Thanks for your time.

@woj-evan
Copy link
Author

Continued issues:
Apologies for not being as detailed in my previous post, but aside from installing the package I've had some issues with simply importing the package in Python 3.6. I cannot do anything with the package as of now. In an IPython window, typing

import scimes

returns an ImportError,

/usr/lib/python3.6/site-packages/scimes-0.2.0-py3.6.egg/scimes/__init__.py in <module>()
     15 # For egg_info test builds to pass, put package imports here.
     16 if not _ASTROPY_SETUP_:
---> 17     from scimes import SpectralCloudstering

ImportError: cannot import name 'SpectralCloudstering'

I'm currently in the process of investigating, but any help would be appreciated.

@tonywong94
Copy link

It seems to load okay if the line in init.py that reads
from scimes import SpectralCloudstering
is changed to
from .scimes import SpectralCloudstering

@keflavich
Copy link
Contributor

@tonywong94 could you submit that fix as a PR?

@tonywong94
Copy link

Not really git savvy, sorry. Will bug Dario. I know how to do that!

@TimothyADavis
Copy link

Just so you know, this still seems to be an issue. Fixed it for my system using the steps above...

@mazpar
Copy link
Contributor

mazpar commented Aug 1, 2019

I faced these as well today. The suggested fix works. I have added a PR

@afmcl
Copy link

afmcl commented Dec 8, 2020

I'm reviving this because I'm having trouble installing (on Python 3.7.5), I get the following error:

AttributeError: module 'distutils.config' has no attribute 'ConfigParser'

@keflavich
Copy link
Contributor

Should be solved by f59b619, thanks for re-raising this @afmcl

@afmcl
Copy link

afmcl commented Dec 8, 2020

Should be solved by f59b619, thanks for re-raising this @afmcl

Yes, it works now!

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

6 participants