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: johnmarktaylor91/torchlens
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v1.0.0
Choose a base ref
...
head repository: johnmarktaylor91/torchlens
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v1.0.1
Choose a head ref
  • 5 commits
  • 6 files changed
  • 2 contributors

Commits on Mar 13, 2026

  1. chore: add secret detection pre-commit hooks

    Add detect-private-key (pre-commit-hooks) and detect-secrets (Yelp) to
    catch leaked keys, tokens, and high-entropy strings before they hit the repo.
    johnmarktaylor91 committed Mar 13, 2026
    Configuration menu
    Copy the full SHA
    0e2889a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    84d4644 View commit details
    Browse the repository at this point in the history

Commits on Mar 23, 2026

  1. fix(decoration): clear stale sq_item C slot after wrapping Tensor.__g…

    …etitem__
    
    When __getitem__ is replaced on a C extension type with a Python function,
    CPython sets the sq_item slot in tp_as_sequence. This makes
    PySequence_Check(tensor) return True (was False in clean PyTorch), causing
    torch.tensor([0-d_tensor, ...]) to iterate elements as sequences and call
    len() -- which raises TypeError for 0-d tensors. The slot is never cleared
    by restoring the original wrapper_descriptor or by delattr.
    
    Fix: null sq_item via ctypes after every decoration/undecoration cycle
    (decorate_all_once, unwrap_torch, wrap_torch). Safe because tensor indexing
    uses mp_subscript (mapping protocol), not sq_item (sequence protocol).
    Verified via tp_name guard; fails silently on non-CPython.
    
    Adds 9 regression tests covering all lifecycle paths.
    johnmarktaylor91 committed Mar 23, 2026
    Configuration menu
    Copy the full SHA
    b2c6085 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    fb897e0 View commit details
    Browse the repository at this point in the history
  3. chore(release): 1.0.1

    semantic-release committed Mar 23, 2026
    Configuration menu
    Copy the full SHA
    1af6785 View commit details
    Browse the repository at this point in the history
Loading