Skip to content

Commit 37b8a26

Browse files
committed
FIP-0103: proposal to remove ExtendSectorExpiration
1 parent f19b792 commit 37b8a26

File tree

2 files changed

+78
-0
lines changed

2 files changed

+78
-0
lines changed

FIPS/fip-0103.md

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
---
2+
fip: "0103"
3+
title: Removal of the ExtendSectorExpiration method from the miner actor
4+
author: "Rod Vagg (@rvagg)"
5+
discussions-to: https://github.com/filecoin-project/FIPs/discussions/1116
6+
status: Draft
7+
type: Technical (Core)
8+
category: Core
9+
created: 2025-03-14
10+
spec-sections:
11+
requires: FIP-0045
12+
replaces: N/A
13+
---
14+
15+
# FIP-0103: Removal of the ExtendSectorExpiration method from the miner actor
16+
17+
## Simple Summary
18+
19+
This FIP proposes the removal of the `ExtendSectorExpiration` method from the miner actor as it has been superseded by the more flexible `ExtendSectorExpiration2` method, which was introduced in FIP-0045 and supports verified claims.
20+
21+
## Abstract
22+
23+
The `ExtendSectorExpiration` method in the miner actor was designed to allow storage providers to extend the commitment period of their sectors. However, with the introduction of `ExtendSectorExpiration2` in FIP-0045, which offers the same functionality plus additional flexibility for handling verified claims, the original method has become redundant. This proposal aims to remove the legacy `ExtendSectorExpiration` method to simplify the protocol, reduce technical debt, and streamline code pathways in the miner actor. It's important to note that sector extension functionality remains fully supported through the enhanced `ExtendSectorExpiration2` method.
24+
25+
## Change Motivation
26+
27+
The main motivation behind this change is to clean up builtin actors and reduce technical debt. By removing the redundant `ExtendSectorExpiration` method, we can simplify the protocol, making it more maintainable and less error-prone. The existence of two methods that serve similar purposes creates unnecessary complexity in the codebase and requires additional maintenance overhead. Since `ExtendSectorExpiration2` provides enhanced functionality including support for verified claims, there is no longer a need to maintain the original method.
28+
29+
## Specification
30+
31+
Implementation-wise, this change involves removing the `ExtendSectorExpiration` method from the miner actor, along with all associated helper methods that are not used by other methods, and all tests that uniquely test its functionality.
32+
33+
## Design Rationale
34+
35+
The decision to propose this change follows the same principle as FIP-0101, which removed the `ProveCommitAggregate` method. When newer, more flexible methods are available and in use, removing redundant legacy methods simplifies the codebase and reduces maintenance burden.
36+
37+
With `ExtendSectorExpiration2` fully supporting all functionality of the original method plus additional capabilities for verified claims, maintaining both methods is unnecessary and adds complexity. Efficient and clean code is prioritised over accumulated complexity that increases the potential for bugs.
38+
39+
## Backwards Compatibility
40+
41+
This change will not introduce any backward incompatibilities, as the `ExtendSectorExpiration2` method fully covers all the functionality previously offered by `ExtendSectorExpiration`. Storage providers have already migrated to using the newer method. The last `ExtendSectorExpiration` message recorded on-chain was on 2024-12-15 (over 3 months ago from this FIP creation), as evidenced by transaction [`bafy2bzacecmyltma2j42wai3vqymu6apmcervz3eia3oixhyyls2tdcvj7okm`](https://filfox.info/en/message/bafy2bzacecmyltma2j42wai3vqymu6apmcervz3eia3oixhyyls2tdcvj7okm). Tooling and client libraries have been updated to use `ExtendSectorExpiration2`, making this a safe removal that simplifies the API without affecting functionality.
42+
43+
## Test Cases
44+
45+
Test cases will need to ensure that `ExtendSectorExpiration2` method adequately covers all the functionality previously offered by `ExtendSectorExpiration` and that the system behaves normally following the removal.
46+
47+
Care should be taken with the removal of `ExtendSectorExpiration` tests to avoid removal of tests for other parts of the system that are not covered by other test cases. In this situation, tests should be reworked to use `ExtendSectorExpiration2` to test the same functionality.
48+
49+
## Security Considerations
50+
51+
This FIP doesn't alter any security features of the Filecoin protocol, as it only involves the removal of a deprecated method that has been superseded by a more capable one. It may potentially reduce the attack surface area where there could be previously unknown security bugs.
52+
53+
## Incentive Considerations
54+
55+
Removing the `ExtendSectorExpiration` method from the miner actor does not have any direct impact on the incentive mechanisms in the Filecoin protocol. All the functionality continues to be available through `ExtendSectorExpiration2`, so there are no changes to the incentives for extending sector commitments.
56+
57+
## Product Considerations
58+
59+
Once the deprecated `ExtendSectorExpiration` method is removed, users and developers will experience a cleaner and less confusing system. Having a single method for extending sector expiration makes the API more consistent and easier to understand. Additionally, the simplification of code pathways in the miner actor could potentially enable further optimisations in the future.
60+
61+
## Implementation
62+
63+
As the implementation involves removal of a method from the current codebase, it is expected to be relatively straightforward and low-risk.
64+
65+
No migration is necessary as the functionality remains available through the existing `ExtendSectorExpiration2` method.
66+
67+
### Removal tasks
68+
69+
- Remove `ExtendSectorExpiration` method from the miner actor.
70+
- Ensure that tests for `ExtendSectorExpiration2` effectively cover the same functionality.
71+
- Ensure that removal of tests previously covering `ExtendSectorExpiration` doesn't result in an overall reduction in test coverage.
72+
- Ensure all systems behave normally with the removal of `ExtendSectorExpiration`.
73+
74+
## Copyright
75+
76+
Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,3 +137,5 @@ This improvement protocol helps achieve that objective for all members of the Fi
137137
| [0099](https://github.com/filecoin-project/FIPs/blob/master/FRCs/frc-0099.md) | Delegation of Authority for F3 Parameter Setting | FRC | @Kubuxu @BigLep | Accepted |
138138
| [0100](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0100.md) | Removing Batch Balancer, Replacing It With a Per-sector Fee and Removing Gas-limited Constraints | FIP | irene (@irenegia), AX (@AxCortesCubero), rvagg (@rvagg), molly (@momack2), kiran (@kkarrancsu)| Accepted |
139139
| [0101](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0101.md) | Removal of the ProveCommitAggregate method from the miner actor | FIP | Rod Vagg (@rvagg) | Accepted |
140+
(@rvagg) | Draft |
141+
| [0103](https://github.com/filecoin-project/FIPs/blob/master/FIPS/fip-0103.md) | Removal of the ExtendSectorExpiration method from the miner actor | FIP | Rod Vagg (@rvagg) | Draft |

0 commit comments

Comments
 (0)