-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Add supported / unsupported version for fork enum #16030
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
Conversation
59c068b to
02b142a
Compare
|
|
I'd rather see the language of "Unsupported" where a list of forks that are not fully supported are removed from |
runtime/version/fork.go
Outdated
| // enabled on any supported network. These versions are removed from All(). | ||
| var unsupportedVersions = []int{Gloas} | ||
|
|
||
| var unsupportedVersionSet = map[int]struct{}{} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can get rid of the list and declare the keys directly in the map:
var unsupportedVersions = map[int]struct{}{
Gloas: struct{}{}
}
Deletes this whole chunk of init code:
unsupportedVersionSet = make(map[int]struct{}, len(unsupportedVersions))
for _, v := range unsupportedVersions {
unsupportedVersionSet[v] = struct{}{}
}
sort.Ints(unsupportedVersions)
I think you can also drop the Unsupported func.
This PR introduces unsupported versions (currently only Gloas), and tightened
version.All()to hide those entries, and addedversion.IsUnsupported(). Tests were updated to enumerate and assert they never show up in All() or any testnet schedule.