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

update for algorand/go-algorand#5757 and algorand/go-algorand-sdk#617 #1605

Closed
wants to merge 6 commits into from
Closed
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 20 additions & 8 deletions idb/postgres/internal/encoding/encoding.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,13 +94,17 @@
func convertBlockHeader(header sdk.BlockHeader) blockHeader {
return blockHeader{
BlockHeader: header,
ProposerOverride: AlgodEncodedAddress(header.Proposer),

Check failure on line 97 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L97

header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:97:68: header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)

Check failure on line 97 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L97

header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:97:68: header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)

Check failure on line 97 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L97

header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:97:68: header.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
ExpiredParticipationAccountsOverride: convertExpiredAccounts(header.ExpiredParticipationAccounts),
AbsentParticipationAccountsOverride: convertExpiredAccounts(header.AbsentParticipationAccounts),

Check failure on line 99 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L99

header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:99:71: header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)

Check failure on line 99 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L99

header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:99:71: header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)

Check failure on line 99 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L99

header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:99:71: header.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
}
}

func unconvertBlockHeader(header blockHeader) sdk.BlockHeader {
res := header.BlockHeader
res.Proposer = sdk.Address(header.ProposerOverride)

Check failure on line 105 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L105

res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:105:6: res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)

Check failure on line 105 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L105

res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:105:6: res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)

Check failure on line 105 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L105

res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
Raw output
idb/postgres/internal/encoding/encoding.go:105:6: res.Proposer undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method Proposer)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
res.ExpiredParticipationAccounts = unconvertExpiredAccounts(header.ExpiredParticipationAccountsOverride)
res.AbsentParticipationAccounts = unconvertExpiredAccounts(header.AbsentParticipationAccountsOverride)

Check failure on line 107 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L107

res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:107:6: res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)

Check failure on line 107 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L107

res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:107:6: res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)

Check failure on line 107 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L107

res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
Raw output
idb/postgres/internal/encoding/encoding.go:107:6: res.AbsentParticipationAccounts undefined (type "github.com/algorand/go-algorand-sdk/v2/types".BlockHeader has no field or method AbsentParticipationAccounts)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
return res
}

Expand Down Expand Up @@ -359,6 +363,7 @@
RewardsBase: ad.RewardsBase,
RewardedMicroAlgos: sdk.MicroAlgos(ad.RewardedMicroAlgos),
AuthAddr: ad.AuthAddr,
IncentiveEligible: ad.IncentiveEligible,

Check failure on line 366 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L366

unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:366:4: unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 366 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L366

unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:366:4: unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 366 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L366

unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:366:4: unknown field IncentiveEligible in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
TotalAppSchema: ad.TotalAppSchema,
TotalExtraAppPages: ad.TotalExtraAppPages,
TotalAppParams: ad.TotalAppParams,
Expand All @@ -367,6 +372,8 @@
TotalAssets: ad.TotalAssets,
TotalBoxes: ad.TotalBoxes,
TotalBoxBytes: ad.TotalBoxBytes,
LastProposed: ad.LastProposed,

Check failure on line 375 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L375

unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:375:4: unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 375 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L375

unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:375:4: unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 375 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L375

unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:375:4: unknown field LastProposed in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
LastHeartbeat: ad.LastHeartbeat,

Check failure on line 376 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L376

unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:376:4: unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 376 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L376

unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:376:4: unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData

Check failure on line 376 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L376

unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
Raw output
idb/postgres/internal/encoding/encoding.go:376:4: unknown field LastHeartbeat in struct literal of type "github.com/algorand/go-algorand-sdk/v2/types".AccountBaseData
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
},
VotingData: sdk.VotingData{
VoteID: ad.VoteID,
Expand Down Expand Up @@ -648,6 +655,7 @@
return baseAccountData{
Status: ad.Status,
AuthAddr: ad.AuthAddr,
IncentiveEligible: ad.IncentiveEligible,

Check failure on line 658 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L658

ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)
Raw output
idb/postgres/internal/encoding/encoding.go:658:27: ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)

Check failure on line 658 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L658

ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)
Raw output
idb/postgres/internal/encoding/encoding.go:658:27: ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)

Check failure on line 658 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L658

ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)
Raw output
idb/postgres/internal/encoding/encoding.go:658:27: ad.IncentiveEligible undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method IncentiveEligible)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
TotalAppSchema: ad.TotalAppSchema,
TotalExtraAppPages: ad.TotalExtraAppPages,
TotalAssetParams: ad.TotalAssetParams,
Expand All @@ -656,14 +664,15 @@
TotalAppLocalStates: ad.TotalAppLocalStates,
TotalBoxes: ad.TotalBoxes,
TotalBoxBytes: ad.TotalBoxBytes,
baseOnlineAccountData: baseOnlineAccountData{
VoteID: ad.VoteID,
SelectionID: ad.SelectionID,
StateProofID: ad.StateProofID,
VoteFirstValid: ad.VoteFirstValid,
VoteLastValid: ad.VoteLastValid,
VoteKeyDilution: ad.VoteKeyDilution,
},
LastProposed: ad.LastProposed,

