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.x compliance #33

Closed
dnene opened this issue Jun 5, 2013 · 13 comments
Closed

Python 3.x compliance #33

dnene opened this issue Jun 5, 2013 · 13 comments
Labels

Comments

@dnene
Copy link

dnene commented Jun 5, 2013

I did a quick modification for python 3.x compliance (See dnene@1acb0eb )

I haven't quite figured out how to run the existing test cases so created my own at test/test_beanstalkc.py

Could you describe what commands I need to run and from which directory to execute the test cases. That can help me work through any other issues.

The tests in test/test_beanstalkc.py are successful across both python 2.7 and 3.3

@earl
Copy link
Owner

earl commented Jun 5, 2013

You can run the tests either by running beanstalkc.py itself python beanstalkc.py, or by invoking nose directly: nosetests -c .nose.cfg.

Thanks for looking into this (it's a long-standing issue: #13). beanstalkc currently aims to stay backwards compatible to 2.6.

@dnene
Copy link
Author

dnene commented Jun 6, 2013

Thanks. Not sure why, but the same command wasn't working for me yesterday
:(

If I am able to retain 2.6 compatibility and have all the test cases pass
on 2.6, 2.7 and 3.3, would you welcome a pull request? (Alternatively I
will have to perpetually retain this fork for myself since I use Python 3.3)

On Wed, Jun 5, 2013 at 11:02 PM, Andreas Bolka [email protected]:

You can run the tests either by running beanstalkc.py itself python
beanstalkc.py, or by invoking nose directly: nosetests -c .nose.cfg.

Thanks for looking into this. beanstalkc currently aims to stay backwards
compatible to 2.6.


Reply to this email directly or view it on GitHubhttps://github.com//issues/33#issuecomment-18993666
.


http://blog.dhananjaynene.com twitter: @dnene
http://twitter.com/dnenegoogle plus:
http://gplus.to/dhananjaynene

@earl
Copy link
Owner

earl commented Jun 6, 2013

Yes, if you can maintain 2.6+ compatibility, a pull request would be very welcome.

I'd also be interested in results regarding 3.2 (and probably 3.1).

@Tomtomgo
Copy link

@dnene @earl Any news on this? Having beanstalkc standard work on Python 3.3 would be really nice!

@djit
Copy link

djit commented Nov 25, 2013

+1 for Python 3.3 compatibility

@justinabrahms
Copy link

I went to make an attempt here. I'm not sure how to proceed and still keep doctests. Example below running python3.4

======================================================================
FAIL: Doctest: README.mkd
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/local/Cellar/python3/3.4.0/Frameworks/Python.framework/Versions/3.4/lib/python3.4/doctest.py", line 2193, in runTest
    raise self.failureException(self.format_failure(new.getvalue()))
AssertionError: Failed doctest test for README.mkd
  File "/Users/justinlilly/src/hacks/beanstalkc/README.mkd", line 0

----------------------------------------------------------------------
File "/Users/justinlilly/src/hacks/beanstalkc/README.mkd", line 28, in README.mkd
Failed example:
    job.body
Expected:
    'hey!'
Got:
    b'hey!'

Not sure how to proceed for that.

@justinabrahms
Copy link

If there are others who would like to try, this was my tox.ini

[tox]
envlist = py26,py27,py34
[testenv]
deps=
    nose
    pyyaml
commands=nosetests -c .nose.cfg

Write that into the repo root as tox.ini, pip install tox then just run tox to run in all 3 environments. I pulled in the branch mentioned above (and fixed 2 merge conflicts), but got stuck on that difficult error I posted above.

@hit9
Copy link

hit9 commented Jul 29, 2014

syntax error on py3.3

@hit9
Copy link

hit9 commented Aug 1, 2014

Any progress on Py 3.x?

@svisser
Copy link
Contributor

svisser commented Sep 13, 2014

+1 to make it clear this is desired.

Here is a pull request towards 2.x and 3.x support: #52.

@menezes-
Copy link

menezes- commented Dec 6, 2014

Hey,
I was needing python3 support so i created this: https://github.com/menezes-/pystalkd
it's based on beanstalkc and should be API compatible.
Hope that's ok.

@svisser
Copy link
Contributor

svisser commented Dec 6, 2014

@earl is it possible to merge in the pull request and to make beanstalkc 3.x compatible? I don't think the situation regarding SLES 12 has changed much but having two nearly identical projects isn't a good thing.

@earl
Copy link
Owner

earl commented Dec 7, 2014

Thanks, everyone, for the continued interest in getting beanstalkc to run on Python 3. I'll be tending to this over the next few days (or weeks, if necessary), with the aim of getting a properly Python 3-enabled beanstalkc 0.5.0 released before the end of 2014.

As a first step, I'll be cleaning up issues & pull requests to focus discussion. Please, everyone interested in Python 3 support, follow / subscribe to issue #13. This is where the discussion will continue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

8 participants