json-schema-org / community

A space to discuss community and organisational related things

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Bug : Failed execution of ocwm-issue-collector.yml

benjagm opened this issue · comments

The last execution of ocwm-issue-collector.yml failed.

The error seems the same than #644 and #640

The error is:
https://github.com/json-schema-org/community/actions/runs/8126662255/job/22210665104

##[debug]Loading env
Run actions/github-script@v6
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: No "exports" main defined in /home/runner/work/community/community/node_modules/@octokit/core/package.json
    at new NodeError (node:internal/errors:387:5)
    at throwExportsNotFound (node:internal/modules/esm/resolve:365:9)
    at packageExportsResolve (node:internal/modules/esm/resolve:589:7)
    at resolveExports (node:internal/modules/cjs/loader:556:36)
    at Function.Module._findPath (node:internal/modules/cjs/loader:596:31)
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:1014:27)
    at resolve (node:internal/modules/cjs/helpers:125:19)
    at Object.apply (/home/runner/work/_actions/actions/github-script/v6/dist/index.js:15188:43)
    at eval (eval at callAsyncFunction (/home/runner/work/_actions/actions/github-script/v6/dist/index.js:15[143](https://github.com/json-schema-org/community/actions/runs/8126662255/job/22210665104#step:5:144):16), <anonymous>:3:17)
    at callAsyncFunction (/home/runner/work/_actions/actions/github-script/v6/dist/index.js:15[144](https://github.com/json-schema-org/community/actions/runs/8126662255/job/22210665104#step:5:145):12) {
  code: 'ERR_PACKAGE_PATH_NOT_EXPORTED'
}
Error: Unhandled error: Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: No "exports" main defined in /home/runner/work/community/community/node_modules/@octokit/core/package.json
##[debug]Node Action run completed with exit code 1

hi @benjagm i have worked on workflows and pipelines and would be happy to work on any of #654 and #655 .

Thanks @satyam-x10 !!
Please take add a comment in #655. I'd assign to you both issues.

Hi @benjagm . I am pass through previous error , it was only a mere version issue. but i am getting a new error .
Error occurred: Validation Failed: {"message":"The listed users and repositories cannot be searched either because the resources do not exist or you do not have permission to view them.","resource":"Search","field":"q","code":"invalid"} - https://docs.github.com/v3/search/ . i think its permission issue and not any problem , let me know what you think

Hi @benjagm . I am pass through previous error , it was only a mere version issue. but i am getting a new error . Error occurred: Validation Failed: {"message":"The listed users and repositories cannot be searched either because the resources do not exist or you do not have permission to view them.","resource":"Search","field":"q","code":"invalid"} - https://docs.github.com/v3/search/

Hi @satyam-x10 can you share your fork(action) in which you have tried this action . Thanks !

Hi @benjagm . I am pass through previous error , it was only a mere version issue. but i am getting a new error . Error occurred: Validation Failed: {"message":"The listed users and repositories cannot be searched either because the resources do not exist or you do not have permission to view them.","resource":"Search","field":"q","code":"invalid"} - https://docs.github.com/v3/search/

Hi @satyam-x10 can you share your fork(action) in which you have tried this action . Thanks !

https://github.com/satyam-x10/community/actions/runs/8138716764/job/22240151811

@satyam-x10 the problem is probably your token in your fork. Right? Probably this is already working in our org with the production token.

@satyam-x10 you have not defined the below configuration variables at the repository

 env:
        MY_TOKEN: ${{ secrets.AUTH_TOKEN }}
        MY_LABEL: ${{ vars.OCWM_LABEL }}
        OWNER: ${{ vars.ORGANISATION }}
        REPO_NAMES: ${{ vars.REPOSITORIES }}

You can check more about it here

@satyam-x10 the problem is probably your token in your fork. Right? Probably this is already working in our org with the production token.

Yes.. the previous issue was because octokit had new update one week ago.. I changed it to last stable version

@satyam-x10 you have not defined the below configuration variables at the repository

 env:
        MY_TOKEN: ${{ secrets.AUTH_TOKEN }}
        MY_LABEL: ${{ vars.OCWM_LABEL }}
        OWNER: ${{ vars.ORGANISATION }}
        REPO_NAMES: ${{ vars.REPOSITORIES }}

You can check more about it here

yes , i dont have access to the env

Why not applying the same solution applied in #644 and #640?

Why not applying the same solution applied in #644 and #640?

just checked. it was fixed the same way

@satyam-x10 you have not defined the below configuration variables at the repository

 env:
        MY_TOKEN: ${{ secrets.AUTH_TOKEN }}
        MY_LABEL: ${{ vars.OCWM_LABEL }}
        OWNER: ${{ vars.ORGANISATION }}
        REPO_NAMES: ${{ vars.REPOSITORIES }}

You can check more about it here

yes , i dont have access to the env

Hey @satyam-x10 , You just need to downgrade octokit version and left everything as it is.
The workflow will get fails in your fork repo but will work in main repo.

happy coding : )

@satyam-x10 you have not defined the below configuration variables at the repository

 env:
        MY_TOKEN: ${{ secrets.AUTH_TOKEN }}
        MY_LABEL: ${{ vars.OCWM_LABEL }}
        OWNER: ${{ vars.ORGANISATION }}
        REPO_NAMES: ${{ vars.REPOSITORIES }}

You can check more about it here

yes , i dont have access to the env

Hey @satyam-x10 , You just need to downgrade octokit version and left everything as it is. The workflow will get fails in your fork repo but will work in main repo.

happy coding : )

yes thanks . did the same and Raise a PR for #655 . #654 has same fix but I think someone already fixed it.. please let me know

@satyam-x10 can't find the PR for this issue. Did you created it?

@satyam-x10 can't find the PR for this issue. Did you created it?

thanks for merging #655. whats the update on #654 , looks like someone already fixed that

Thanks @satyam-x10. I did some analysis and when fixing #640 the contributor fixed the wrong github action by mistake so they fixed this one but the one assiciated to #640 is still pending. Can you please add the change to:

https://github.com/json-schema-org/community/blob/main/.github/workflows/ocwm-creator.yml

So we leave everything aligned? My apologies for the misunderstanding.

Thanks @satyam-x10. I did some analysis and when fixing #640 the contributor fixed the wrong github action by mistake so they fixed this one but the one assiciated to #640 is still pending. Can you please add the change to:

https://github.com/json-schema-org/community/blob/main/.github/workflows/ocwm-creator.yml

So we leave everything aligned? My apologies for the misunderstanding.

Sure

@benjagm as asked i have made changes in ocwm-creator.yml and raised a PR. #661

Closed as completed.