[PR #1829] [MERGED] perf(browser): parse captured module URLs once per lookup #4845

Closed
opened 2026-10-31 00:55:53 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/morluto/rea/pull/1829
Author: @shayanxcyber
Created: 10/11/2026
Status: ✅ Merged
Merged: 10/11/2026
Merged by: @morluto

Base: main ← Head: perf/reuse-captured-module-url


📝 Commits (1)

  • 0870b3f perf(browser): parse captured module URLs once per lookup

📊 Changes

2 files changed (+27 additions, -14 deletions)

View changed files

📝 src/domain/webModuleImports.test.ts (+16 -0)
📝 src/domain/webModuleImports.ts (+11 -14)

📄 Description

Captured-module matching currently parses the same reported URL separately for each non-exact scenario-response candidate. Parse it once per matching operation and reuse its fragment-free form.

This preserves exact reported identities, query-version distinctions, candidate order and all captured versions. Invalid or relative URL strings still support exact matching and do not gain a fragment-stripped response match.

Validation: all 8 tests in src/domain/webModuleImports.test.ts pass via npm run test:local -- src/domain/webModuleImports.test.ts, including a new non-URL identity case. Focused oxfmt, oxlint and git diff --check pass.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/morluto/rea/pull/1829 **Author:** [@shayanxcyber](https://github.com/shayanxcyber) **Created:** 10/11/2026 **Status:** ✅ Merged **Merged:** 10/11/2026 **Merged by:** [@morluto](https://github.com/morluto) **Base:** `main` ← **Head:** `perf/reuse-captured-module-url` --- ### 📝 Commits (1) - [`0870b3f`](https://github.com/morluto/rea/commit/0870b3fc993071adb44739a7143a46f2f970bf89) perf(browser): parse captured module URLs once per lookup ### 📊 Changes **2 files changed** (+27 additions, -14 deletions) <details> <summary>View changed files</summary> 📝 `src/domain/webModuleImports.test.ts` (+16 -0) 📝 `src/domain/webModuleImports.ts` (+11 -14) </details> ### 📄 Description Captured-module matching currently parses the same reported URL separately for each non-exact scenario-response candidate. Parse it once per matching operation and reuse its fragment-free form. This preserves exact reported identities, query-version distinctions, candidate order and all captured versions. Invalid or relative URL strings still support exact matching and do not gain a fragment-stripped response match. Validation: all 8 tests in `src/domain/webModuleImports.test.ts` pass via `npm run test:local -- src/domain/webModuleImports.test.ts`, including a new non-URL identity case. Focused oxfmt, oxlint and `git diff --check` pass. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 00:55:53 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
morluto/rea#4845
No description provided.