Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
7 changes: 7 additions & 0 deletions cmd/gouroboros/query.go
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,13 @@ func testQuery(f *globalFlags) {
}
}
}
case "proposed-protocol-params-updates":
proposedUpdates, err := o.LocalStateQuery().Client.GetProposedProtocolParamsUpdates()
if err != nil {
fmt.Printf("ERROR: failure querying proposed protocol params updates: %s\n", err)
os.Exit(1)
}
fmt.Printf("proposed-protocol-params-updates: %v\n", *proposedUpdates)
default:
fmt.Printf("ERROR: unknown query: %s\n", queryFlags.flagset.Args()[0])
os.Exit(1)
Expand Down
3 changes: 3 additions & 0 deletions ledger/common/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,9 @@ func Blake2b224Hash(data []byte) Blake2b224 {
return Blake2b224(tmpHash.Sum(nil))
}

// GenesisHash is a type alias for the Blake2b-224 hash used for genesis keys
type GenesisHash = Blake2b224

type Blake2b160 [Blake2b160Size]byte

func NewBlake2b160(data []byte) Blake2b160 {
Expand Down
4 changes: 2 additions & 2 deletions protocol/localstatequery/queries.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import (

"github.com/blinklabs-io/gouroboros/cbor"
"github.com/blinklabs-io/gouroboros/ledger"
"github.com/blinklabs-io/gouroboros/ledger/common"
)

// Query types
Expand Down Expand Up @@ -521,8 +522,7 @@ type CurrentProtocolParamsResult interface {
any
}

// TODO (#861)
type ProposedProtocolParamsUpdatesResult any
type ProposedProtocolParamsUpdatesResult map[common.GenesisHash]common.ProtocolParameterUpdate

type StakeDistributionResult struct {
cbor.StructAsArray
Expand Down
Loading