Skip to content

docs: annotate vbtoken pricing safety checks#1350

Open
BobTheBuidler wants to merge 1 commit intomasterfrom
docs/vbtoken-safety-notes-20260218
Open

docs: annotate vbtoken pricing safety checks#1350
BobTheBuidler wants to merge 1 commit intomasterfrom
docs/vbtoken-safety-notes-20260218

Conversation

@BobTheBuidler
Copy link
Copy Markdown
Owner

Summary

  • Document vbToken safety assumptions and guardrails in pricing paths.

Rationale

  • Make explicit the fail-closed behavior and solvency verification needed to keep vbToken prices valid.

Details

  • Added comments in y/prices/one_to_one.py to call out allowlist, solvency guard, and implementation verification.
  • Added a vbToken fail-closed note near the DEX fallback in y/prices/magic.py.
  • Clarified in y/prices/yearn.py that ERC-4626 conversion methods are estimates and should be used only for solvency checks.

Tests

  • PYTEST_ADDOPTS="-p no:pytest_ethereum" BROWNIE_NETWORK=mainnet make test (41 failed, 141 passed, 101 skipped; Brownie UnicodeDecodeError during teardown)
  • Mypyc extensions built via python setup.py build_ext --inplace and confirmed compiled module load path for y/_db/brownie.cpython-312-x86_64-linux-gnu.so.

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.

1 participant