Skip to content

Commit

Permalink
Use access token GIX_CREATE_PR_PAT instead of GIX_SNSDEMO_BOT_GH_TOKEN (
Browse files Browse the repository at this point in the history
#393)

# Motivation

The [latest
run](https://github.com/dfinity/snsdemo/actions/runs/10553072245/job/29232813566)
to update the IC commit in snsdemo, had the following error:
```
fatal: could not read Username for 'https://github.com': No such device or address
```

After some searching, I found
[this](peter-evans/create-pull-request#2094),
indicating that this is an issue with the access token.

After switching from `GIX_SNSDEMO_BOT_GH_TOKEN` to `GIX_CREATE_PR_PAT`,
the issue went away.
We already use `GIX_CREATE_PR_PAT` in `nns-dapp`, `ic-js` and
`gix-components` so it seems fine to use in snsdemo as well. The snsdemo
repo already had access to the token.

# Changes

Change the version of `peter-evans/create-pull-request` that we use from
v4 to v5.

# Tests

Ran the workflow from the branch and it succeeded:

https://github.com/dfinity/snsdemo/actions/runs/10556505138/job/29242171471
And it created this PR:
#392
  • Loading branch information
dskloetd authored Aug 26, 2024
1 parent 75d023a commit 61f7e89
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/update-dfx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
if: ${{ steps.update.outputs.updated == '1' }}
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GIX_SNSDEMO_BOT_GH_TOKEN }}
token: ${{ secrets.GIX_CREATE_PR_PAT }}
base: main
add-paths: |
dfx.json
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/update-ic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
if: ${{ steps.update.outputs.updated == '1' }}
uses: peter-evans/create-pull-request@v4
with:
token: ${{ secrets.GIX_SNSDEMO_BOT_GH_TOKEN }}
token: ${{ secrets.GIX_CREATE_PR_PAT }}
base: main
add-paths: |
bin/versions.bash
Expand Down

0 comments on commit 61f7e89

Please sign in to comment.