Installation Error on paramiko package 1.4.1 on mac

442
February 22, 2017, at 10:36 PM

I was recently trying to run a piece of code with paramiko, the code is simply building a basic ssh port and the code is available on other machines. However, when I install paramiko and run the code on my own machine, it's not working. I double checked the code to make sure it's the same. Then I checked the Error when compiling, it says:

    import paramiko
  File "/Library/Python/2.7/site-packages/paramiko/__init__.py", line 30, in <module>
    from paramiko.transport import SecurityOptions, Transport
  File "/Library/Python/2.7/site-packages/paramiko/transport.py", line 33, in <module>
    from cryptography.hazmat.backends import default_backend
  File "/Library/Python/2.7/site-packages/cryptography/hazmat/backends/__init__.py", line 7, in <module>
    import pkg_resources
  File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 72, in <module>
    import packaging.requirements
  File "/Library/Python/2.7/site-packages/packaging/requirements.py", line 59, in <module>
    MARKER_EXPR = originalTextFor(MARKER_EXPR())("marker")
  TypeError: __call__() takes exactly 2 arguments (1 given)

I seeked online for answers and it said the possible problem I might have is that I don't have the crypto 1.4.1 package. Therefore, I use pip to install the package and for some reason I received the same error as running the program.

pip install crypto
Collecting crypto
  Using cached crypto-1.4.1-py2.py3-none-any.whl
Collecting shellescape (from crypto)
  Using cached shellescape-3.4.1-py2.py3-none-any.whl
Collecting Naked (from crypto)
  Using cached Naked-0.1.31-py2.py3-none-any.whl
Collecting requests (from Naked->crypto)
  Using cached requests-2.13.0-py2.py3-none-any.whl
Collecting pyyaml (from Naked->crypto)
  Using cached PyYAML-3.12.tar.gz
Exception:
Traceback (most recent call last):
  File "/Library/Python/2.7/site-packages/pip/basecommand.py", line 215, in main
    status = self.run(options, args)
  File "/Library/Python/2.7/site-packages/pip/commands/install.py", line 335, in run
    wb.build(autobuilding=True)
  File "/Library/Python/2.7/site-packages/pip/wheel.py", line 749, in build
    self.requirement_set.prepare_files(self.finder)
  File "/Library/Python/2.7/site-packages/pip/req/req_set.py", line 380, in prepare_files
    ignore_dependencies=self.ignore_dependencies))
  File "/Library/Python/2.7/site-packages/pip/req/req_set.py", line 634, in _prepare_file
    abstract_dist.prep_for_dist()
  File "/Library/Python/2.7/site-packages/pip/req/req_set.py", line 129, in prep_for_dist
    self.req_to_install.run_egg_info()
  File "/Library/Python/2.7/site-packages/pip/req/req_install.py", line 412, in run_egg_info
    self.setup_py, self.name,
  File "/Library/Python/2.7/site-packages/pip/req/req_install.py", line 387, in setup_py
    import setuptools  # noqa
  File "/Library/Python/2.7/site-packages/setuptools/__init__.py", line 12, in <module>
    import setuptools.version
  File "/Library/Python/2.7/site-packages/setuptools/version.py", line 1, in <module>
    import pkg_resources
  File "/Library/Python/2.7/site-packages/pkg_resources/__init__.py", line 72, in <module>
    import packaging.requirements
  File "/Library/Python/2.7/site-packages/packaging/requirements.py", line 59, in <module>
    MARKER_EXPR = originalTextFor(MARKER_EXPR())("marker")
TypeError: __call__() takes exactly 2 arguments (1 given)

So does anyone know what's going on with my machine? Is there any other packages I need to install before I install crypto?

I'm currently using mac OS Y Yosemite and my pip is upgraded.

Thanks for your great help and patience in advance, Peter

Rent Charter Buses Company
READ ALSO
Django: How to implement custom authentification with master password

Django: How to implement custom authentification with master password

I need to implement a cusotm authorization in django which works like that: A user logs in with his forname, surname and a global password which is stored in a specific table

407
What values does the algorithm parametre take in OpenCV&#39;s FlannBasedMatcher constructor?

What values does the algorithm parametre take in OpenCV's FlannBasedMatcher constructor?

In python, OpenCV's FlannBasedMatcher constructor takes a dictionary of parametres, the first of which is algorithmThe python tutorial suggests that one can specify different values of algorithm by passing differently named variables, e

401
PIL Pix gets wrong colors

PIL Pix gets wrong colors

I programmed a little Programm using PIL which tells me the colors of a Pixel in a PictureHowever, all white pixel will be printed as black

325
Getting both group size and min of column B grouping by column A

Getting both group size and min of column B grouping by column A

Given a DataFrame df, I can obtain the size of groups by column A with

404