GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-103329: Add regression test for PropertyMock with side effect by freakboy3742 · Pull Request #103358 · python/cpython

Conversation

@freakboy3742

@freakboy3742 freakboy3742 commented Apr 8, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

#102213 introduced an optimisation to __getattr__ that had some unexpected side effects, one of which was a change in behavior of PropertyMock when the property has a side effect.

This change was reverted in #103332; This PR adds a regression test to ensure that PropertyMock behavior is preserved. It also enhances the test of the return value for PropertyMock.

Fixes #103329.

  • Issue: 3.12.0a7 changes behavior of PropertyMock #103329

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@freakboy3742
Add regression test for python#103329.
26f2709
@freakboy3742
freakboy3742 requested a review from cjw296 as a code owner April 8, 2023 00:43
@bedevere-bot bedevere-bot mentioned this pull request Apr 8, 2023
3.12.0a7 changes behavior of PropertyMock #103329
Closed
@bedevere-bot bedevere-bot added the awaiting review label Apr 8, 2023
@blurb-it
📜🤖 Added by blurb_it.
45a4070
carljm
carljm reviewed Apr 8, 2023
View reviewed changes
Comment thread Lib/test/test_unittest/testmock/testhelpers.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

@carljm
Update Lib/test/test_unittest/testmock/testhelpers.py
1a94fad
@carljm

carljm commented Apr 8, 2023

Copy link
Copy Markdown
Member

Thanks @freakboy3742! (Also, hello!)

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@freakboy3742

freakboy3742 commented Apr 8, 2023

Copy link
Copy Markdown
Contributor Author

@carljm 👋

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@carljm carljm added the needs backport to 3.11 only security fixes label Apr 8, 2023
@carljm
carljm merged commit 26c6598 into python:main Apr 8, 2023
@miss-islington

miss-islington commented Apr 8, 2023

Copy link
Copy Markdown
Contributor

Thanks @freakboy3742 for the PR, and @carljm for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot bedevere-bot removed the awaiting review label Apr 8, 2023
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Apr 8, 2023
@freakboy3742 @miss-islington
pythongh-103329: Add regression test for PropertyMock with side effect (
6c3da92
pythonGH-103358)

(cherry picked from commit 26c6598)

Co-authored-by: Russell Keith-Magee <[email protected]>
@bedevere-bot

bedevere-bot commented Apr 8, 2023

Copy link
Copy Markdown

GH-103364 is a backport of this pull request to the 3.11 branch.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Apr 8, 2023
@freakboy3742
freakboy3742 deleted the propertymock_sideeffect branch April 8, 2023 02:09
@freakboy3742 freakboy3742 mentioned this pull request Apr 8, 2023
CI Tests Failure with Release of Python 3.12.0-alpha.7 beeware/briefcase#1165
Closed
miss-islington added a commit that referenced this pull request Apr 8, 2023
@miss-islington @freakboy3742
gh-103329: Add regression test for PropertyMock with side effect (GH-…
29a1e89
…103358)

(cherry picked from commit 26c6598)

Co-authored-by: Russell Keith-Magee <[email protected]>
warsaw pushed a commit to warsaw/cpython that referenced this pull request Apr 11, 2023
@freakboy3742 @warsaw
pythongh-103329: Add regression test for PropertyMock with side effect (
8c2786a
python#103358)
@sunmy2019 sunmy2019 mentioned this pull request Apr 25, 2023
gh-102213: Optimize the performance of __getattr__ #103761
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@carljm carljm carljm left review comments
@cjw296 cjw296 Awaiting requested review from cjw296 cjw296 is a code owner

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3.12.0a7 changes behavior of PropertyMock

Uh oh!

There was an error while loading. Please reload this page.

4 participants

@freakboy3742 @carljm @miss-islington @bedevere-bot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.