Change by Hai Shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue45691>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Hai Shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue46417>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Hai Shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue46368>
___
___
Python-bugs-list mailing list
Unsubscribe:
Hai Shi added the comment:
> If not, I'd like to close this (with apologies for not doing my research and
> letting Hai Shi do unmerged work).
> If a use case is found, I suspect it'll need a different solution – perhaps
> allowing PyType_Slot·s
OK, I close this bpo. W
Hai Shi added the comment:
> _functoolsmodule is a core bootstrap module and defined in
> Modules/Setup.bootstrap. It has no external dependencies. There is no reason
> and no point to disable the module.
+1.
> Cristian, in this case - is there a reason to keep `skipUnless
Change by Hai Shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue46613>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by hai shi :
--
pull_requests: +14978
pull_request: https://github.com/python/cpython/pull/15259
___
Python tracker
<https://bugs.python.org/issue37
hai shi added the comment:
IMHO, if we supply the ability to add an argument group, we need add the
ability to remove the argument group too.
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue9
hai shi added the comment:
paul, raymond. Thanks for give me a quick answer:).
Looks raymond's reason is good enough, i just only consider this question from
api completeness(as paul said) not from user case.
--
___
Python tracker
&
New submission from hai shi :
Some reference leak in compiler_assert function, due to not using
Py_DECREF(assertion_error) before return. And having a question about code
order in compiler_assert function.
--
components: Interpreter Core
files: compiler_assert.patch
keywords: patch
hai shi added the comment:
Ok, got it.
--
___
Python tracker
<https://bugs.python.org/issue37887>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by hai shi :
--
pull_requests: +15073
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/15362
___
Python tracker
<https://bugs.python.org/iss
hai shi added the comment:
It is a good idea. So I update this title and add PR 15362.
I am not sure there have a problem of xuanli's CLA or not~
--
components: -Documentation
nosy: +shihai1991
title: Documentation for argparse interactive use -> Improving interactive
Change by hai shi :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Change by hai shi :
--
nosy: +pitrou
___
Python tracker
<https://bugs.python.org/issue37750>
___
___
Python-bugs-list mailing list
Unsubscribe:
https://mail.pyth
Change by hai shi :
--
nosy: +pitrou
___
Python tracker
<https://bugs.python.org/issue37698>
___
___
Python-bugs-list mailing list
Unsubscribe:
https://mail.pyth
New submission from hai shi :
As paul said in bpo 9938:
The exit and error methods are mentioned in the 3.4 documentation, but there
are no examples of modifying them.
16.4.5.9. Exiting methods
ArgumentParser.exit(status=0, message=None)
ArgumentParser.error(message)
I will
hai shi added the comment:
issue 9938
--
___
Python tracker
<https://bugs.python.org/issue37908>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by hai shi :
--
nosy: +paul.j3
___
Python tracker
<https://bugs.python.org/issue37908>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by hai shi :
--
title: Improving interactive use of argparse -> Add optional kwargs to argparse
___
Python tracker
<https://bugs.python.org/iss
Change by hai shi :
--
keywords: +patch
pull_requests: +15150
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/15455
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
Adding an example of ArgumentParser.exit(), because some user would like
cathing errors manually or consider exit progress or not when an error occurs.
I have not add example of ArgumentParser.error(), because i can not think some
user scenarios
Change by hai shi :
--
title: Add some examples of ArgumentParser.exit() -> Add an example of
ArgumentParser.exit()
type: -> resource usage
___
Python tracker
<https://bugs.python.org/i
Change by hai shi :
--
nosy: +bethard
___
Python tracker
<https://bugs.python.org/issue37908>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
How about use a flag(such USING_OUT_NAMESPACE) to identify we use namespace or
not?
For example:
subnamespace, arg_strings = parser.parse_known_args(arg_strings, None)
for key, value in vars(subnamespace).items():
if USING_OUT_NAMESPACE and not hasattr
hai shi added the comment:
How about:
1. Adding documentation as steven said.
2. If user use '-' of positional arguments in latest cpython, we cloud remind
user that `the '-' of positional arguments be replaced by '_' since cpython 4.0`
3.Applying Simon
hai shi added the comment:
I do something such as:
p = argparse.ArgumentParser()
p.add_argument('-a', action='store_true')
p.add_argument('-b', action='store_true')
p.parse_args('-ab='.split())
thos code code jump in 1903, and the explicit
hai shi added the comment:
Adding a judgment of explicit_args in judgment statement in the patch.
--
keywords: +patch
Added file: https://bugs.python.org/file48582/parse_v1.patch
___
Python tracker
<https://bugs.python.org/issue36
hai shi added the comment:
Thanks, Raymond. This patch not a formal patch, just show what i want to do. if
everything agree this behavior, I would add a normal PR.
--
type: behavior -> crash
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
pull_requests: +15323
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/15656
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
oh, sorry, pls ignore it. I misunderstand your opinion.
--
type: crash -> behavior
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
nosy: +rhettinger
___
Python tracker
<https://bugs.python.org/issue9938>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
some test cases which paul provided looks doesn't keep compatible.
In TestDoubleDashRemoval:
# output in my env is Namespace(cmd='cmd', foo=None, rest=['--', '--foo'])
('-- cmd -- -- --foo', NS(cmd='cmd', foo=No
Change by hai shi :
--
pull_requests: +15369
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/15714
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
nosy: +rhettinger
type: -> behavior
___
Python tracker
<https://bugs.python.org/issue14364>
___
___
Python-bugs-list mailing list
Un
hai shi added the comment:
>* Remove notes about the new API being added in 3.4 since 3.4 is no longer
>supported
Related bpo in issue14455
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/i
Change by hai shi :
--
pull_requests: +15617
pull_request: https://github.com/python/cpython/pull/15988
___
Python tracker
<https://bugs.python.org/issue37
hai shi added the comment:
Stéphane, thanks for your good comment. Some argparse's bpo is too old ;)
--
___
Python tracker
<https://bugs.python.org/i
New submission from hai shi :
As the title said, in `setint` function, the refcount of `o` should decreased
all the time.
--
components: Interpreter Core
messages: 352412
nosy: shihai1991
priority: normal
severity: normal
status: open
title: Reflaks in setint() of mmapmodule.c
type
Change by hai shi :
--
title: Reflaks in setint() of mmapmodule.c -> Refleaks in setint() of
mmapmodule.c
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
keywords: +patch
pull_requests: +15746
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16136
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
Looks we have a fast version rhythm. IMHO, If user would be affected and
reported, reversing the PR is ok.
--
___
Python tracker
<https://bugs.python.org/issue19
New submission from hai shi :
Py_SET_ERANGE_ON_OVERFLOW should be changed to Py_SET_ERANGE_IF_OVERFLOW in
pyport.h.
--
assignee: docs@python
components: Documentation
messages: 352981
nosy: docs@python, shihai1991
priority: normal
severity: normal
status: open
title: Fix typo of
Change by hai shi :
--
keywords: +patch
pull_requests: +15906
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16230
___
Python tracker
<https://bugs.python.org/issu
New submission from hai shi :
Got an compile error, my OS is gcc version 4.8.5 20150623 (Red Hat 4.8.5-36:
CC='gcc -pthread' LDSHARED='gcc -pthread -shared' OPT='-g -Og -Wall'
_TCLTK_INCLUDES='' _TCLTK_LIBS='' ./python -E .
hai shi added the comment:
Got an compile error, i have not check the detail for now:
python: Objects/typeobject.c:2867: PyType_FromSpecWithBases: Assertion
`memb->type == 19' failed.
i report it in bpo 38273
--
nosy: +shihai1991
__
hai shi added the comment:
oh, thanks, guys. This error info is disappeared when i followed victor's
advice. It must be i changed the configure/make file by accident.
Sorry for this noisy info
--
resolution: -> not a bug
stage: -> resolved
status: ope
hai shi added the comment:
Hi, Jonas. Thanks for your report.
Let us wait core team's discuss;)
--
___
Python tracker
<https://bugs.python.org/is
New submission from hai shi :
`if (start + slen > len)` would cause undefined behavior?
such as: start=PY_SSIZE_T_MAX, slen=1
REFS:
[1] https://github.com/python/cpython/blob/master/Objects/bytes_methods.c#L746
--
components: Interpreter Core
messages: 354032
nosy: shihai1991
prior
Change by hai shi :
--
keywords: +patch
pull_requests: +16191
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16603
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
> The PR's Misc/NEWS entry, "Fix behavior of argparse when '--' as argument to
> option", is insufficient.
Thanks for your comment, Raymond. I would continue update the desc.
--
___
New submission from hai shi :
The warning detail:
Objects/dictobject.c: In function ‘_PyDictView_Intersect’:
Objects/dictobject.c:4189:15: warning: unused variable ‘tmp’ [-Wunused-variable]
PyObject *tmp;
^
--
components: Build
messages: 354068
nosy: shihai1991
Change by hai shi :
--
title: Got an compile warning in dictobject.c -> Got a compile warning in
dictobject.c
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
keywords: +patch
pull_requests: +16198
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16610
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
I checked the help format.
the help_lines' width in python2.7 is different python3.
The width is more likely a hardcode in
https://github.com/python/cpython/blob/2.7/Lib/argparse.py#L165.
, so the help_lines = [u'This is a very long help string. ex: &qu
hai shi added the comment:
oh, typo error. the help_lines' width in python2.7 is different python3.-->the
help_lines' width in python2.7 is different with python3.x
--
___
Python tracker
<https://bugs.pytho
hai shi added the comment:
Maybe the keyword need add the `easy` wrod? (i don't know the internals)
newcomer need find it in `Easy issues` ;)
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/is
New submission from hai shi :
for a code example:
```
v = []
b = bytearray(0x)
for i in range(2**31+1)
# the ob_exports would be overflow in 32 bit machine when i = 2**31.
v.append(memoryview(b))
```
IMHO, i thought converting the type of ob_exports to Py_ssize_t is fine.
PS: I
Change by hai shi :
--
keywords: +patch
pull_requests: +16322
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16746
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
sorry, typo error.
# the ob_exports would be overflow in 32 bit machine when i = 2**31.
-->
# the ob_exports would be overflow in 64 bit machine when i = 2**31.
--
___
Python tracker
<https://bugs.python.org/issu
hai shi added the comment:
Thanks, Serhiy, you are right.
--
___
Python tracker
<https://bugs.python.org/issue38465>
___
___
Python-bugs-list mailing list
Unsub
hai shi added the comment:
In
'If *exc* is *NULL*, then the exception is cleared and the value is clipped to
*PY_SSIZE_T_MIN* for a negative integer or *PY_SSIZE_T_MAX* for a positive
integer.', should PY_SSIZE_T_MIN and PY_SSIZE_T_MAX be changed too?
--
nosy: +
hai shi added the comment:
Ok, it's fine to me.
--
___
Python tracker
<https://bugs.python.org/issue38600>
___
___
Python-bugs-list mailing list
Unsubscr
New submission from hai shi :
`if (c.c_normalize) {
Py_DECREF(c.c_normalize);
}`
-->
`Py_XDECREF(c.c_normalize);`
--
components: Interpreter Core
messages: 355545
nosy: shihai1991
priority: normal
severity: normal
status: open
title: Using Py_XDECREF to replace Py_DECREF
Change by hai shi :
--
keywords: +patch
pull_requests: +16490
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16962
___
Python tracker
<https://bugs.python.org/issu
New submission from hai shi :
1) param is unpredictable;
2) the compiler_free() use Py_XDECREF(c->c_filename) in PyAST_CompileObject();
--
components: Interpreter Core
messages: 355547
nosy: shihai1991
priority: normal
severity: normal
status: open
title: Using Py_XINCREF to repl
Change by hai shi :
--
keywords: +patch
pull_requests: +16491
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16963
___
Python tracker
<https://bugs.python.org/issu
New submission from hai shi :
I don't know why don't use refcount
`
/* borrowed reference */
c.c_filename = filename;
`
in https://github.com/python/cpython/blob/master/Python/ast.c#L786-L787
like
`
Py_INCREF(filename);
c.c_filename = filename;
`
in https://github.com/python/cp
hai shi added the comment:
Due to victor add the desc(`/* borrowed reference */`)
so noisy+ victor ;)
--
nosy: +vstinner
___
Python tracker
<https://bugs.python.org/issue38
hai shi added the comment:
Got it, thanks, Serhiy.
--
___
Python tracker
<https://bugs.python.org/issue38617>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
> I don't understand the purpose of this issue. The bug tracker is not the
> right place to ask question. If you think that it's a bug, please explain how
> to trigger the bug.
Hi, victor. What i want to express is that the refcount operation
hai shi added the comment:
Thanks for your patience, Serhiy.
IMHO, i called the moving operation `clean code`: Consistent understanding,
Consistent code. And the `clean code` should be a part of `enhancement`.
--
___
Python tracker
<ht
hai shi added the comment:
I think the answer is 'yes'(It's over 8 years~).
And tons of argparse'work need to be finished;)
--
nosy: +shihai1991
___
Python tracker
<https://bug
Change by hai shi :
--
nosy: +shihai1991
nosy_count: 8.0 -> 9.0
pull_requests: +23686
pull_request: https://github.com/python/cpython/pull/24922
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
nosy: +barry, maxking, r.david.murray
___
Python tracker
<https://bugs.python.org/issue43554>
___
___
Python-bugs-list mailing list
Unsub
hai shi added the comment:
There have another related issue and have been fixed now in bpo 41718.
So I suggest to close this bpo.
--
resolution: -> duplicate
stage: -> resolved
status: open -> closed
___
Python tracker
<https://bug
hai shi added the comment:
bpo-41718
--
___
Python tracker
<https://bugs.python.org/issue41551>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by hai shi :
--
nosy: +shihai1991
nosy_count: 25.0 -> 26.0
pull_requests: +23859
pull_request: https://github.com/python/cpython/pull/25115
___
Python tracker
<https://bugs.python.org/iss
Change by hai shi :
--
keywords: +patch
pull_requests: +23864
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/25115
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
pull_requests: -23859
___
Python tracker
<https://bugs.python.org/issue4111>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
> By the way, maybe Py_LIMITED_API should be defined in xxlimited.c, rather
> than in setup.py.
+1. Defining Py_LIMITED_API in xxlimited.c is more direct than in setup.py. so
I created the PR-25115.
--
___
Change by hai shi :
--
pull_requests: +23865
pull_request: https://github.com/python/cpython/pull/25115
___
Python tracker
<https://bugs.python.org/issue4
Change by hai shi :
--
pull_requests: +23922
pull_request: https://github.com/python/cpython/pull/25180
___
Python tracker
<https://bugs.python.org/issue41
hai shi added the comment:
> Perhaps it would be better that compiling them not be attempted with
> configuring --with-trace-refs?
+1. The limited C API can't be build under Py_TRACE_REFS now.
--
___
Python tracker
<https://b
Change by hai shi :
--
nosy: +shihai1991
nosy_count: 12.0 -> 13.0
pull_requests: +23963
pull_request: https://github.com/python/cpython/pull/25226
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue43753>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
I created PR 25226. It's a another way to solve this problem.
Compared to PR 15175, `_set_sentinel()` don't need to receive any params :)
--
___
Python tracker
<https://bugs.python.o
Change by hai shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue43845>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
> I would like this type (and other types that have been or will be converted
> to heap types) to remain immutable.
Hi, Guido. I am interested in what have been broken in fact? or it's a
defined behavior?
> I think we may need a new flag bit mea
hai shi added the comment:
>Ideally if we did not intend to break libraries then can this be fixed?
Or if it is acceptable to have such a breaking change.
Hi, akdor1154, thanks for your notice. It was a bugfix in fact:)
https://bugs.python.org/issue37751#msg349448
> maybe this is
hai shi added the comment:
Thanks Marc-Andre for your supplement of PEP-100.
Thanks Inada, victor for your review and merge.
After PR-23096 merged, I suggest to close this bpo.
If there have any other questions, we can reopen it again.
--
resolution: -> fixed
stage: patch rev
Change by hai shi :
--
pull_requests: +24719
pull_request: https://github.com/python/cpython/pull/26080
___
Python tracker
<https://bugs.python.org/issue41
hai shi added the comment:
> The main limitation to use the limited C API for stdlib is Argument Clinic
> which attempts to always emit the most efficient code, like using the
> METH_FASTCALL calling convention and use private functions like
> _PyArg_CheckPositional(
Change by hai shi :
--
nosy: +orsenthil
___
Python tracker
<https://bugs.python.org/issue40938>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
> METH_VARARGS and METH_KEYWORDS are part of the stable ABI.
Copy that, thanks, petr.
--
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
versions: +Python 3.11 -Python 3.10
___
Python tracker
<https://bugs.python.org/issue4>
___
___
Python-bugs-list mailing list
Unsub
hai shi added the comment:
> * functools._lru_list_elem
Looks like this type have performance in issue PR-5008 when supporting GC. I am
not sure there have other similar questions or not.
--
___
Python tracker
<https://bugs.python.org/issu
Change by hai shi :
--
pull_requests: +25045
pull_request: https://github.com/python/cpython/pull/26451
___
Python tracker
<https://bugs.python.org/issue42
Change by hai shi :
--
nosy: +shihai1991
___
Python tracker
<https://bugs.python.org/issue44263>
___
___
Python-bugs-list mailing list
Unsubscribe:
hai shi added the comment:
OK, I try to take a look after Kyle leaves temporarily. But I haven't replicate
this issue in my vm in recent days :(
--
nosy: +shihai1991
versions: +Python 3.11 -Python 3.8
___
Python tracker
<https://bugs.py
1 - 100 of 700 matches
Mail list logo