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

safe-global / safe-client-gateway / 36135650865
65%

Build:
DEFAULT BRANCH: main
Ran 25 Sep 2026 12:39PM UTC
Jobs 2
Files 1025
Run time 2min
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

25 Sep 2026 12:33PM UTC coverage: 89.162% (-0.02%) from 89.182%
36135650865

push

github

web-flow
feat(policies): add the policy indexer client for allowance-module state (#3392)

* feat(policies): add the policy indexer client for allowance-module state

The Policy Indexer aggregates module and guard logs into current-state rows, so
CGW reads state and folds no events itself. This client reads the
allowance-module half: SafeAllowance and SafeDelegate, and nothing else. Guard
bindings live in SafePolicy, which is a field this PR deliberately does not
request - a type it cannot report is a field it should not pay for, and the PR
that reports them adds it.

One request covers any number of Safes on any number of chains, which is what
lets a Space-level read cost one round-trip instead of one per Safe.

Five properties of the read contract, each verified against the live endpoint,
shape the code - and each is silently wrong if ignored:

- `numeric` columns serialise as decimal strings. Base units stay strings all
  the way to the wire, because parsing an 18-decimal amount into a number
  truncates it into a plausible, wrong figure. Seconds and minutes are
  converted, and rejected rather than truncated if they would not fit.
- `chainId` is an Int upstream and a string everywhere in CGW, converted once at
  the schema boundary.
- addresses are stored checksummed, and a lower-cased address in a filter
  matches nothing *and returns no error* - so the repository checksums before
  asking, or a Safe silently reads as having no policies.
- `resetphase` and the other enum-looking columns are custom scalars rather than
  GraphQL enums, so their value sets are validated here. An unrecognised reset
  phase reads as ASSUMED - the pessimistic answer - rather than as exact.
- pairs are grouped per chain under `_or`. A flat chainId/safe pair of `_in`
  filters is a cross-product, which returns rows for a Safe on a chain it is not
  held on.

Per-row validation is lenient and logged: a row shape added by a newer indexer
release must not blank a Safe's policies. A ... (continued)

4410 of 5194 branches covered (84.91%)

Branch coverage included in aggregate %.

127 of 137 new or added lines in 11 files covered. (92.7%)

2 existing lines in 2 files now uncovered.

11246 of 12365 relevant lines covered (90.95%)

537.35 hits per line

Uncovered Changes

Lines Coverage ∆ File
5
84.21
-15.79% src/datasources/cache/__tests__/fake.cache.service.ts
5
72.29
-8.53% src/datasources/cache/redis.cache.service.ts

Coverage Regressions

Lines Coverage ∆ File
1
86.67
-5.0% src/modules/notifications/routes/v1/notifications.controller.ts
1
83.96
-0.94% src/modules/relay/domain/relayers/no-fee-campaign.relayer.ts
Jobs
ID Job ID Ran Files Coverage
1 run-integration-tests - 36135650865.1 25 Sep 2026 12:41PM UTC 1025
63.49
GitHub Action Run
2 run-unit-tests - 36135650865.2 25 Sep 2026 12:39PM UTC 1025
66.46
GitHub Action Run
Source Files on build 36135650865
  • Tree
  • List 1025
  • Changed 16
  • Source Changed 9
  • Coverage Changed 15
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #36135650865
  • 22a7ca46 on github
  • Prev Build on main (#36134770622)
  • Next Build on main (#36136421482)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc