collective / collective.saml2

Installation of SAML2 web single-sign-on for Plone (dm.zope.saml2)
5 stars 6 forks source link

Not working with Zope 2.10 #8

Closed scorpiosoft closed 3 months ago

scorpiosoft commented 3 years ago

The documentation for dm.zope.saml2 says it was tested with Zope 2.10. I would expect this wrapper to also work with Zope 2.10. The instructions I have for installing new Zope modules say to make sure to use the Python executable from the Zope installation. So:

git clone https://github.com/collective/collective.saml2.git
cd collective.saml2/
/vol/plone/Python-2.4/bin/python2.4 setup.py install

is the process I used. Here is the output:

running install
running bdist_egg
running egg_info
creating src/collective.saml2.egg-info
writing requirements to src/collective.saml2.egg-info/requires.txt
writing src/collective.saml2.egg-info/PKG-INFO
writing namespace_packages to src/collective.saml2.egg-info/namespace_packages.txt
writing top-level names to src/collective.saml2.egg-info/top_level.txt
writing dependency_links to src/collective.saml2.egg-info/dependency_links.txt
writing entry points to src/collective.saml2.egg-info/entry_points.txt
writing manifest file 'src/collective.saml2.egg-info/SOURCES.txt'
reading manifest file 'src/collective.saml2.egg-info/SOURCES.txt'
writing manifest file 'src/collective.saml2.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/collective
copying src/collective/__init__.py -> build/lib/collective
creating build/lib/collective/saml2
copying src/collective/saml2/testing.py -> build/lib/collective/saml2
copying src/collective/saml2/__init__.py -> build/lib/collective/saml2
copying src/collective/saml2/interfaces.py -> build/lib/collective/saml2
copying src/collective/saml2/idpsso.py -> build/lib/collective/saml2
copying src/collective/saml2/tests.py -> build/lib/collective/saml2
creating build/lib/collective/saml2/browser
copying src/collective/saml2/browser/__init__.py -> build/lib/collective/saml2/browser
creating build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/__init__.py -> build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/_sp.py -> build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/_auth.py -> build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/_wsa.py -> build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/ws_fed.py -> build/lib/collective/saml2/bindings
copying src/collective/saml2/bindings/_wsu.py -> build/lib/collective/saml2/bindings
creating build/bdist.linux-x86_64
creating build/bdist.linux-x86_64/egg
creating build/bdist.linux-x86_64/egg/collective
creating build/bdist.linux-x86_64/egg/collective/saml2
creating build/bdist.linux-x86_64/egg/collective/saml2/browser
copying build/lib/collective/saml2/browser/__init__.py -> build/bdist.linux-x86_64/egg/collective/saml2/browser
copying build/lib/collective/saml2/testing.py -> build/bdist.linux-x86_64/egg/collective/saml2
copying build/lib/collective/saml2/__init__.py -> build/bdist.linux-x86_64/egg/collective/saml2
copying build/lib/collective/saml2/interfaces.py -> build/bdist.linux-x86_64/egg/collective/saml2
copying build/lib/collective/saml2/idpsso.py -> build/bdist.linux-x86_64/egg/collective/saml2
creating build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/__init__.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/_sp.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/_auth.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/_wsa.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/ws_fed.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/bindings/_wsu.py -> build/bdist.linux-x86_64/egg/collective/saml2/bindings
copying build/lib/collective/saml2/tests.py -> build/bdist.linux-x86_64/egg/collective/saml2
copying build/lib/collective/__init__.py -> build/bdist.linux-x86_64/egg/collective
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/browser/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/testing.py to testing.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/interfaces.py to interfaces.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/idpsso.py to idpsso.pyc
  File "build/bdist.linux-x86_64/egg/collective/saml2/idpsso.py", line 32
    class CookieRelayStateStore(object):
        ^
SyntaxError: invalid syntax
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/__init__.py to __init__.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/_sp.py to _sp.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/_auth.py to _auth.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/_wsa.py to _wsa.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/ws_fed.py to ws_fed.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/bindings/_wsu.py to _wsu.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/saml2/tests.py to tests.pyc
byte-compiling build/bdist.linux-x86_64/egg/collective/__init__.py to __init__.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/entry_points.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/namespace_packages.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/not-zip-safe -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/requires.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying src/collective.saml2.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
creating dist
creating 'dist/collective.saml2-1.0-py2.4.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing collective.saml2-1.0-py2.4.egg
creating /vol/plone/Python-2.4/lib/python2.4/site-packages/collective.saml2-1.0-py2.4.egg
Extracting collective.saml2-1.0-py2.4.egg to /vol/plone/Python-2.4/lib/python2.4/site-packages
  File "/vol/plone/Python-2.4/lib/python2.4/site-packages/collective.saml2-1.0-py2.4.egg/collective/saml2/idpsso.py", line 32
    class CookieRelayStateStore(object):
        ^
SyntaxError: invalid syntax
Adding collective.saml2 1.0 to easy-install.pth file

Installed /vol/plone/Python-2.4/lib/python2.4/site-packages/collective.saml2-1.0-py2.4.egg
Processing dependencies for collective.saml2==1.0
Searching for zope.app.component
Reading http://pypi.python.org/simple/zope.app.component/
Couldn't find index page for 'zope.app.component' (maybe misspelled?)
Scanning index of all packages (this may take a while)
Reading http://pypi.python.org/simple/
No local packages or download links found for zope.app.component
error: Could not find suitable distribution for Requirement.parse('zope.app.component')

What do I need to do to use collective.saml2 with Zope 2.10? (specifically 2.10.6 final)

The README.rst file does NOT have any install instructions.

(BTW, I did search for any discussion before opening this issue.)

wesleybl commented 3 months ago

@scorpiosoft I think your problem is that setuptools is trying to use pypi over http but it now only works over https. Try updating setuptools.