Skip to content

fix: use proper debug mode detection#26

Merged
iBotPeaches merged 1 commit intomasterfrom
proper-debug-mode
Jan 28, 2026
Merged

fix: use proper debug mode detection#26
iBotPeaches merged 1 commit intomasterfrom
proper-debug-mode

Conversation

@iBotPeaches
Copy link
Member

While investigating #25 I cannot see debug information :/

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adjusts debug-mode detection in the deployment script so additional diagnostic output is emitted when debugging is enabled, to help investigate task-definition JSON failures (Issue #25).

Changes:

  • Switches debug gating from ACTIONS_RUNNER_DEBUG == true to checking whether ACTIONS_RUNNER_DEBUG is non-empty.
  • Applies the updated debug gating to both modified-task-definition output and diff output.
Comments suppressed due to low confidence (1)

deploy.sh:165

  • The JSON validity check is currently incorrect: jq is invoked without a filter (so it exits non-zero in standard jq), and the condition is not negated. As written, the "invalid JSON" branch is either never entered or entered on valid JSON (depending on jq behavior). Update this to run a real validation (e.g., jq -e . against the file) and trigger the error branch only when validation fails.
    if jq < "$TASK_DEFINITION_FILE" &> /dev/null; then
        echo -e "${RED}Task Definition became invalid JSON after modifications (invalid_task_definition)."

        if [ -n "$ACTIONS_RUNNER_DEBUG" ]; then
            echo "::debug::Debug enabled. Outputting modified Task Definition file.";
            cat "$TASK_DEFINITION_FILE"
        fi

        exit 1;

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@iBotPeaches iBotPeaches merged commit cd223db into master Jan 28, 2026
7 checks passed
@iBotPeaches iBotPeaches deleted the proper-debug-mode branch January 28, 2026 19:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

5 participants