Skip to content

Report malformed release metadata without an installer traceback #174

Open

Description

@LunaStev

Audited against merged master 13289d7a74ad45561554bbb6673a189dbb192a27 (PR #161).

Problem and reproduction

Several external JSON fields are indexed without shape validation. The top-level error handler does not catch resulting KeyError/TypeError exceptions, so malformed metadata can produce a Python traceback instead of the installer's normal diagnostic.

Reproduced by mocking the release API response to:

{"draft": false, "tag_name": "v0.0.2-beta"}

With host and gh discovery mocked, tools.install.main() raises KeyError('assets'). No download or destination replacement is needed to reach this failure.

Scope and acceptance

  • Validate the release asset list and tag-object shapes before indexing fields that installation depends on.
  • Produce a concise error describing the malformed response and missing/invalid field.
  • Test missing assets, wrong container types, malformed asset entries and malformed tag objects using mocked responses.
  • Leave any previous installation intact and preserve temporary-file cleanup.
  • Do not mask programming errors with a blanket except Exception, relax official-URL checks or skip verification.

This covers response-shape handling; subprocess deadlines are a separate small fix.

Starting points

This is a bounded follow-up suitable for a first contribution; no broader feature redesign is requested.

Activity

  1. added
    bugSomething isn't working
    good first issueIssues that are good for newcomers or first-time contributors.
    ui/uxIssues related to command-line usability, diagnostics, and user experience.
    releaseIssues related to packaging, installation, versioning, and releases.
    on Oct 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueIssues that are good for newcomers or first-time contributors.releaseIssues related to packaging, installation, versioning, and releases.ui/uxIssues related to command-line usability, diagnostics, and user experience.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions