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

Make imports Python 3 compatible #1

Merged
merged 7 commits into from
Mar 13, 2018
Merged

Make imports Python 3 compatible #1

merged 7 commits into from
Mar 13, 2018

Conversation

ale-rt
Copy link
Member

@ale-rt ale-rt commented Mar 11, 2018

No description provided.

Copy link
Member

@mgedmin mgedmin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Are there other fixes required for Python 3 compatibility? Because if not, then I'd like .travis.yml to start testing Python 3, and also setup.py to include the Python version classifiers.

@ale-rt
Copy link
Member Author

ale-rt commented Mar 12, 2018

Actually this one is already testable vs Python 3 (I just add to update the bootstrap and drop zope.testing):

[ale@emily z3c.objpath]$ python3 -m venv .
[ale@emily z3c.objpath]$ ./bin/python3 bootstrap.py 
ez_setup.py is deprecated and when using it setuptools will be pinned to 33.1.1 since it's the last version that supports setuptools self upgrade/installation, check https://github.com/pypa/setuptools/issues/581 for more info; use pip to install setuptools
Downloading https://pypi.io/packages/source/s/setuptools/setuptools-33.1.1.zip
Extracting in /tmp/tmpf3hmred_
Now working in /tmp/tmpf3hmred_/setuptools-33.1.1
Building a Setuptools egg in /tmp/bootstrap-oeu94m1q
warning: no files found matching '*' under directory 'setuptools/_vendor'
/tmp/bootstrap-oeu94m1q/setuptools-33.1.1-py3.6.egg
no previously-included directories found matching 'doc'
no previously-included directories found matching 'old-tutorial'
Creating directory '/home/ale/Code/plone/plone3/src/z3c.objpath/develop-eggs'.
Generated script '/home/ale/Code/plone/plone3/src/z3c.objpath/bin/buildout'.
[ale@emily z3c.objpath]$ ./bin/buildout -Nt 2
Setting socket time out to 2 seconds.
Develop: '/home/ale/Code/plone/plone3/src/z3c.objpath/.'
/home/ale/Code/plone/plone3/src/z3c.objpath/lib/python3.6/site-packages/setuptools/dist.py:333: UserWarning: Normalizing '1.2dev' to '1.2.dev0'
  normalized_version,
Uninstalling devpython.
Uninstalling test.
Installing test.
Generated script '/home/ale/Code/plone/plone3/src/z3c.objpath/bin/test'.
Installing devpython.
Generated interpreter '/home/ale/Code/plone/plone3/src/z3c.objpath/bin/devpython'.
[ale@emily z3c.objpath]$ ./bin/test 
Running zope.testrunner.layer.UnitTests tests:
  Set up zope.testrunner.layer.UnitTests in 0.000 seconds.
  Ran 1 tests with 0 failures, 0 errors and 0 skipped in 0.002 seconds.
Tearing down left over layers:
  Tear down zope.testrunner.layer.UnitTests in 0.000 seconds.

I think I do not have the power to add the travis hook. Can somebody do that for me please?
Can I already merge this one?

@jamadden
Copy link
Member

Travis is enabled for z3c.objpath.

@mgedmin
Copy link
Member

mgedmin commented Mar 13, 2018

Can you push another commit so we can see Travis working? E.g. rename *.txt to *.rst for prettier ReST rendering.

@ale-rt
Copy link
Member Author

ale-rt commented Mar 13, 2018

Thanks @jamadden!
I will now add a travis conf file

@ale-rt ale-rt merged commit cef5b8a into master Mar 13, 2018
@ale-rt ale-rt deleted the py3-compat branch March 13, 2018 17:38
@ale-rt
Copy link
Member Author

ale-rt commented Mar 13, 2018

I merged this one, thanks for caring.
To you think something else is needed before we have another PyPI release?

@mgedmin
Copy link
Member

mgedmin commented Mar 13, 2018

Personally, I'd explicitly declare all supported minor Python versions in setup.py, add Python 3.4 and 3.5 to .travis.yml, and rename *.txt to *.rst before making a new release, to bring z3c.objpath to the standard of other maintained zopefoundation packages.

(I'd also add a tox.ini for my own personal convenience, because I prefer running tox locally instead of waiting for Travis results to come in.)

But the main thing is to contact one of the current PyPI owners (hi @faassen, @witsch!) and ask them if they can make the release or add you (or anybody else who might volunteer for this duty) as a package owner on PyPI. (Oh, and add url='https://github.com/zopefoundation/z3c.objpath' to setup.py metadata.)

Oh, when asking for PyPI permissions it's best to explicitly mention your PyPI username (mine is mgedmin).

@ale-rt
Copy link
Member Author

ale-rt commented Mar 13, 2018

@mgedmin your plan looks reasonable, I will try to put it in practice.

BTW I am alert on PyPI (https://pypi.org/user/alert/)

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

Successfully merging this pull request may close these issues.

3 participants