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

ruby-grape / grape / 24754575829
97%

Build:
DEFAULT BRANCH: master
Ran 22 Apr 2026 01:01AM UTC
Jobs 37
Files 155
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

22 Apr 2026 01:00AM UTC coverage: 96.998% (+0.004%) from 96.994%
24754575829

push

github

web-flow
Avoid empty-hash merges on request hot paths (#2689)

Three `|| {}` patterns on the per-request path allocated an empty Hash
and handed it to a merge that produced a shallow copy of the left-hand
side — pure waste. Guard the merge when the right-hand side is absent
or empty instead.

When a route has no path placeholders (or none captured), `route.params`
returns an empty Hash (or nil). The old code did
`args.merge(route_params || {})`, allocating `{}` and then a new hash
identical to `args` on every matched static route.

`grape_routing_args` falls back to `{}` when env has no routing args.
`deep_merge!` on `{}` is a walking no-op. Skip the call entirely when
routing_args is empty.

`(body || {}).merge(key => representation)` — when no body is set
(the common case), this allocated `{}` only to merge one key into it.
Build the one-key hash directly.

process_route, no route_params (static path, common case):
  old: 4.48 M i/s, 480 objects allocated / 1k calls
  new: 8.31 M i/s, 160 objects allocated / 1k calls  (1.85x faster, 3x fewer)

process_route, empty {} route_params:
  old: 5.16 M i/s, 320 objects / 1k calls
  new: 8.02 M i/s, 160 objects / 1k calls  (1.55x faster, 2x fewer)

process_route, real route_params: within noise (unchanged path).

No behavior change; all 2,236 specs pass.

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>

1077 of 1161 branches covered (92.76%)

Branch coverage included in aggregate %.

5 of 5 new or added lines in 3 files covered. (100.0%)

3350 of 3403 relevant lines covered (98.44%)

32235.21 hits per line

Jobs
ID Job ID Ran Files Coverage
1 run-4.0-gemfiles/rails_7_2.gemfile - 24754575829.1 22 Apr 2026 01:01AM UTC 155
95.68
GitHub Action Run
2 run-4.0-gemfiles/rack_3_2.gemfile - 24754575829.2 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
3 run-4.0-gemfiles/rails_8_1.gemfile - 24754575829.3 22 Apr 2026 01:02AM UTC 155
95.68
GitHub Action Run
4 run-4.0-gemfiles/grape_entity.gemfile - 24754575829.4 22 Apr 2026 01:01AM UTC 154
49.44
GitHub Action Run
5 run-3.3-gemfiles/rails_8_0.gemfile - 24754575829.5 22 Apr 2026 01:01AM UTC 155
95.66
GitHub Action Run
6 run-3.4-gemfiles/rails_8_1.gemfile - 24754575829.6 22 Apr 2026 01:01AM UTC 155
95.68
GitHub Action Run
7 run-3.4-gemfiles/rack_3_1.gemfile - 24754575829.7 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
8 run-3.3-Gemfile - 24754575829.8 22 Apr 2026 01:01AM UTC 154
95.65
GitHub Action Run
9 run-3.3-gemfiles/rack_3_0.gemfile - 24754575829.9 22 Apr 2026 01:01AM UTC 154
95.65
GitHub Action Run
10 run-3.3-gemfiles/rack_3_2.gemfile - 24754575829.10 22 Apr 2026 01:01AM UTC 154
95.65
GitHub Action Run
11 run-3.3-gemfiles/rack_3_1.gemfile - 24754575829.11 22 Apr 2026 01:01AM UTC 154
95.65
GitHub Action Run
12 run-4.0-Gemfile - 24754575829.12 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
13 run-3.3-gemfiles/rails_8_1.gemfile - 24754575829.13 22 Apr 2026 01:01AM UTC 155
95.66
GitHub Action Run
14 run-3.3-gemfiles/rack_2_2.gemfile - 24754575829.14 22 Apr 2026 01:01AM UTC 154
95.61
GitHub Action Run
15 run-3.4-gemfiles/rack_2_2.gemfile - 24754575829.15 22 Apr 2026 01:01AM UTC 154
95.63
GitHub Action Run
16 run-3.2-gemfiles/rails_8_0.gemfile - 24754575829.16 22 Apr 2026 01:01AM UTC 155
95.7
GitHub Action Run
17 run-3.2-gemfiles/rack_2_2.gemfile - 24754575829.17 22 Apr 2026 01:01AM UTC 154
95.65
GitHub Action Run
18 run-3.3-gemfiles/rails_7_2.gemfile - 24754575829.18 22 Apr 2026 01:01AM UTC 155
95.66
GitHub Action Run
19 run-4.0-gemfiles/rack_2_2.gemfile - 24754575829.19 22 Apr 2026 01:01AM UTC 154
95.63
GitHub Action Run
20 run-4.0-gemfiles/hashie.gemfile - 24754575829.20 22 Apr 2026 01:01AM UTC 154
62.49
GitHub Action Run
21 run-3.2-gemfiles/rails_7_2.gemfile - 24754575829.21 22 Apr 2026 01:01AM UTC 155
95.7
GitHub Action Run
22 run-4.0-gemfiles/rails_8_0.gemfile - 24754575829.22 22 Apr 2026 01:01AM UTC 155
95.68
GitHub Action Run
23 run-3.4-gemfiles/rack_3_2.gemfile - 24754575829.23 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
24 run-3.4-gemfiles/rails_7_2.gemfile - 24754575829.24 22 Apr 2026 01:01AM UTC 155
95.68
GitHub Action Run
25 run-4.0-gemfiles/dry_validation.gemfile - 24754575829.25 22 Apr 2026 01:01AM UTC 154
57.79
GitHub Action Run
26 run-3.2-Gemfile - 24754575829.26 22 Apr 2026 01:01AM UTC 154
95.7
GitHub Action Run
27 run-4.0-gemfiles/rack_3_1.gemfile - 24754575829.27 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
28 run-3.2-gemfiles/rack_3_1.gemfile - 24754575829.28 22 Apr 2026 01:01AM UTC 154
95.7
GitHub Action Run
29 run-4.0-gemfiles/multi_json.gemfile - 24754575829.29 22 Apr 2026 01:01AM UTC 154
35.95
GitHub Action Run
30 run-3.4-gemfiles/rack_3_0.gemfile - 24754575829.30 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
31 run-3.4-Gemfile - 24754575829.31 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
32 run-4.0-gemfiles/multi_xml.gemfile - 24754575829.32 22 Apr 2026 01:01AM UTC 154
35.95
GitHub Action Run
33 run-3.4-gemfiles/rails_8_0.gemfile - 24754575829.33 22 Apr 2026 01:01AM UTC 155
95.68
GitHub Action Run
34 run-3.2-gemfiles/rails_8_1.gemfile - 24754575829.34 22 Apr 2026 01:01AM UTC 155
95.7
GitHub Action Run
35 run-3.2-gemfiles/rack_3_0.gemfile - 24754575829.35 22 Apr 2026 01:01AM UTC 154
95.7
GitHub Action Run
36 run-4.0-gemfiles/rack_3_0.gemfile - 24754575829.36 22 Apr 2026 01:01AM UTC 154
95.67
GitHub Action Run
37 run-3.2-gemfiles/rack_3_2.gemfile - 24754575829.37 22 Apr 2026 01:01AM UTC 154
95.7
GitHub Action Run
Source Files on build 24754575829
  • Tree
  • List 155
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Repo
  • Github Actions Build #24754575829
  • 952a74c4 on github
  • Prev Build on master (#24699723680)
  • Next Build on master (#24754666104)
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