On Sun, Jan 12, 2020 at 9:32 PM Eryk Sun wrote:
>
> In both of the above cases, what I'd prefer is for UTF-8 mode to take
> precedence over legacy modes, i.e. to disable
> config->legacy_windows_fs_encoding and config->legacy_windows_stdio in
> the startup configuration.
>
UTF-8 mode shouldn't ta
On 1/14/20, Inada Naoki wrote:
>
> UTF-8 mode shouldn't take precedence over legacy FS encoding.
>
> Mercurial uses legacy encoding for file paths. They use
> sys._enablelegacywindowsfsencoding() on Windows.
> https://www.mercurial-scm.org/repo/hg/rev/8d5489b048b7
This runtime call can override
Hello there,
If I have simply missed a double colon starting a for loop
File "./bbq.py", line 160
for config_file in config_files
^
SyntaxError: invalid syntax
the message is not as straightforward.
I am not sure what the status quo of these messages are,
Andrew Barnert writes:
> On Jan 13, 2020, at 19:32, Stephen J. Turnbull
> wrote:
> >
> > There is still tons of data in legacy
> > applications, both as text files and in various application data
> > formats, that use legacy encodings (in Japanese, that means MBCS).
> > Sadly, it's not
We have importlib resources. We should put it to use.
Imagine if you could separate your docs from your code and yet include
them in your package.
```
f"""{from mymodule.docs include main.rst}"""
def foo():
f"""{from mymodule.docs include foo.rst}"""
pass
class Bar:
f"""{from mymodule.
On 1/14/20 12:44 PM, Soni L. wrote:
We have importlib resources. We should put it to use.
Imagine if you could separate your docs from your code and yet include
them in your package.
```
f"""{from mymodule.docs include main.rst}"""
def foo():
f"""{from mymodule.docs include foo.rst}"""
p
On Jan 14, 2020, at 05:22, Σταύρος Ντέντος wrote:
>
> Hello there,
>
> If I have simply missed a double colon starting a for loop
>
> File "./bbq.py", line 160
>for config_file in config_files
> ^
> SyntaxError: invalid syntax
>
> the message is not as st
On the subject of replacing the current parser, I am actively working on
that. See GitHub.com/gvanrossum/pegen.
On Tue, Jan 14, 2020 at 10:32 Andrew Barnert via Python-ideas <
[email protected]> wrote:
> On Jan 14, 2020, at 05:22, Σταύρος Ντέντος wrote:
> >
> > Hello there,
> >
> > If I h
The friendly-traceback project (in early alpha) is working on making
traceback messages more helpful and translatable -
https://aroberge.github.io/friendly-traceback-docs/docs/html/
On Tue, 14 Jan 2020 at 12:43, Guido van Rossum wrote:
> On the subject of replacing the current parser, I am activ
On Tue, 14 Jan 2020 at 20:43, Guido van Rossum wrote:
>
> On the subject of replacing the current parser, I am actively working on
> that. See GitHub.com/gvanrossum/pegen.
Sounds interesting!
I could open you a ticket, if something like that is not implemented /
in your plans currently.
>
> On
For the sake of completeness: friendly-traceback is already handling
this. @Naomi Thank you for bringing this up :-)
https://github.com/aroberge/friendly-traceback/issues/42
--
Yours faithfully,
Ntentos Stavros
___
Python-ideas mailing list -- python-id
My pleasure! Glad to see you have discussed with André!
On Tue, 14 Jan 2020 at 13:52, Ntentos Stavros wrote:
> For the sake of completeness: friendly-traceback is already handling
> this. @Naomi Thank you for bringing this up :-)
>
> https://github.com/aroberge/friendly-traceback/issues/42
> --
For what it's worth, after 20+ years of using Python, forgetting the colon
for blocks remains the most common error I make by a fairly wide margin.
Of course, once I see the error message—even being not all that descriptive
of the real issue—I immediately know what to fix too.
On Tue, Jan 14, 2020
13 matches
Mail list logo