Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: RustPython/RustPython
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main@{1day}
Choose a base ref
...
head repository: RustPython/RustPython
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
  • 3 commits
  • 8 files changed
  • 3 contributors

Commits on Apr 13, 2026

  1. Update LICENSE (#7581)

    StepfenShawn authored Apr 13, 2026
    Configuration menu
    Copy the full SHA
    27aed85 View commit details
    Browse the repository at this point in the history
  2. Add InstructionMetadata::stack_effect_jump for branch stack effects (#…

    …7585)
    
    * Add InstructionMetadata::stack_effect_jump for branch stack effects
    
    CPython's compile.c provides stack_effect(opcode, oparg, jump) where the
    jump parameter selects between fallthrough and branch effects. The existing
    stack_effect() only returns the fallthrough effect.
    
    Add stack_effect_jump() that returns the branch effect. Most instructions
    have identical fallthrough/branch effects; ForIter and Send are the
    exceptions (ForIter: fallthrough=+1, branch=-1; Send: fallthrough=0,
    branch=-1).
    
    * apply review
    youknowone authored Apr 13, 2026
    Configuration menu
    Copy the full SHA
    7e5e026 View commit details
    Browse the repository at this point in the history
  3. Add __callback__ property to weakref type (#7590)

    * Initial plan
    
    * Add __callback__ property to PyWeak for weakref compatibility
    
    Add get_callback() method to PyWeak in core.rs that safely reads the
    callback field under the stripe lock. Expose it as a read-only
    __callback__ property on the weakref type, matching CPython behavior:
    - Returns the callback function when one was provided and referent is alive
    - Returns None when no callback was provided
    - Returns None after the referent has been collected
    - Raises AttributeError on assignment (read-only)
    
    Remove @unittest.expectedFailure from test_callback_attribute and
    test_callback_attribute_after_deletion in test_weakref.py.
    
    Add regression tests to extra_tests/snippets/stdlib_weakref.py.
    
    Agent-Logs-Url: https://github.com/RustPython/RustPython/sessions/a8689daa-4476-4645-a935-0e13c7f7bb42
    
    Co-authored-by: youknowone <69878+youknowone@users.noreply.github.com>
    
    * Fix ruff formatting in stdlib_weakref.py snippet
    
    Agent-Logs-Url: https://github.com/RustPython/RustPython/sessions/4995198f-e083-4dac-823a-166fcf54adc4
    
    Co-authored-by: youknowone <69878+youknowone@users.noreply.github.com>
    
    ---------
    
    Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
    Co-authored-by: youknowone <69878+youknowone@users.noreply.github.com>
    Copilot and youknowone authored Apr 13, 2026
    Configuration menu
    Copy the full SHA
    7e637e8 View commit details
    Browse the repository at this point in the history
Loading