Skip to content

Commit

Permalink
Support periodic testnets (#955)
Browse files Browse the repository at this point in the history
  • Loading branch information
aopoltorzhicky authored Dec 28, 2022
1 parent 9ce292a commit 975ab92
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 0 deletions.
1 change: 1 addition & 0 deletions internal/bcd/protocols.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ var symLinks = map[string]string{
"PtHangz2aRngywmSRGGvrcTyMbbdpWdpFKuS4uMWxg2RaH9i1qx": SymLinkBabylon, // Hangzhounet 2
"PsiThaCaT47Zboaw71QWScM8sXeMM7bbQFncK9FLqYc6EKdpjVP": SymLinkBabylon, // Itacanet
"Psithaca2MLRFYargivpo7YvUr7wUDqyxrdhC5CQq78mRvimz6A": SymLinkBabylon, // Itacanet 2
"ProtoALphaALphaALphaALphaALphaALphaALphaALphaDdp3zK": SymLinkJakarta, // Monday and daily
"PtJakart2xVj7pYXJBXrqHgd82rdkLey5ZeeGwDgPp9rhQUbSqY": SymLinkJakarta, // Jakarta
"PtKathmankSpLLDALzWw7CGD2j2MtyveTwboEYokqUCP4a1LxMg": SymLinkJakarta, // Kathmandu
"PtLimaPtLMwfNinJi9rCfDPWea8dFgTZ1MeJ9f1m2SRic6ayiwW": SymLinkJakarta, // Lima
Expand Down
6 changes: 6 additions & 0 deletions internal/models/types/network.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ const (
Ghostnet
Kathmandunet
Limanet
Mondaynet
Dailynet
)

var networkNames = map[Network]string{
Expand All @@ -43,6 +45,8 @@ var networkNames = map[Network]string{
Ghostnet: "ghostnet",
Kathmandunet: "kathmandunet",
Limanet: "limanet",
Mondaynet: "mondaynet",
Dailynet: "dailynet",
}

var namesToNetwork = map[string]Network{
Expand All @@ -60,6 +64,8 @@ var namesToNetwork = map[string]Network{
"ghostnet": Ghostnet,
"kathmandunet": Kathmandunet,
"limanet": Limanet,
"mondaynet": Mondaynet,
"dailynet": Dailynet,
}

// String - convert enum to string for printing
Expand Down
2 changes: 2 additions & 0 deletions internal/parsers/operations/migration.go
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ func (m Migration) Parse(data noderpc.Operation, operation *operation.Operation,
"PtEdo2ZkT9oKpimTah6x2embF25oss54njMuPzkJTEi5RqfdZFA":
return m.fromBigMapDiffs(data, operation, store)
case
"ProtoALphaALphaALphaALphaALphaALphaALphaALphaDdp3zK",
"PtHangz2aRngywmSRGGvrcTyMbbdpWdpFKuS4uMWxg2RaH9i1qx",
"PtHangzHogokSuiMHemCuowEavgYTP8J5qQ9fQS793MHYFpCY3r",
"PsiThaCaT47Zboaw71QWScM8sXeMM7bbQFncK9FLqYc6EKdpjVP",
Expand All @@ -56,6 +57,7 @@ func (m Migration) Parse(data noderpc.Operation, operation *operation.Operation,
"PtJakart2xVj7pYXJBXrqHgd82rdkLey5ZeeGwDgPp9rhQUbSqY",
"PtKathmankSpLLDALzWw7CGD2j2MtyveTwboEYokqUCP4a1LxMg",
"PtLimaPtLMwfNinJi9rCfDPWea8dFgTZ1MeJ9f1m2SRic6ayiwW":

return m.fromLazyStorageDiff(data, operation, store)
default:
return errors.Errorf("unknown protocol for migration parser: %s", protocol)
Expand Down
2 changes: 2 additions & 0 deletions internal/parsers/protocols/protocol.go
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ func Get(ctx *config.Context, protocol string) (*Specific, error) {
}, nil
case "PtJakart2xVj7pYXJBXrqHgd82rdkLey5ZeeGwDgPp9rhQUbSqY",
"PtKathmankSpLLDALzWw7CGD2j2MtyveTwboEYokqUCP4a1LxMg",
"ProtoALphaALphaALphaALphaALphaALphaALphaALphaDdp3zK",
"PtLimaPtLMwfNinJi9rCfDPWea8dFgTZ1MeJ9f1m2SRic6ayiwW":
return &Specific{
StorageParser: storage.NewLazyBabylon(ctx.BigMapDiffs, ctx.Operations, ctx.Accounts),
Expand Down Expand Up @@ -121,6 +122,7 @@ func NeedImplicitParsing(protocol string) bool {
"Psithaca2MLRFYargivpo7YvUr7wUDqyxrdhC5CQq78mRvimz6A",
"PtJakart2xVj7pYXJBXrqHgd82rdkLey5ZeeGwDgPp9rhQUbSqY",
"PtKathmankSpLLDALzWw7CGD2j2MtyveTwboEYokqUCP4a1LxMg",
"ProtoALphaALphaALphaALphaALphaALphaALphaALphaDdp3zK",
"PtLimaPtLMwfNinJi9rCfDPWea8dFgTZ1MeJ9f1m2SRic6ayiwW":
return true
}
Expand Down

0 comments on commit 975ab92

Please sign in to comment.