Skip to content

Conversation

@yyuu
Copy link
Member

@yyuu yyuu commented Aug 20, 2012

Please support Python 3.x.

Unfortunately, this pull req will effect fluent-logger-python to lose compatibility with Python versions prior than 2.5.

@kzk
Copy link
Member

kzk commented Aug 20, 2012

Thanks for your pull request. I'm now researching whether or not we should support Python 2.5.

Could you describe what makes it difficult to support 2.5? Just curious.

BTW, i got a comment below from @methane and am inclined to drop 2.5 support. > https://twitter.com/methane/status/237468419094622208

@yyuu
Copy link
Member Author

yyuu commented Aug 20, 2012

It's based on syntax incompatibility around try ... except clause between Python 2.x and Python 3.x.

Python versions prior than 2.5 accepts following syntax to capture raised exceptions (e).

try:
    foo()
except Exception, e:
    bar()

On Python 3.x, we have to use as keyword to do same as above. Python 2.6 and later versions can handle both form of them.

try:
    foo()
except Exception as e:
    bar()

Since this is an issue of syntax, it is hard to support both of them.

http://docs.python.org/dev/howto/pyporting.html#capturing-the-currently-raised-exception

kzk added a commit that referenced this pull request Aug 20, 2012
support python 3.x, and not support python 2.5 anymore.
@kzk kzk merged commit 0b14cbc into fluent:master Aug 20, 2012
@kzk
Copy link
Member

kzk commented Aug 20, 2012

I understand what you mean, and yeah it's a bad idea to support Python 2.5 anymore. Thanks for the pull request!

EvaSDK pushed a commit to EvaSDK/fluent-logger-python that referenced this pull request Jul 26, 2013
support python 3.x, and not support python 2.5 anymore.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants