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-101747: Fix refleak in new `OrderedDict` repr by sobolevn · Pull Request #101748 · python/cpython

Conversation

@sobolevn

@sobolevn sobolevn commented Feb 9, 2023 •
edited by bedevere-bot
Loading

Uh oh!

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

Copy link
Copy Markdown
Member

After: ./python.exe -m test -v test_ordered_dict -R 3:3

Ran 279 tests in 1.460s

OK
.

== Tests result: SUCCESS ==

1 test OK.

Total duration: 10.2 sec
Tests result: SUCCESS
  • Issue: Refleak after new OrderedDict repr #101747

Sorry, something went wrong.

Uh oh!

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

All reactions
@sobolevn
pythongh-101747: Fix refleak in new OrderedDict repr
f8adfe9
@sobolevn
sobolevn requested a review from corona10 February 9, 2023 17:10
@bedevere-bot bedevere-bot added the awaiting review label Feb 9, 2023
@bedevere-bot bedevere-bot mentioned this pull request Feb 9, 2023
Refleak after new OrderedDict repr #101747
Closed
@sobolevn sobolevn added the skip news label Feb 9, 2023
@corona10 corona10 added the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Feb 9, 2023
@bedevere-bot

bedevere-bot commented Feb 9, 2023

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @corona10 for commit f8adfe9 🤖

If you want to schedule another build, you need to add the :hammer: test-with-refleak-buildbots label again.

All reactions

Sorry, something went wrong.

Uh oh!

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

@bedevere-bot bedevere-bot removed the 🔨 test-with-refleak-buildbots Test PR w/ refleak buildbots; report in status section label Feb 9, 2023
kumaraditya303
kumaraditya303 approved these changes Feb 9, 2023
View reviewed changes
@bedevere-bot bedevere-bot added awaiting merge and removed awaiting review labels Feb 9, 2023
erlend-aasland
erlend-aasland approved these changes Feb 9, 2023
View reviewed changes
@erlend-aasland

erlend-aasland commented Feb 9, 2023

Copy link
Copy Markdown
Contributor

The aarch64 RHEL8 refleak bot still reports a leak. Could you please examine, @sobolevn?

All reactions

Sorry, something went wrong.

Uh oh!

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

serhiy-storchaka
serhiy-storchaka reviewed Feb 9, 2023
View reviewed changes
Comment thread Objects/odictobject.c Outdated

Done:
Py_ReprLeave((PyObject *)self);
Py_XDECREF(dcopy);

@serhiy-storchaka serhiy-storchaka Feb 9, 2023

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

You can move it above the Done label and change Py_XDECREF to Py_DECREF.

Sorry, something went wrong.

Uh oh!

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

erlend-aasland reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

@sobolevn sobolevn Feb 9, 2023

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Thanks, it might be a slightly more readable! I will wait for all tests to finish and apply it :)

Sorry, something went wrong.

Uh oh!

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

All reactions
@sobolevn

sobolevn commented Feb 9, 2023

Copy link
Copy Markdown
Member Author

@erlend-aasland it reports:

test_importlib leaked [6, 4, 2] references, sum=12
test_importlib leaked [4, 4, 2] memory blocks, sum=10

I think these leaks are not related 🤔

Should I fix it here?

All reactions

Sorry, something went wrong.

Uh oh!

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

@erlend-aasland

erlend-aasland commented Feb 9, 2023

Copy link
Copy Markdown
Contributor

Should I fix it here?

I prefer one fix per PR; that makes it easier to bisect in case something goes wrong, and it also makes for a cleaner git history.

All reactions

Sorry, something went wrong.

Uh oh!

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

@sobolevn
Apply code review suggestion
dce3ec1
@sobolevn

sobolevn commented Feb 9, 2023

Copy link
Copy Markdown
Member Author

@erlend-aasland then I consider this done:

  1. Review suggestion is applied
  2. New issue is created: Refleak in test_importlib on aarch64 RHEL8 #101766
All reactions

Sorry, something went wrong.

Uh oh!

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

corona10
corona10 approved these changes Feb 9, 2023
View reviewed changes

@corona10 corona10 left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

lgtm

Sorry, something went wrong.

Uh oh!

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

All reactions
@corona10
corona10 requested a review from serhiy-storchaka February 9, 2023 23:35
@corona10

corona10 commented Feb 9, 2023

Copy link
Copy Markdown
Member

I will merge this PR after waiting for @serhiy-storchaka approval

test_importlib leaked [6, 4, 2] references, sum=12

I can not reproduce the issue on my macOS. It sounds like we have to debug on the RHEL machine.

erlend-aasland reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

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

@sobolevn sobolevn mentioned this pull request Feb 9, 2023
gh-101703: use PyOS_snprintf instead of sprintf #101729
Closed
rhettinger
rhettinger approved these changes Feb 10, 2023
View reviewed changes
@rhettinger
rhettinger merged commit 34c50ce into python:main Feb 10, 2023
@bedevere-bot bedevere-bot removed the awaiting merge label Feb 10, 2023
carljm added a commit to carljm/cpython that referenced this pull request Feb 10, 2023
@carljm
Merge branch 'main' into inlinecomp2
add772e
* main:
  Fix some typos in asdl_c.py (pythonGH-101757)
  pythongh-101747: Fix refleak in new `OrderedDict` repr (pythonGH-101748)
  pythongh-101430: Update tracemalloc to handle presize properly. (pythongh-101745)
  pythonGH-101228: Fix typo in docstring for read method of `_io.TextIOWrapper` class (python#101227)
  Fix typo in `test_fstring.py` (python#101600)
  pythongh-101726: Update the OpenSSL version to 1.1.1t (pythonGH-101727)
  pythongh-101283: Fix 'versionchanged' for the shell=True fallback on Windows in 3.12 (pythonGH-101728)
  LibFFI build requires x64 Cygwin, and skip the ARM build (pythonGH-101743)
@arhadthedev arhadthedev mentioned this pull request Feb 10, 2023
Make Bedevere showing label names like GitHub does python/buildmaster-config#361
Merged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@rhettinger rhettinger rhettinger approved these changes
@corona10 corona10 corona10 approved these changes
@erlend-aasland erlend-aasland erlend-aasland approved these changes
@kumaraditya303 kumaraditya303 kumaraditya303 approved these changes
@serhiy-storchaka serhiy-storchaka Awaiting requested review from serhiy-storchaka

Uh oh!

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

Assignees

No one assigned

Labels

skip news

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

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

7 participants

@sobolevn @bedevere-bot @erlend-aasland @corona10 @rhettinger @serhiy-storchaka @kumaraditya303
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.