Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG]: workflow treated as invalid if it contains a disabled step #16

Closed
2 tasks done
firewave opened this issue Nov 26, 2024 · 3 comments · Fixed by #17 or woodruffw/zizmor#211
Closed
2 tasks done

[BUG]: workflow treated as invalid if it contains a disabled step #16

firewave opened this issue Nov 26, 2024 · 3 comments · Fixed by #17 or woodruffw/zizmor#211
Assignees
Labels
bug Something isn't working

Comments

@firewave
Copy link

firewave commented Nov 26, 2024

Pre-submission checks

  • I am not filing a feature request. These should be filed via the feature request form instead.
  • I have looked through the open issues for a duplicate report.

Expected behavior

The workflow is successfully analyzed.

Actual behavior

The analysis fails saying the workflow is invalid.

Reproduction steps

Analyze the included workflow.

Logs

failed to register workflow: ".github/workflows/workflow.yml"

Caused by:
    0: couldn't load workflow from file
    1: invalid GitHub Actions workflow: ".github/workflows/workflow.yml"
    2: jobs: data did not match any variant of untagged enum Job at line 6 column 3

Additional context

name: Name

on: [push]

jobs:
  build:
    runs-on: ubuntu-22.04
    steps:
      - name: Step
        if: false
        run: echo
@firewave firewave added the bug Something isn't working label Nov 26, 2024
@woodruffw
Copy link
Owner

Thanks for the report @firewave! I'll triage this in a bit.

@woodruffw woodruffw self-assigned this Nov 27, 2024
@woodruffw woodruffw transferred this issue from woodruffw/zizmor Nov 27, 2024
@woodruffw
Copy link
Owner

I've root-caused this as an incorrect assumption in my handling of conditions; the fix is in #17.

@woodruffw
Copy link
Owner

Done; this will be bumped into a zizmor release pretty soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
2 participants