On Oct 7, 2010, at 8:05 AM, Jonathan Lundell wrote:
> 
> On Oct 7, 2010, at 7:32 AM, Jonathan Lundell wrote:
>> 
>> On Oct 7, 2010, at 7:09 AM, mdipierro wrote:
>>> 
>>> For now I reverted to 1.86.2 hoping the problem is not there.
>> 
>> A hunch: the new syntax-checking code in admin/default/edit needs to convert 
>> Windows line endings before calling compile.
> 
> If that's right, a (possibly) better alternative is to do the conversion 
> before saving the edited file.

Second & third thoughts.

There are three logical places to do the conversion: when reading the file (for 
editing), when saving the edited file, and at compilation time.

It might be best to do it either when reading the file (so the editor sees 
"proper" newlines), or when compiling (so the file is changed as little as 
possible).

On the whole, I think it's best to end up with the on-disk file fully 
converted. Otherwise, you might end up with a confusing mix of Windows newlines 
(from the original file) and Unix newlines (from the editor).

> 
>> 
>>> 
>>> On Oct 7, 8:39 am, Chuck Paulson <[email protected]> wrote:
>>>> I just upgraded to version 1.86.3 and whenever I try to edit a file
>>>> using the web2py interface I get a "failed to compile file because:
>>>> SyntaxError on line 2..." error. This happens on files that I have not
>>>> even changed, such as db.py as well as on files that I have created.
>>>> Help, I can't edit anything.
>>>> 
>>>> Chuck Paulson
>> 
>> 
> 
> 


Reply via email to