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

fix(f3): when returning a partially used lease, trim its ValidityTerm #12667

Merged
merged 1 commit into from
Nov 1, 2024

Conversation

Kubuxu
Copy link
Contributor

@Kubuxu Kubuxu commented Nov 1, 2024

Otherwise the early renew logic will never trigger.

Signed-off-by: Jakub Sztandera <oss@kubuxu.com>
@Kubuxu Kubuxu added skip/changelog This change does not require CHANGELOG.md update release/backport labels Nov 1, 2024
Copy link
Member

@Stebalien Stebalien left a comment

Choose a reason for hiding this comment

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

... I thought I had tested this. How is anything working?

@Stebalien Stebalien merged commit 49f3b55 into master Nov 1, 2024
86 of 87 checks passed
@Stebalien Stebalien deleted the fix/f3-lease-validity-term branch November 1, 2024 04:10
@Stebalien
Copy link
Member

Oh, I see. The lease will eventually expire. We just won't get the overlap behavior.

@@ -104,6 +104,8 @@ func (l *leaser) participate(ticket api.F3ParticipationTicket) (api.F3Participat
if found {
// short-circuite for reparticipation.
if currentLease == newLease {
newLease.ValidityTerm = newLease.ToInstance() - instant.ID
newLease.FromInstance = instant.ID
Copy link
Member

Choose a reason for hiding this comment

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

New lease is not stored in lease map. Should it be?

Copy link
Member

Choose a reason for hiding this comment

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

It shouldn't be stored because the lease in the lease map is the decoded ticket. It's... confusing and we should probably do something about it.

Kubuxu added a commit to Kubuxu/curio that referenced this pull request Nov 1, 2024
lotus-rc2 miss-registered error types, rc3 does it correctly
Next release will additionally contain fix for early reneweal. filecoin-project/lotus#12667
filecoin-project#312 is still an issue

Signed-off-by: Jakub Sztandera <oss@kubuxu.com>
Kubuxu added a commit to Kubuxu/curio that referenced this pull request Nov 1, 2024
lotus-rc2 miss-registered error types, rc3 does it correctly
Next release will additionally contain fix for early reneweal. filecoin-project/lotus#12667
filecoin-project#312 is still an issue

Signed-off-by: Jakub Sztandera <oss@kubuxu.com>
magik6k pushed a commit to filecoin-project/curio that referenced this pull request Nov 2, 2024
lotus-rc2 miss-registered error types, rc3 does it correctly
Next release will additionally contain fix for early reneweal. filecoin-project/lotus#12667
#312 is still an issue

Signed-off-by: Jakub Sztandera <oss@kubuxu.com>
rjan90 pushed a commit that referenced this pull request Nov 4, 2024
rjan90 pushed a commit that referenced this pull request Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip/changelog This change does not require CHANGELOG.md update
Projects
Status: ☑️ Done (Archive)
Development

Successfully merging this pull request may close these issues.

4 participants