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

Import All not working #2

Closed
Stanzilla opened this issue Jan 24, 2022 · 11 comments
Closed

Import All not working #2

Stanzilla opened this issue Jan 24, 2022 · 11 comments

Comments

@Stanzilla
Copy link

Hey there! My config looks like this

name: Create issues for TODOs

on:
  workflow_dispatch:
    inputs:
      importAll:
        default: "false"
        required: false
        type: boolean
        description: Enable, if you want to import all TODOs.
  push:
    branches:
      - development

permissions:
  issues: write
  repository-projects: read
  contents: read

jobs:
  todos:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v2

      - name: Run Issue Bot
        uses: derjuulsn/todo-issue@main
        with:
          excludePattern: "^(mkdocs-material/|src/assets/javascripts/)"
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Yet, every time I want to kick off a manual run with import all, it errors with Action can only be used on trigger push or in manual and importAll mode any ideas?

@DerJuulsn
Copy link
Owner

Hey! Did you activate the Import All option before you click Run Workflow?

image

@Stanzilla
Copy link
Author

Hey! Did you activate the Import All option before you click Run Workflow?

image

Yeah I did! Could it be something about the quotes? Your example has single quotes, I use double?

@DerJuulsn
Copy link
Owner

Nope, that shouldn't be it. As a workaround: change the input type to string instead of boolean and write true in the text field.
That should work.
I've read something about bools are not real bools in workflow inputs but kinda ignored it haha :)

@Stanzilla
Copy link
Author

Nope, that shouldn't be it. As a workaround: change the input type to string instead of boolean and write true in the text field. That should work. I've read something about bools are not real bools in workflow inputs but kinda ignored it haha :)

Still fails, sadly :(

The logs don't have much either:

2022-01-24T15:30:49.5493690Z [command]/usr/bin/git log -1 --format='%H'
2022-01-24T15:30:49.5525703Z '899b4abbafd91466ab0696644f33e98c3714d509'
2022-01-24T15:30:49.5778210Z ##[group]Run derjuulsn/todo-issue@main
2022-01-24T15:30:49.5778502Z with:
2022-01-24T15:30:49.5778809Z   excludePattern: ^(mkdocs-material/|src/assets/javascripts/)
2022-01-24T15:30:49.5779124Z   keywords: TODO
2022-01-24T15:30:49.5779490Z env:
2022-01-24T15:30:49.5780106Z   GITHUB_TOKEN: ***
2022-01-24T15:30:49.5780328Z ##[endgroup]
2022-01-24T15:30:51.6131335Z ##[error]Action can only be used on trigger push or in manual and importAll mode
2022-01-24T15:30:51.6819161Z Post job cleanup.

@DerJuulsn
Copy link
Owner

You can change your input type back to boolean now. The latest change should fix the issue.

DerJuulsn added a commit that referenced this issue Jan 24, 2022
@Stanzilla
Copy link
Author

Stanzilla commented Jan 24, 2022

Edit: looks like it worked, thanks!

@gunar
Copy link

gunar commented Aug 6, 2022

I'm having the same problem:

Action can only be used on trigger push or in manual and importAll mode

Tried all variations of default: 'true', type: boolean and type: string, etc… nothing makes importAll work :(

I'm wondering if this exceptions that is thrown has anything to do with it:

image

@DerJuulsn
Copy link
Owner

DerJuulsn commented Sep 5, 2022

Hey @gunar

solved it with v1.1.3. Sorry for responding that late.
Overlooked the comment in this closed issue ;)

@gunar
Copy link

gunar commented Sep 5, 2022

@DerJuulsn Thanks for circling back. I'm still getting Error: Action can only be used on trigger push or in manual and importAll mode.

I'm assuming @main should get me the latest version right?

image

@DerJuulsn
Copy link
Owner

@gunar My bad, fixed now!

@gunar
Copy link

gunar commented Sep 6, 2022

Much better, thanks @DerJuulsn!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants