sebastien / cuisine

Chef-like functionality for Fabric

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

python3 support?

observerss opened this issue · comments

trying to pip install cuisine in py3 failed with

Exception in thread Thread-1:
Traceback (most recent call last):
  File "/Users/ob/.pythonbrew/pythons/Python-3.3.0/lib/python3.3/threading.py", line 639, in _bootstrap_inner
    self.run()
  File "/Users/ob/.pythonbrew/pythons/Python-3.3.0/lib/python3.3/threading.py", line 596, in run
    self._target(*self._args, **self._kwargs)
  File "/Users/ob/.virtualenvs/mastiff3/lib/python3.3/site-packages/pip-1.2.1-py3.3.egg/pip/index.py", line 245, in _get_queued_page
    page = self._get_page(location, req)
  File "/Users/ob/.virtualenvs/mastiff3/lib/python3.3/site-packages/pip-1.2.1-py3.3.egg/pip/index.py", line 337, in _get_page
    return HTMLPage.get_page(link, req, cache=self.cache)
  File "/Users/ob/.virtualenvs/mastiff3/lib/python3.3/site-packages/pip-1.2.1-py3.3.egg/pip/index.py", line 466, in get_page
    inst = cls(u(contents), real_url, headers)
  File "/Users/ob/.virtualenvs/mastiff3/lib/python3.3/site-packages/pip-1.2.1-py3.3.egg/pip/backwardcompat.py", line 44, in u
    return s.decode('utf-8')
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x8b in position 1: invalid start byte

Downloading/unpacking cuisine
  Downloading cuisine-0.5.1.tar.gz
  Running setup.py egg_info for package cuisine
    Traceback (most recent call last):
      File "<string>", line 16, in <module>
      File "/Users/ob/.virtualenvs/mastiff3/build/cuisine/setup.py", line 10, in <module>
        file("src/cuisine.py").readlines())[0].split("=")[1])
    NameError: name 'file' is not defined
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 16, in <module>

  File "/Users/ob/.virtualenvs/mastiff3/build/cuisine/setup.py", line 10, in <module>

    file("src/cuisine.py").readlines())[0].split("=")[1])

NameError: name 'file' is not defined

----------------------------------------
Command python setup.py egg_info failed with error code 1 in /Users/ob/.virtualenvs/mastiff3/build/cuisine
Storing complete log in /Users/ob/.pip/pip.log

Thanks, I'll look into that!

Cuisine can be make py3k compatible quite easily but there's still fabric and paramiko which don't support it at the moment as far as I know (at least not their stable releases).

Is anyone working in this issue right now? If not, I'll do it!

I am trying to fix this, and I found I need to fix fabric python 3 support first.

Yes, Cuisine itself should be easy to port, but Fabric is the problematic
one.
Le 2014-10-17 03:22, "帝归" notifications@github.com a écrit :

I am trying to fix this, and I found I need to fix fabric python 3 support
first.


Reply to this email directly or view it on GitHub
#133 (comment).

@sebastien

I checked some fabric's issues, and they are struggling in python 3 support and python 2.5 compatibility. Maybe I can do something for fabric first.

Yes or help remove the dependency on fabric altogether. The only things
that cuisine really depend on are "connect" and "run". Implementing the
same functions on top of a Python 3 SSH library would do the trick.
Le 2014-10-18 00:36, "帝归" notifications@github.com a écrit :

@sebastien https://github.com/sebastien

I checked some fabric's issues, and they are struggling in python 3
support and python 2.5 compatibility. Maybe I can do something for fabric
first.


Reply to this email directly or view it on GitHub
#133 (comment).

How about using @mathiasertl 's fork? Hopefully, we can make compatible changes.

pip install git+https://github.com/mathiasertl/fabric.git

That's an option, did you test it? I'd be happy to make some updates for Py3K compatibility

Hey guys,

Perhaps I can shed a little light on this:

  • My port is also available via pip: pip install Fabric3.
  • Paramiko is compatible with Python3
  • Upstream Fabric rejected multiple merge requests for Python3 support by me and others, because they absolutely must support Python 2.4 (!) and 2.5, which they think is still very widely used.

Happy to hear it's available though pip. I don't understand Fabric's rationale -- who uses 2.5 these days? And even then, why not simply make a maintenance branch of Fabric -- there's no reason to be stuck in Python's middle ages.

It's simple, there is a "version 2", it's not yet on GitHub so there is no code to show for it, but the alpha for the new code (once again, there is no GitHub repo) will be out soon:

Since January 2016 all issues concerning Python3 are just closed and locked without comment by the maintainer.

Wait, I just found out that since last April there now actually is an alpha vor v2: http://bitprophet.org/blog/2017/04/17/fabric-2-alpha-beta

I haven't looked at it though!

http://www.fabfile.org/changelog.html Fabric v2 is released!
Does cuisine also correspond to Python 3?