Skip to content

gh-87452 Making returncode unreliability explicit - #92181

Merged
gpshead merged 19 commits into
python:mainfrom
zitterbewegung:gh-87452
Apr 24, 2023
Merged

gh-87452 Making returncode unreliability explicit#92181
gpshead merged 19 commits into
python:mainfrom
zitterbewegung:gh-87452

Conversation

@zitterbewegung

@zitterbewegungzitterbewegung commented May 2, 2022

Copy link
Copy Markdown
Contributor

We make explicit that the value stored in return code is best returned by poll instead of using the value in return code.

gh-87452: Making returncode unreliability explicit

@bedevere-bot

Copy link
Copy Markdown

Every change to Python requires a NEWS entry.

Please, add it using the blurb_it Web app or the blurb command-line tool.

@bedevere-botbedevere-bot added docs Documentation in the Doc dir awaiting review labels May 2, 2022
@zitterbewegungzitterbewegung changed the title Making returncode unreliability explicitgh-87452 Making returncode unreliability explicitMay 2, 2022
@benjaminp

Copy link
Copy Markdown
Contributor

Thank you for the PR.

I don't think "out-of-date" is the right term here. Either the entire subprocess.Subprocess instance is aware of the exit of the child process and knows the return code, or it doesn't. The first paragraph of the method documentation could perhaps be rearranged to more clearly state the order of events instead of appending another sentence.

@benjaminp

Copy link
Copy Markdown
Contributor

I would propose:

The child return code. Initially ``None``, :attr:`returncode` is set by :meth:`poll` and :meth:`wait` after process termination is observed.
``

Comment threadDoc/library/subprocess.rst Outdated
Comment threadDoc/library/subprocess.rst Outdated
@erlend-aasland

Copy link
Copy Markdown
Contributor

Please remove the duplicate NEWS entry.

Comment threadDoc/library/subprocess.rst Outdated
Comment threadDoc/library/subprocess.rst Outdated
Co-authored-by: Oleg Iarygin <dralife@yandex.ru>

@erlend-aaslanderlend-aasland left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Again, please remove the duplicate NEWS entry. Also please address Benjamin's remarks.

Comment threadDoc/library/subprocess.rst Outdated
@bedevere-bot

Copy link
Copy Markdown

A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated.

Once you have made the requested changes, please leave a comment on this pull request containing the phrase I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@slateny

Copy link
Copy Markdown
Contributor

@zitterbewegung Would you still be interested in giving the PR a quick update per the reviews above?

@zitterbewegung

Copy link
Copy Markdown
ContributorAuthor

Sorry I can do that.

Wrapping to 79 characters.
@netlify

netlifyBot commented Dec 6, 2022

Copy link
Copy Markdown

Deploy Preview for python-cpython-preview ready!

NameLink
🔨 Latest commit41a5d22
🔍 Latest deploy loghttps://app.netlify.com/sites/python-cpython-preview/deploys/638f5503b72cc30008de175b
😎 Deploy Previewhttps://deploy-preview-92181--python-cpython-preview.netlify.app/whatsnew/changelog
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@zitterbewegungzitterbewegung left a comment

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Fixed word wrap issue
  • Removed duplicate news entry.

@zitterbewegungzitterbewegung left a comment

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed trailing whitespace

@zitterbewegung

Copy link
Copy Markdown
ContributorAuthor

I have made the requested changes; please review again.

@bedevere-bot

Copy link
Copy Markdown

Thanks for making the requested changes!

@erlend-aasland: please review the changes made to this pull request.

@zitterbewegung

Copy link
Copy Markdown
ContributorAuthor

@erlend-aasland can this be reviewed?

@gpsheadgpshead self-assigned this Apr 24, 2023
@gpshead
gpshead merged commit 68f5836 into python:mainApr 24, 2023
@miss-islington

Copy link
Copy Markdown
Contributor

Thanks @zitterbewegung for the PR, and @gpshead for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

@erlend-aasland

Copy link
Copy Markdown
Contributor

Sorry for the delay; thanks Greg for merging. Thanks for the PR, Joshua.

@terryjreedyterryjreedy removed the needs backport to 3.11 only security fixes label Feb 18, 2025
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docsDocumentation in the Doc dirskip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants

@zitterbewegung@bedevere-bot@benjaminp@erlend-aasland@slateny@miss-islington@arhadthedev@furkanonder@gpshead@terryjreedy