Conversation
|
/condalock |
|
@tsnow03, might need to revert f1d6150 and 83cfd30, don't think the default GITHUB_TOKEN is working either. ##[group]Run if [[ $(git ls-files --modified) ]]; then
�[36;1mif [[ $(git ls-files --modified) ]]; then�[0m
�[36;1m git config --global user.name 'actions-bot'�[0m
�[36;1m git config --global user.email '58130806+actions-bot@users.noreply.github.com'�[0m
�[36;1m git remote set-url origin https://x-access-token:${GITHUB_TOKEN}@github.com/CryoInTheCloud/hub-image.git�[0m
�[36;1m git commit --all --message "[condalock-command] autogenerated conda-lock files"�[0m
�[36;1m git push�[0m
�[36;1mfi�[0m
shell: /usr/bin/bash -e {0}
env:
MAMBA_ROOT_PREFIX: /home/runner/micromamba
MAMBA_EXE: /home/runner/micromamba-bin/micromamba
CONDARC: /home/runner/work/_temp/setup-micromamba/.condarc
GITHUB_TOKEN: ***
##[endgroup]
[jh5 e777206] [condalock-command] autogenerated conda-lock files
2 files changed, 711 insertions(+), 550 deletions(-)
remote: Invalid username or token. Password authentication is not supported for Git operations.
fatal: Authentication failed for 'https://github.com/CryoInTheCloud/hub-image.git/'
##[error]Process completed with exit code 128.We should use the cryointhecloud-bot GitHub App token auth, but problem is that the token expires after 1 hour as mentioned in #157 (comment). Edit: done in #185 |
|
Do you have to involve the github-app-token at all in the condalock-command workflow? The create-or-update-comment action should work with built-in |
Probably not in this case since the PR is made on a branch under For context, I added the token stuff back in 2022 (#5), when GITHUB_TOKEN didn't quite work with create-or-update-comment I think, even from non-forks. But situation might be a little different now. If we don't mind not being able to run the workflow on forks (e.g. casual user not in the organisation wanting to update some dependency), then probably ok to just use GITHUB_TOKEN. |
|
Thanks @weiji14. This is super weird. I think we occasionally have people from outside the org so it would be good to keep it. It doesn't seem like that is the issue we are having though. |
|
I'm seeing this error in the logs on another run in #189: Thinking that there might be an issue with the bot's private key? I'm gonna regenerate it and refresh the |
|
The |
We could keep it for the create-or-update-comment action, while removing it from actions/checkout (which would also make the
No this doesn't fix the slow solve issue, but it might prevent the workflow from failing because of the slow solve. The create-github-app-token step could be after the locking step, so timeout wouldn't be an issue. |
|
Draft with suggested permissions and reordering is in #191. |
|
/condalock |
|
Here are the packages in
|
weiji14
left a comment
There was a problem hiding this comment.
Cool, thanks @itcarroll for figuring out those token permissions! I just have one note below, otherwise should be ok to merge today.
|
@tsnow03 The expected check can be ignored; haven't figured out how to fine tune that rule since we removed spurious triggers to re-build the image. |
That hub-image/.github/workflows/test.yaml Lines 3 to 7 in f449351 but it doesn't look like the job is running somehow? This reminds me of icesat2py/icepyx#756 (comment) - wherein the commit needs to be made with a PAT instead of the default GITHUB_TOKEN to trigger a job, maybe #191 wasn't a good idea... |
|
😢 Maybe the only good idea was requesting the token after running conda lock. (And fixing the "hooray"!) So we change the step order again and put the |
|
I think we want to revert most of #191 (generate the token and use it for 'actions/checkout', so no need to use |
|
While you do that, I'll just push a tiny commit here, so the checks will run and we can get this PR merged. |
I don't see how we do this, necessarily before the conda solve, without going back to having a push error if the token expires. The token has a max duration of one hour, right? |
Yes, token expires in 1 hour (there's a way to extend it following actions/create-github-app-token#121 (comment) but too complicated). The main issue is still the slow solver (it honestly shouldn't take more than an hour). I'm holding my breath for conda-lock to support mamba 2.6.0's repodata shards (#157 (comment)), hopefully by end of this week - conda/conda-lock#907 🤞 which should improve the situation. |
jupyterhub single user is 4.0 but needs to be 5.0 to maintain stability for the 2i2c deployment.