[Tutor] Failing svn pre-commit hok was Re: Urgent Help Required
Peter Otten
__peter__ at web.de
Sat Feb 4 14:50:43 CET 2012
Zafrullah Syed wrote:
> I need urgent help:
Remember that this isn't paid support. Don't frivolously consume the
goodwill of volunteers.
> I am unable to commit code to svn, I am getting this warning:
>
> *svn: Commit failed (details follow):*
> *svn: Commit blocked by pre-commit hook (exit code 1) with output:*
> *<string>:17: Warning: 'with' will become a reserved keyword in Python
> 2.6* *writeConf.py:17: invalid syntax*
> *Commited Python-Files refused, please check and retry...*
>
> How do i surpass this and commit my code??
You have a pre-commit hook in place that ensures that you commit valid
Python 2.5 code. To make your file 2.5-compliant you can either replace
with output:
...
with something else or add
from __future__ import with_statement
at the top of your file.
Alternatively you can ask the person responsible for the svn installation to
remove the hook or replace it with a check that accepts Python 2.6 or
whatever version you are developing for.
More information about the Tutor
mailing list