Skip to content

Refleak in LOAD_SUPER_ATTR_ATTR #104413

@JelleZijlstra

Description

@JelleZijlstra

The buildbots show a refleak in test_super. I narrowed it down to this:

"""Unit tests for zero-argument super() & related machinery."""

import unittest


class TestSuper(unittest.TestCase):

    def test_attribute_error(self):
        class C:
            def method(self):
                return super().msg

        try:
            C().method()
        except AttributeError:
            pass


if __name__ == "__main__":
    unittest.main()

And found a fix. PR incoming.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    type-bugAn unexpected behavior, bug, or error

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy