Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-93649: Split getargs testing from _testcapimodule.c#99346

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

erlend-aasland
Copy link
Contributor

@erlend-aaslanderlend-aasland commentedNov 10, 2022
edited by bedevere-bot
Loading

- a couple of PEP 7 nits- use intermingled decls a few places- Use Py_NewRef() API to save a few lines
@erlend-aasland
Copy link
ContributorAuthor

erlend-aasland commentedNov 11, 2022
edited
Loading

There is some fishy error handling in some of the test methods. Let's handle those in a separate issue/PR. An example istest_k_code(), wheretuple leak in multiple branches.

@encukou
Copy link
Member

Leaks in failing tests? The only situation I see where that's is a problem is when tests are used as API usage examples. So, it's good to fix those, but not too important for older tests.

UndefiningPyArg_ParseTupleAndKeywords and defining again it is also a bit fishy – IMO it would better to havs the non-Size_T definition in the public header file, albeit shadowed by a macro, so only#undef would suffice. But that's an unrelated issue.

erlend-aasland reacted with thumbs up emoji

@erlend-aasland
Copy link
ContributorAuthor

Leaks in failing tests?

Yes, only in error handling paths, and it's not a problem in practice.

UndefiningPyArg_ParseTupleAndKeywords and defining again it is also a bit fishy – IMO it would better to havs the non-Size_T definition in the public header file, albeit shadowed by a macro, so only#undef would suffice. But that's an unrelated issue.

+1

@erlend-aaslanderlend-aasland merged commit3d94319 intopython:mainNov 14, 2022
@erlend-aaslanderlend-aasland deleted the testcapi/extract-arg-stuff branchNovember 14, 2022 21:23
CuriousLearner added a commit to CuriousLearner/cpython that referenced this pull requestNov 16, 2022
* main: (8272 commits)  Update Windows readme.txt to clarify Visual Studio required versions (pythonGH-99522)pythongh-99460 Emscripten trampolines on optimized METH_O and METH_NOARGS code paths (python#99461)pythongh-92647: [Enum] use final status to determine lookup or create (pythonGH-99500)pythongh-81057: Move Globals in Core Code to _PyRuntimeState (pythongh-99496)  Post 3.12.0a2pythongh-99300: Use Py_NewRef() in Python/Python-ast.c (python#99499)pythongh-93649: Split pytime and datetime tests from _testcapimodule.c (python#99494)pythongh-99370: fix test_zippath_from_non_installed_posix (pythonGH-99483)pythonGH-99205: remove `_static` field from `PyThreadState` and `PyInterpreterState` (pythonGH-99385)pythongh-81057: Move the Remaining Import State Globals to _PyRuntimeState (pythongh-99488)pythongh-87604: Avoid publishing list of active per-interpreter audit hooks via the gc module (pythonGH-99373)pythongh-93649: Split getargs tests from _testcapimodule.c (python#99346)pythongh-81057: Move Global Variables Holding Objects to _PyRuntimeState. (pythongh-99487)pythonGH-98219: reduce sleep time in `asyncio` subprocess test (python#99464)pythonGH-99388: add `loop_factory` parameter to `asyncio.run` (python#99462)pythongh-99300: Use Py_NewRef() in PC/ directory (python#99479)pythongh-99300: Use Py_NewRef() in Doc/ directory  (python#99480)pythongh-99300: Use Py_NewRef() in Modules/ directory (python#99473)pythongh-99300: Use Py_NewRef() in Modules/ directory (python#99469)pythongh-99370: Calculate zip path from prefix when in a venv (pythonGH-99371)  ...
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@encukouencukouencukou approved these changes

Assignees
No one assigned
Labels
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@erlend-aasland@encukou@bedevere-bot

[8]ページ先頭

©2009-2025 Movatter.jp