Check failure on line 667 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L667

ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)
Raw output
idb/postgres/internal/encoding/encoding.go:667:27: ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)

Check failure on line 667 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L667

ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)
Raw output
idb/postgres/internal/encoding/encoding.go:667:27: ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)

Check failure on line 667 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L667

ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)
Raw output
idb/postgres/internal/encoding/encoding.go:667:27: ad.LastProposed undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastProposed)
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
LastHeartbeat: ad.LastHeartbeat,

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

too many errors) (typecheck)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: too many errors) (typecheck)
	"github.com/algorand/indexer/v3/idb/postgres/internal/encoding"
	^

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

too many errors) (typecheck)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: too many errors) (typecheck)
	"github.com/algorand/indexer/v3/idb/postgres/internal/encoding"
	^

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: ad.LastHeartbeat undefined (type "github.com/algorand/go-algorand-sdk/v2/types".AccountData has no field or method LastHeartbeat)

Check failure on line 668 in idb/postgres/internal/encoding/encoding.go

View workflow job for this annotation

GitHub Actions / Lint Warnings

[Lint Warnings] idb/postgres/internal/encoding/encoding.go#L668

too many errors) (typecheck)
Raw output
idb/postgres/internal/encoding/encoding.go:668:27: too many errors) (typecheck)
	"github.com/algorand/indexer/v3/idb/postgres/internal/encoding"
	^
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved
jannotti marked this conversation as resolved.
Show resolved Hide resolved

VoteID: ad.VoteID,
SelectionID: ad.SelectionID,
StateProofID: ad.StateProofID,
VoteFirstValid: ad.VoteFirstValid,
VoteLastValid: ad.VoteLastValid,
VoteKeyDilution: ad.VoteKeyDilution,
}
}

Expand All @@ -672,6 +681,7 @@
AccountBaseData: sdk.AccountBaseData{
Status: ba.Status,
AuthAddr: ba.AuthAddr,
IncentiveEligible: ba.IncentiveEligible,
TotalAppSchema: ba.TotalAppSchema,
TotalExtraAppPages: ba.TotalExtraAppPages,
TotalAppParams: ba.TotalAppParams,
Expand All @@ -680,6 +690,8 @@
TotalAssets: ba.TotalAssets,
TotalBoxes: ba.TotalBoxes,
TotalBoxBytes: ba.TotalBoxBytes,
LastProposed: ba.LastProposed,
LastHeartbeat: ba.LastHeartbeat,
},
VotingData: sdk.VotingData{
VoteID: ba.VoteID,
Expand Down
26 changes: 14 additions & 12 deletions idb/postgres/internal/encoding/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@ type AlgodEncodedAddress sdk.Address

type blockHeader struct {
sdk.BlockHeader
// these "override" fields are used to encode these arrays of addresses as
// human-readable strings, instead of base64.
ProposerOverride AlgodEncodedAddress `codec:"prp"`
ExpiredParticipationAccountsOverride []AlgodEncodedAddress `codec:"partupdrmv"`
AbsentParticipationAccountsOverride []AlgodEncodedAddress `codec:"partupdabs"`
}

type assetParams struct {
Expand Down Expand Up @@ -87,22 +91,12 @@ type appParams struct {
GlobalStateOverride tealKeyValue `codec:"gs"`
}

type baseOnlineAccountData struct {
_struct struct{} `codec:",omitempty,omitemptyarray"`

VoteID sdk.OneTimeSignatureVerifier `codec:"vote"`
SelectionID sdk.VRFVerifier `codec:"sel"`
StateProofID sdk.Commitment `codec:"stprf"`
VoteFirstValid sdk.Round `codec:"voteFst"`
VoteLastValid sdk.Round `codec:"voteLst"`
VoteKeyDilution uint64 `codec:"voteKD"`
}

type baseAccountData struct {
_struct struct{} `codec:",omitempty,omitemptyarray"`

Status sdk.Status `codec:"onl"`
AuthAddr sdk.Address `codec:"spend"`
IncentiveEligible bool `codec:"ie"`
TotalAppSchema sdk.StateSchema `codec:"tsch"`
TotalExtraAppPages uint32 `codec:"teap"`
TotalAssetParams uint64 `codec:"tasp"`
Expand All @@ -112,5 +106,13 @@ type baseAccountData struct {
TotalBoxes uint64 `codec:"tbx"`
TotalBoxBytes uint64 `codec:"tbxb"`

baseOnlineAccountData
LastProposed sdk.Round `codec:"lpr"`
LastHeartbeat sdk.Round `codec:"lhb"`

VoteID sdk.OneTimeSignatureVerifier `codec:"vote"`
SelectionID sdk.VRFVerifier `codec:"sel"`
StateProofID sdk.Commitment `codec:"stprf"`
VoteFirstValid sdk.Round `codec:"voteFst"`
VoteLastValid sdk.Round `codec:"voteLst"`
VoteKeyDilution uint64 `codec:"voteKD"`
}
Loading