[issue47158] logging.handlers.SysLogHandler doesn't get cleaned up properly on exit if it throws an exception

2022-03-31 Thread Grégory Starck
Grégory Starck added the comment: Enji : you can use this then: ``` In [6]: class Fixed(logging.handlers.SysLogHandler): ...: def __init__(self, *a, **kw): ...: self.socket = None ...: super().__init__(*a, **kw) ...: def close(self

[issue47158] logging.handlers.SysLogHandler doesn't get cleaned up properly on exit if it throws an exception

2022-03-30 Thread Grégory Starck
Grégory Starck added the comment: I guess it could be done relatively easily. but the question is more: should it be done ? -- ___ Python tracker <https://bugs.python.org/issue47

[issue47158] logging.handlers.SysLogHandler doesn't get cleaned up properly on exit if it throws an exception

2022-03-29 Thread Grégory Starck
Grégory Starck added the comment: I think this is fixed in main, thanks to this: https://github.com/python/cpython/blob/main/Lib/logging/handlers.py#L862-L863 -- nosy: +gstarck ___ Python tracker <https://bugs.python.org/issue47

[issue40074] pickle module dump and load: add support for string file names

2022-03-19 Thread Grégory Starck
Grégory Starck added the comment: FWIW -1 as well, for same reasons. -- nosy: +gstarck ___ Python tracker <https://bugs.python.org/issue40074> ___ ___ Python-bug

[issue45625] Add support for top-level await

2021-11-01 Thread Grégory Starck
Grégory Starck added the comment: python --async myscript.py ? -- nosy: +gstarck ___ Python tracker <https://bugs.python.org/issue45625> ___ ___ Python-bug

[issue45511] Batch-mode input() limited to 4095 characters on *NIX

2021-10-25 Thread Grégory Starck
Grégory Starck added the comment: > This does not seems to be a copypaste issue. well. it's either not a prob in my_fgets()/fgets IMO. what the process reads on its stdin is already corrupted/broken. but I'm interrested in knowing more about the issue/original ca

[issue45511] Batch-mode input() limited to 4095 characters on *NIX

2021-10-23 Thread Grégory Starck
Grégory Starck added the comment: reproduced and also seen in my_fgets. but strange. it's fgets that seems to return/insert a \n after 4096 chars read from stdin :O I dont quite get. at all haha. now just straced that.. we see 4 read of 1024 bytes/chars. and with strace -s 1025 I can see

[issue43535] Make str.join auto-convert inputs to strings.

2021-03-21 Thread Grégory Starck
Grégory Starck added the comment: FWIW -1 from me too. That should be solved by creating a new function IMO : def joinstr(sep, *seq): return sep.join(str(i) for i in seq) -- nosy: +g.sta...@gmail.com ___ Python tracker <ht

[issue43125] Trying To Concatenate Bytes and String in SMTPLIB

2021-02-07 Thread Grégory Starck
Grégory Starck added the comment: I filled the PR https://github.com/python/cpython/pull/24476 feel free to comment. -- ___ Python tracker <https://bugs.python.org/issue43

[issue43125] Trying To Concatenate Bytes and String in SMTPLIB

2021-02-07 Thread Grégory Starck
Change by Grégory Starck : -- keywords: +patch pull_requests: +23268 stage: -> patch review pull_request: https://github.com/python/cpython/pull/24476 ___ Python tracker <https://bugs.python.org/issu

[issue43125] Trying To Concatenate Bytes and String in SMTPLIB

2021-02-07 Thread Grégory Starck
Change by Grégory Starck : -- versions: +Python 3.6 ___ Python tracker <https://bugs.python.org/issue43125> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue43125] Trying To Concatenate Bytes and String in SMTPLIB

2021-02-07 Thread Grégory Starck
Grégory Starck added the comment: problem seems to/could be in /usr/lib/python3.8/email/base64mime.py ``` def body_encode(s, maxlinelen=76, eol=NL): r"""Encode a string with base64. Each line will be wrapped at, at most, maxlinelen characters (defaults to

[issue43125] Trying To Concatenate Bytes and String in SMTPLIB

2021-02-07 Thread Grégory Starck
Grégory Starck added the comment: I reproduced directly. by using a valid smtp server. -- nosy: +g.sta...@gmail.com ___ Python tracker <https://bugs.python.org/issue43

[issue41406] BufferedReader causes Popen.communicate losing the remaining output.

2020-07-27 Thread Grégory Starck
Grégory Starck added the comment: also affecting 3.6 -- nosy: +g.sta...@gmail.com versions: +Python 3.6 ___ Python tracker <https://bugs.python.org/issue41

[issue9232] Allow trailing comma in any function argument list.

2015-07-13 Thread Grégory Starck
Grégory Starck added the comment: Have also been confronted to this bug (imo) and this happen from time to time to me : I often like to ends my (big) functions defs and calls (those that span over multiple lines thus..) with that extra comma, so that when/if I add another argument

[issue10682] With '*args' or even bare '*' in def/call argument list, trailing comma causes SyntaxError

2015-07-13 Thread Grégory Starck
Grégory Starck added the comment: unneeded consistency unneeded consistency !:? I'd say that either there is a full or complete consistency on the mentionned point/element of syntax, or there is none .. but an unneeded one.. or an half-one, isn't consistent consistency

[issue24600] function(**dict) does not accept comma after dict (inside parenthese)

2015-07-09 Thread Grégory Starck
New submission from Grégory Starck: Consider following: Python 3.4.0 (default, Jun 19 2015, 14:20:21) [GCC 4.8.2] on linux def f(**kw): pass f(a=1 , ) # ok f(**{'a': 1} ) # ok # but : f(**{'a': 1} , ) SyntaxError: invalid syntax shouldn't the last form be also allowed