feat(tools): Go module enrichment in get_dependency_blast_radius - #106
Open
manus-use wants to merge 1 commit into
Open
feat(tools): Go module enrichment in get_dependency_blast_radius#106manus-use wants to merge 1 commit into
manus-use wants to merge 1 commit into
Conversation
Add _enrich_go() to get_dependency_blast_radius.py, giving the blast-radius tool first-class support for the Go ecosystem alongside npm, PyPI, and Maven. Data sources (both free, no API key required): - Go module proxy https://proxy.golang.org/{module}/@latest → latest semver tag + release timestamp - deps.dev API https://api.deps.dev/v3alpha/systems/GO/packages/{module} → full version list, per-version publishedAt timestamps → first_release_date, age_years, total_versions Design: - _parse_go_timestamp(): robust ISO-8601 parser shared by both calls; handles Z suffix, +00:00 offset, naive TZ, sub-second fractions up to 7-digit .NET-style ticks (truncated to 6 for Python datetime) - Module paths URL-encoded with urllib.parse.quote (safe="") so "golang.org/x/net" → "golang.org%2Fx%2Fnet" in both API URLs - Two independent try/except blocks: proxy failure still yields deps.dev data; deps.dev failure still yields the latest-version from proxy - Dispatch: eco_lower in ("go", "golang") routes to _enrich_go() - Output block: Latest version, Total versions, First released (+ age), Latest release date — rendered only for Go ecosystem Tests (17 new, 100% mocked): - TestParseGoTimestamp (7): Z suffix, +00:00 offset, naive TZ, microseconds, 7-digit ticks, empty string, invalid string - TestEnrichGo (7): happy path metadata, URL encoding, proxy-only fallback, deps.dev-only fallback, both-fail minimal record, empty version list, missing publishedAt skipped - TestEnrichPackageDispatch (2): "Go" and "golang" aliases - TestGetDependencyBlastRadius (1): Go output block rendered in integration
This was referenced Jul 8, 2026
This was referenced Jul 11, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Adds
_enrich_go()toget_dependency_blast_radius.py, giving the blast-radius tool first-class support for the Go ecosystem alongside the existing npm, PyPI, and Maven enrichers.What changed
src/manus_agent/tools/get_dependency_blast_radius.py_parse_go_timestamp(ts)Zsuffix,+00:00offset, naive TZ, sub-second fractions up to 7-digit .NET-style ticks_enrich_go(name)_enrich_package()dispatch"go"/"golang"ecosystem strings route to_enrich_go()Data sources (both free, unauthenticated)
Go module proxy
https://proxy.golang.org/{module}/@latestdeps.dev API
https://api.deps.dev/v3alpha/systems/GO/packages/{module}publishedAttimestampsfirst_release_date,age_years,total_versionsDesign decisions
urllib.parse.quote(name, safe="")sogolang.org/x/net→golang.org%2Fx%2Fnetin both API URLs (required by Go proxy spec)_parse_go_timestamptruncates fractional seconds to 6 digits before callingdatetime.fromisoformatto handle.NET-style 7-digit ticksweekly_downloadsis not set for Go packages (no equivalent public metric); blast score falls through toUNKNOWNfor packages with no download/dependent signal — honest and correcttests/test_dependency_blast_radius.py17 new tests, 100% mocked — no real HTTP calls:
TestParseGoTimestampTestEnrichGoTestEnrichPackageDispatch"Go"and"golang"ecosystem aliasesTestGetDependencyBlastRadiusSuite results: 1175 passed, 0 failures (baseline was 1158; +17 new tests).
Example output
No-duplicate confirmation
Checked all open and merged PRs before building. No existing PR covers Go module enrichment in
get_dependency_blast_radius.Open PRs checked (no overlap): #51, #53, #54, #58, #60, #64, #65, #67, #74, #75, #76, #77, #78, #79, #80, #82, #83, #85, #86, #87, #88, #89, #90, #96, #97, #98, #100, #103, #104, #105