Repository navigation
fix(overpass): send OVERPASS_URL credentials as Basic auth - #686
Merged
Medformatik merged 1 commit intoOct 30, 2026
Merged
Medformatik merged 1 commit into
Medformatik merged 1 commit into
Conversation
fetch refuses a URL carrying credentials, so queries to an OVERPASS_URL like https://user:pass@host always failed, with the password in the error. Send them as an Authorization header through the shared core helper.
Medformatik
force-pushed
the
fix/overpass-url-credentials
branch
from
October 30, 2026 09:49
52c8211 to
58f471c
Compare
Medformatik
merged commit Oct 30, 2026
c245756
into
fix/overpass-health-follows-instance
25 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed and why
Stacked on #685, whose core helper it reuses; the diff against #685's branch is this one commit.
An operator can point OpenMapX at a hosted Overpass with
OVERPASS_URL, including one that needs a login (https://user:pass@host). Every query to such an instance failed. Node'sfetchrefuses a URL that carries credentials, throwingRequest cannot be constructed from a URL that includes credentials: https://user:pass@host/…, so the password also ended up in the error.The Overpass client now sends such credentials as a Basic
Authorizationheader and queries the URL without them, through the sameurlCredentialsAsBasicAuthhelper the health checks use since #685. Attribution keeps resolving from the host, now taken from the URL without credentials. Instances without credentials are unaffected.Verification
OVERPASS_URLwith credentials goes tohttps://overpass.example.org/api/interpreterwithAuthorization: Basic …for those credentials. The existing Overpass client tests still pass, including the public-mirror fallback.fetch("https://u:p@example.com")throws the error quoted above.pnpm lint,pnpm check-typesandpnpm check:policypass. The full Vitest suite passes (1,953 files, 24,087 tests) exceptmotis-probe.test.ts's socket-retry test. That test is flaky: it failed 1 of 5 isolated reruns on this same code, and it drives a real socket throughnode:httpin the data manager, which this change doesn't touch.Release and upgrade impact
Product impact: ordinary
No package release: the change is limited to the Overpass client in the private
@openmapx/corepackage; neither published package's source changes in this commit.