New submission from Victor Porton :
In https://docs.python.org/3/library/io.html it is forgotten to say whether
'\n' is appened to the return value of readline().
It is also unclear what happens if the last line not terminated by '\n' is read.
It is also unclear what i
New submission from Victor Porton :
The following script:
#/usr/bin/env python3
import logging
logger = logging.getLogger(name='main')
logger.setLevel(logging.INFO)
logger.error('XXX')
logging.error('ZZZ')
logger.error('XXX')
outputs
XXX
ERROR:
Victor Porton added the comment:
Oh, I noticed I can do
my_subparser = subparsers.add_parser('checkout', aliases=['co'])
So resolution invalid.
--
resolution: -> not a bug
___
Python tracker
<https://
Victor Porton added the comment:
One of possible solutions:
https://bugs.python.org/issue35480
--
___
Python tracker
<https://bugs.python.org/issue35
New submission from Victor Porton :
Subparsers are added like:
subparsers.add_parser('checkout', aliases=['co'])
But I want to use a parser BOTH as a subparser and as a full-fledged parser.
It is because my program should understand both of the following command line
op
Victor Porton added the comment:
Subparsers are added like:
subparsers.add_parser('checkout', aliases=['co'])
But I want to use a parser BOTH as a subparser and as a full-fledged parser.
It is because my program should understand both of the following command line
optio
New submission from Victor Porton :
We should consider some way to implement argparse functionality asked here:
https://stackoverflow.com/q/53686523/856090
It is unclear how exactly to do this. This message is a call to discuss what
should be the information format and API.
The awful thing
Victor Porton added the comment:
My bug report was wrong:
https://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core.html
In the DOM, all namespace declaration attributes are by definition bound to the
namespace URI: "http://www.w3.org/2000/xmlns/";. These are the attrib
New submission from Victor Porton :
I have:
parser.add_argument('-p', '--preload', help='preload asset', action='append',
metavar='NAMESPACE')
I want also add:
parser.add_argument('-f', '--file', help='preload
New submission from Victor Porton :
The following is a fragment of a real code:
~~~
def test_run_xinlude(self):
# stub_stdin(self,
Global.get_resource_bytes("tests/core/data/xml/xinclude.xml"))
for next_script_mode in ['doc1', 'doc2']:
New submission from Victor Porton :
The below script prints
http://www.w3.org/2000/xmlns/
aa:aa
It should print
None
aa:aa
because xmlns:z is NOT an attribute of xmlns namespace.
~~~
import xml.dom.minidom
x = xml.dom.minidom.parseString("")
for i in x.documentElement.attribu
Victor Porton added the comment:
@Raymond:
"Downstream processing or transformation of inputs is beyond the scope of
argparse which should stick to its core responsibilities of argument
extraction."
You somehow contradict the official documentation:
"One particularly e
New submission from Victor Porton :
argparse produces a long unreadable, non-understandable for non-programmers
error message when a subparser is not specified in the command line.
Note that the below message contains Ubuntu specifics, but it seems it would be
nearly as unclear on other OSes
New submission from Victor Porton :
The below code produces "rock", but it should produce "a". This (to use dict
value instead of the key by argparse result) is both to be a new useful feature
(for example to map strings in a command line to certain functions or class
Change by Victor Porton :
--
type: -> behavior
___
Python tracker
<https://bugs.python.org/issue34188>
___
___
Python-bugs-list mailing list
Unsubscrib
New submission from Victor Porton :
It seems that bool(Q) always return True for a priority queue Q.
It should behave the same way as for bool(L) where L is a list, that is return
False on an empty queue.
Please check also other objects in https://docs.python.org/3/library/queue.html
After
New submission from Victor Porton :
https://docs.python.org/3/library/argparse.html does not allow abbreviations
for subparsers ("subcommands").
It seems inconsistent that long options can be abbreviated but subcommands
cannot.
Either implement subcommand abbreviations or explain i
New submission from Victor Porton :
Please add `__exit__()` method to event loops, to use them with `with`.
--
components: asyncio
messages: 312360
nosy: asvetlov, porton, yselivanov
priority: normal
severity: normal
status: open
title: Add __exit__() method to event loops
type
New submission from Victor Porton :
At https://docs.python.org/3/library/subprocess.html there is said nothing
about what happens if our Python program terminates (by SIGTERM or SIGINT)
while waiting for .communicate().
I assume to do something in this situation is just forgotten.
Usually
Victor Porton added the comment:
Weird, after I minimized the PHP example, it also has the same bug as the
Python one. (The real long code in PHP was working without this bug.)
I attach the PHP code for your reference.
Maybe it is a FreeBSD bug?
Please write to por...@narod.ru with advice
New submission from Victor Porton:
When I connect
telnet XXX 9000
to the server in attached file, the connection breaks after 5 min (and a few
seconds), as if SO_KEEPALIVE were not specified.
I run my server on
FreeBSD 9.2-RELEASE-p15 (GENERIC)
So SO_KEEPALIVE does not work in Python 2.7
21 matches
Mail list logo