Merge pull request #10439 from filecoin-project/jen/v1203

fix: cherrypick/conflict wrongfully resolved
This commit is contained in:
Jiaying Wang 2023-03-09 22:58:36 -05:00 committed by GitHub
commit b332db0a38
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
10 changed files with 10 additions and 5 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -37,7 +37,7 @@ func BuildTypeString() string {
}
// BuildVersion is the local build version
const BuildVersion = "1.20.2"
const BuildVersion = "1.20.3"
func UserVersion() string {
if os.Getenv("LOTUS_VERSION_IGNORE_COMMIT") == "1" {

View File

@ -7,7 +7,7 @@ USAGE:
lotus-miner [global options] command [command options] [arguments...]
VERSION:
1.20.2
1.20.3
COMMANDS:
init Initialize a lotus miner repo

View File

@ -7,7 +7,7 @@ USAGE:
lotus-worker [global options] command [command options] [arguments...]
VERSION:
1.20.2
1.20.3
COMMANDS:
run Start lotus worker

View File

@ -7,7 +7,7 @@ USAGE:
lotus [global options] command [command options] [arguments...]
VERSION:
1.20.2
1.20.3
COMMANDS:
daemon Start a lotus daemon process

2
go.mod
View File

@ -4,6 +4,8 @@ go 1.18
retract v1.14.0 // Accidentally force-pushed tag, use v1.14.1+ instead.
retract v1.20.2 // Wrongfully cherry picked PR, use v1.20.2+ instead.
require (
contrib.go.opencensus.io/exporter/prometheus v0.4.0
github.com/BurntSushi/toml v1.1.0

View File

@ -254,7 +254,10 @@ func (a *EthModule) parseBlkParam(ctx context.Context, blkParam string, strict b
if err != nil {
return nil, fmt.Errorf("cannot parse block number: %v", err)
}
ts, err := a.Chain.GetTipsetByHeight(ctx, abi.ChainEpoch(num), nil, true)
if abi.ChainEpoch(num) > head.Height()-1 {
return nil, fmt.Errorf("requested a future epoch (beyond 'latest')")
}
ts, err := a.ChainAPI.ChainGetTipSetByHeight(ctx, abi.ChainEpoch(num), head.Key())
if err != nil {
return nil, fmt.Errorf("cannot get tipset at height: %v", num)
}