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

Makes time is up to date when compiling CLN for CI jobs #264

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

sr-gi
Copy link
Member

@sr-gi sr-gi commented Sep 5, 2024

Compiling time with rustc over 1.80.0 (inclusive) results in a crash for old versions of the time crate, which CLN uses. Make sure we are up to date with the current revision

@sr-gi sr-gi changed the title Makes sure the time create is up to date Makes time is up to date when compiling CLN for CI jobs Sep 5, 2024
Compiling time with rustc over 1.80.0 (inclusive) results in a crash
for old versions of the time crate, which CLN uses. Make sure we are up
to date with the current revision
@sr-gi sr-gi merged commit 9248f3a into talaia-labs:master Sep 5, 2024
6 of 7 checks passed
@@ -38,6 +38,7 @@ jobs:
sudo apt-get update && sudo apt-get install -y gettext
git clone https://github.com/ElementsProject/lightning.git && cd lightning && git checkout v${{ env.cln_version }}
pip install --user poetry && poetry install
cargo update -p time
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but now the versions are no longer locked!

this usually is more problematic. we don't always get the case where a change in rust version breaks something (happened today though :/), but the case where a change in the package version breaks something happens more often.

I would argue even that the first case should be addressed swiftly anyway because a crate doesn't want to not support a recent rust version ofc.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this should be ok given it is only used to create the cache, so as long as we do not update the bitcoind or cln versions, the time version will be "locked".

We can revert once the issue is fixed upstream and remove this workaround

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so as long as we do not update the bitcoind or cln versions, the time version will be "locked".

No, i think this will update time when a new version of time shows up.

That said, I confused what this cargo update was for. I thought it was for a toes crate (thus we can just run it locally to get a new lock file and push it on github so it's updated and locked), but since it's for cln, I think we should fix that in cln repo.

Copy link
Member Author

@sr-gi sr-gi Sep 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is run only when there is a cache miss, so a new cache is created. Caches are named after the os version, bitcoind version and cln version, which are all locked, so the cache creation should happen only once (or once every time GitHub decides to delete the cache files).

I opened an issue upstream so this can be addressed

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

Successfully merging this pull request may close these issues.

2 participants