You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@avro.apache.org by "Doug Cutting (JIRA)" <ji...@apache.org> on 2014/01/07 00:11:51 UTC
[jira] [Commented] (AVRO-1382) Support for python3
[ https://issues.apache.org/jira/browse/AVRO-1382?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13863605#comment-13863605 ]
Doug Cutting commented on AVRO-1382:
------------------------------------
Several files are modified with only whitespace changes. This should be avoided.
The current patch fails for me with:
{code}
% python3 setup.py test
running test
running egg_info
writing avro.egg-info/PKG-INFO
writing top-level names to avro.egg-info/top_level.txt
writing dependency_links to avro.egg-info/dependency_links.txt
writing manifest file 'avro.egg-info/SOURCES.txt'
running build_ext
Traceback (most recent call last):
File "setup.py", line 69, in <module>
Main()
File "setup.py", line 64, in Main
url = 'http://hadoop.apache.org/avro',
File "/usr/lib/python3.2/distutils/core.py", line 148, in setup
dist.run_commands()
File "/usr/lib/python3.2/distutils/dist.py", line 917, in run_commands
self.run_command(cmd)
File "/usr/lib/python3.2/distutils/dist.py", line 936, in run_command
cmd_obj.run()
File "/usr/lib/python3/dist-packages/setuptools/command/test.py", line 137, in run
self.with_project_on_sys_path(self.run_tests)
File "/usr/lib/python3/dist-packages/setuptools/command/test.py", line 117, in with_project_on_sys_path
func()
File "/usr/lib/python3/dist-packages/setuptools/command/test.py", line 146, in run_tests
testLoader = loader_class()
File "/usr/lib/python3.2/unittest/main.py", line 123, in __init__
self.parseArgs(argv)
File "/usr/lib/python3.2/unittest/main.py", line 191, in parseArgs
self.createTests()
File "/usr/lib/python3.2/unittest/main.py", line 198, in createTests
self.module)
File "/usr/lib/python3.2/unittest/loader.py", line 132, in loadTestsFromNames
suites = [self.loadTestsFromName(name, module) for name in names]
File "/usr/lib/python3.2/unittest/loader.py", line 132, in <listcomp>
suites = [self.loadTestsFromName(name, module) for name in names]
File "/usr/lib/python3.2/unittest/loader.py", line 100, in loadTestsFromName
parent, obj = obj, getattr(obj, part)
AttributeError: 'module' object has no attribute 'tests'
{code}
I installed python3 and python3-setuptools. Is there something else I need?
> Support for python3
> -------------------
>
> Key: AVRO-1382
> URL: https://issues.apache.org/jira/browse/AVRO-1382
> Project: Avro
> Issue Type: Bug
> Components: python
> Affects Versions: 1.7.5
> Reporter: Christophe Taton
> Attachments: AVRO-1382.20131203-001922.diff, AVRO-1382.20140101-123233-0800.diff
>
>
> Hi,
> I'd need to use Avro from Python3, which would require essentially the following changes, which I am happy to contribute:
> - rewrite except statements according to new syntax
> - rewrite print statements according to new syntax
> - basestring becomes str
> - update some imports (StringIO becomes io.StringIO, httplib becomes http.client)
> This would apparently require branching the python code to maintain a version for python2 and a separate version for python3.
> Any thoughts on how to approach this?
> Thanks!
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)