Skip to content

switch safe-eth-py dep to patched version and rename Safe API auth arg#76

Open
wavey0x wants to merge 1 commit intobanteg:masterfrom
wavey0x:api_auth
Open

switch safe-eth-py dep to patched version and rename Safe API auth arg#76
wavey0x wants to merge 1 commit intobanteg:masterfrom
wavey0x:api_auth

Conversation

@wavey0x
Copy link
Copy Markdown

@wavey0x wavey0x commented Mar 9, 2026

  • support env variable name that matches what's called for in safe-eth-py
  • point to patched safe-eth-py which:
    • preserves eth-brownie requirement that web3 be version <7.0.0
    • resolves base_url based on new Safe transaction service URLs
    • resolves AttributeError: 'LocalAccount' object has no attribute 'signHash'

@banteg
Copy link
Copy Markdown
Owner

banteg commented Mar 10, 2026

is there a better way than to rely or wavey backport? basically we are blocked by different web3 py requirement between brownie and safe-eth-py?

@banteg
Copy link
Copy Markdown
Owner

banteg commented Mar 10, 2026

Yes, basically.

  • eth-brownie 1.20.7 wants web3>=6,<7
  • the last upstream safe-eth-py release on that line is v6.4.0
  • upstream safe-eth-py v7+ moved to web3>=7, so we can't just consume the newer upstream fixes while staying on Brownie

There's also a separate break on the old line: safe-eth-py v6.4.0 still uses signHash, but current eth-account uses unsafe_sign_hash, so v6.4.0 can fail even with web3 6.

One nuance: the old safe-transaction-*.safe.global hosts still redirect to api.safe.global, so the hostname move by itself is not the hard blocker. The real blocker is that the useful Safe tx-service/auth fixes now live on the post-web3 7 line, while Brownie is still pinned to pre-web3 7.

So the practical options are:

  1. keep a minimal pre-web3 7 backport/fork for the needed fixes
  2. vendor those small patches locally in brownie-safe
  3. move off Brownie / wait for a web3 7-capable stack

If we keep the fork, we should pin an exact commit/tag instead of a mutable branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants