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

decentraland / comms-gatekeeper / 25122685231
85%
main: 85%

Build:
Build:
LAST BUILD BRANCH: 2.27.1
DEFAULT BRANCH: main
Ran 29 Apr 2026 05:05PM UTC
Jobs 1
Files 145
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

29 Apr 2026 05:02PM UTC coverage: 85.27% (+1.4%) from 83.825%
25122685231

Pull #259

github

LautaroPetaccio
refactor: centralize names cache management and add negative caching

Restructures src/adapters/names.ts so getNamesFromAddresses is the sole
owner of nameByAddressCache, and starts caching negative results so
addresses the upstream confirms have no profile aren't re-fetched.

- fetchProfileBatch no longer touches the cache; it just parses the
  /profiles response into a map of resolved names. The owning batch in
  getNamesFromAddresses now persists both positive entries (string
  name) and negative entries (null) for every address it owned, so a
  later call for an address with no profile reads the null marker
  instead of issuing a fresh POST.
- nameByAddressCache value type widened from `string` to `string | null`,
  with a header comment explaining the null sentinel.
- Variable names dropped the `lower` / `lowerAddresses` prefixes;
  intermediate maps and locals use `address` / `addresses`. A comment
  at the top of getNamesFromAddresses notes that intermediate state is
  keyed by lowercased addresses while the result preserves caller
  casing, and the loop uses `inputAddress` shadowed by `const address`
  for the lowercased form.
- JSDoc on fetchProfileBatch documenting that the cache is owned
  externally; JSDoc on getNamesFromAddresses describing the three
  layers of dedup.

Adds three test cases to test/unit/names.spec.ts under "and an address
has no profile upstream" verifying the negative-cache behaviour.
Pull Request #259: fix: cache hoisting, dedup, and variant caching across adapters

1045 of 1343 branches covered (77.81%)

Branch coverage included in aggregate %.

100 of 101 new or added lines in 7 files covered. (99.01%)

2955 of 3348 relevant lines covered (88.26%)

43.25 hits per line

Uncovered Changes

Lines Coverage ∆ File
1
92.73
71.45% src/adapters/names.ts
Jobs
ID Job ID Ran Files Coverage
1 25122685231.1 29 Apr 2026 05:05PM UTC 290
86.49
GitHub Action Run
Source Files on build 25122685231
  • Tree
  • List 145
  • Changed 98
  • Source Changed 7
  • Coverage Changed 98
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #25122685231
  • Pull Request #259
  • PR Base - main (#24993564023)
  • 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