mongolyy / reviewdog-action-biome

MIT License
19 stars 2 forks source link

Fix `cannot open lib/biome.sh: No such file` #35

Closed skanehira closed 3 months ago

skanehira commented 3 months ago

Fix this error when I use workdir

Run $GITHUB_ACTION_PATH/script.sh
  $GITHUB_ACTION_PATH/script.sh
  shell: /usr/bin/bash --noprofile --norc -e -o pipefail {0}
  env:
    WORKING_DIRECTORY: cdk
    SSH_KEY: ***

    PNPM_HOME: /home/runner/setup-pnpm/node_modules/.bin
    INPUT_GITHUB_TOKEN: ***
    INPUT_WORKDIR: cdk
    INPUT_TOOL_NAME: Biome
    INPUT_LEVEL: warning
    INPUT_REPORTER: github-pr-review
    INPUT_FILTER_MODE: nofilter
    INPUT_FAIL_ON_ERROR: true
    INPUT_REVIEWDOG_FLAGS: 
    INPUT_BIOME_FLAGS: .
/home/runner/work/_actions/mongolyy/reviewdog-action-biome/v1/script.sh: 4: .: cannot open lib/biome.sh: No such file
mongolyy commented 3 months ago

@skanehira Thanks for your first contribution.

I think the reason for the failure of test github action is that the existing configuration is not authoritative enough. I will check with you later, but you are welcome to handle this on your end.

test shell script may not be a concern once the test results are unstable. I'll check it later on my end.

mongolyy commented 3 months ago

@skanehira I did some research. #36

If not forking, the current settings seemed to work fine. 987e6d1

The required permissions were as follows. 99de72a Could you please add the permission settings as well and push?

skanehira commented 3 months ago

@skanehira I did some research. #36

If not forking, the current settings seemed to work fine. 987e6d1

The required permissions were as follows. 99de72a Could you please add the permission settings as well and push?

Thank you :) Added permissions

mongolyy commented 3 months ago

Added permissions

Thank you for your response. However, it doesn't seem to be working. https://github.com/mongolyy/reviewdog-action-biome/actions/runs/8410034096/job/23034283589

I see in the log that the check permission is set to read. 2024-03-25_08h32_03

I will investigate today why this is happening. I'm assuming it's a result of the settings in github, but if you know anything about it on your end, I'd appreciate it if you could let me know!

skanehira commented 3 months ago

Added permissions

Thank you for your response. However, it doesn't seem to be working. https://github.com/mongolyy/reviewdog-action-biome/actions/runs/8410034096/job/23034283589

I see in the log that the check permission is set to read. 2024-03-25_08h32_03

I will investigate today why this is happening. I'm assuming it's a result of the settings in github, but if you know anything about it on your end, I'd appreciate it if you could let me know!

Humm... I try added this settings but it didn't works. I'll take a look later 🙏

      pull-requests: write
      checks: write
      contents: read
mongolyy commented 3 months ago

@skanehira

I try added this settings but it didn't works.

Thank you for trying. I think it is difficult to give write permission for forked repositories with the current trigger. https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token

Need to change test to fix this problem, but difficult to do right away. I'm not sure how to fix this problem.

On the other hand, we think this defect should be resolved as soon as possible. Since we have confirmed that the test succeeds even in #36, we are willing to tolerate the fact that the test is failing.

If you can revert the changes in .github/workflows/test-action.yml, I will approve and merge this.

skanehira commented 3 months ago

@skanehira

I try added this settings but it didn't works.

Thank you for trying. I think it is difficult to give write permission for forked repositories with the current trigger. https://docs.github.com/en/actions/security-guides/automatic-token-authentication#permissions-for-the-github_token

Need to change test to fix this problem, but difficult to do right away. I'm not sure how to fix this problem.

On the other hand, we think this defect should be resolved as soon as possible. Since we have confirmed that the test succeeds even in #36, we are willing to tolerate the fact that the test is failing.

If you can revert the changes in .github/workflows/test-action.yml, I will approve and merge this.

@mongolyy Thank you :) I removed permissions

github-actions[bot] commented 3 months ago

🚀 [bumpr] Bumped! New version:v1.3.2 Changes:v1.3.1...v1.3.2