fix: publish FWSS library ABIs#522
Conversation
There was a problem hiding this comment.
Pull request overview
This PR ensures ABI artifacts are published not only for core FWSS contracts, but also for non-empty first-party libraries (notably Rails, which defines event signatures consumed externally).
Changes:
- Updates
make update-abito rebuild from a clean Foundry build and (intended to) discover non-empty ABIs for libraries undersrc/lib/. - Documents that consumers should include
Rails.abi.jsonin addition to the main FWSS ABI to subscribe to proxy-emitted events. - Adds checked-in ABI JSON artifacts for
RailsandSignatureVerificationLib.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| service_contracts/README.md | Updates ABI management docs to include library ABIs and event-consumer guidance. |
| service_contracts/Makefile | Reworks update-abi to regenerate ABIs from a clean build and attempt library ABI discovery from artifacts. |
| service_contracts/abi/SignatureVerificationLib.abi.json | Adds published ABI artifact for the signature helper library. |
| service_contracts/abi/Rails.abi.json | Adds published ABI artifact for Rails-emitted FWSS proxy events. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
This creates a separate abi.json for the libraries but ideally we would want the events from those libraries included in the ABI of the implementation that links them. This is because web3 libraries reading ABI will assume the events were emitted from the contract address with the ABI, but libraries are accessed via We could keep them separate like this but then the merging would need to happen in all of the consumers. I think it best we merge the ABIs in one place. A similar problem occurs with proxy ABI; what these have in common is |
Rails library in particular has event signatures, and I've just discovered that we don't have these published ABI artifacts. I guess we've missed the 1.3.0 boat but we should remember for next time - any non-empty library we extract should have ABI artifcats included.