• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

graphprotocol / indexer-rs / 21598084083
69%

Build:
DEFAULT BRANCH: main
Ran 02 Feb 2026 04:24PM UTC
Jobs 1
Files 97
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

02 Feb 2026 04:19PM UTC coverage: 68.628% (+0.2%) from 68.459%
21598084083

push

github

web-flow
Fix TapReceipt type mismatch in allocation middleware (#919)

* fix: use TapReceipt type in allocation middleware

The allocation middleware was looking for `SignedReceipt` (V1 inner type)
in request extensions, but `receipt_middleware` inserts `TapReceipt` (enum).
This TypeId mismatch caused the lookup to always fail, falling back to
the `deployment_to_allocation` map which returns an arbitrary allocation.

When multiple allocations exist for the same deployment, this could cause:
- Attestations signed with wrong allocation's derived key
- Gateway verification failures ("bad attestation" errors)
- Incorrect metrics attribution

* test(service): add unit tests for allocation middleware V2 receipt handling

- Add test for extracting allocation ID from TapReceipt V2
- Add test for fallback to DeploymentId when no receipt present
- Add test for graceful handling without receipt or deployment ID
- Add test for unknown deployment IDs not in mapping

* ci: make clippy and format happy

Signed-off-by: Natanael Mojica <neithanmo@gmail.com>

---------

Signed-off-by: Natanael Mojica <neithanmo@gmail.com>

103 of 107 new or added lines in 1 file covered. (96.26%)

10476 of 15265 relevant lines covered (68.63%)

81.15 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
4
97.4
-1.01% crates/service/src/middleware/allocation.rs
Jobs
ID Job ID Ran Files Coverage
1 21598084083.1 02 Feb 2026 04:24PM UTC 97
68.63
GitHub Action Run
Source Files on build 21598084083
  • Tree
  • List 97
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #21598084083
  • 51c9c8af on github
  • Prev Build on main (#21593420756)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc