Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/feat/gmrr' into feat/no-overserv…
Browse files Browse the repository at this point in the history
…icing
  • Loading branch information
red-0ne committed Oct 30, 2024
2 parents 6170a45 + 2bd7240 commit 4c65e84
Show file tree
Hide file tree
Showing 85 changed files with 158 additions and 161 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/label-actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ jobs:
action:
runs-on: ubuntu-latest
steps:
# TODO: switch to `dessant/label-actions@v3` when https://github.com/dessant/label-actions/pull/29 is merged.
# TODO_TECHDEBT: switch to `dessant/label-actions@v3` when https://github.com/dessant/label-actions/pull/29 is merged.
- uses: okdas/label-actions@patch-1
1 change: 0 additions & 1 deletion Tiltfile
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ localnet_config_defaults = {
"count": 1,
"delve": {"enabled": False},
},
# TODO_BLOCKER(@red-0ne, #511): Add support for `REST` and enabled this.
"ollama": {
"enabled": False,
"model": "qwen:0.5b",
Expand Down
2 changes: 1 addition & 1 deletion app/upgrades/historical.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ package upgrades
// separate file, and then move them to `historical.go` after a successful upgrade so the new nodes can still sync from
// the genesis.

// TODO_CONSIDERATION: after we verify `State Sync` is fully functional, we can hypothetically remove old upgrades from
// TODO_TECHDEBT(@okdas): after we verify `State Sync` is fully functional, we can hypothetically remove old upgrades from
// the codebase, as the nodes won't have to execute upgrades and will download the "snapshot" instead. Some other
// blockchain networks do that (such as `evmos`: https://github.com/evmos/evmos/tree/main/app/upgrades).
// Note that this may inhibit a full state sync from genesis.
Expand Down
2 changes: 1 addition & 1 deletion app/volatile/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
// re-organized or removed in future work.
package volatile

// TODO_CLEANUP: Find a way to centralize the use of `upokt` throughout the codebase
// TODO_TECHDEBT: Find a way to centralize the use of `upokt` throughout the codebase
const DenomuPOKT = "upokt"
8 changes: 4 additions & 4 deletions config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ validators:
app:
# DEV_NOTE: Ignite does not carry over all defaults, so we are going to match `minimum-gas-prices` with `cmd/config.go`.
# See the enhancement request here: https://github.com/ignite/cli/issues/4340
# TODO(#794): turn on `minimum-gas-prices` back
# TODO_MAINNET(#794): turn on `minimum-gas-prices` back
# minimum-gas-prices: 0.000000001upokt
telemetry:
enabled: true
Expand Down Expand Up @@ -124,7 +124,7 @@ genesis:
staking:
params:
bond_denom: upokt
# TODO_MAINNET(@Olshansk): Figure out what this should be on Shannon
# TODO_MAINNET: Figure out what this should be on Shannon
# re-genesis. We're setting it to 1 for Alpha TestNet #1 so Grove
# maintains the only validator until Alpha TestNet #2.
max_validators: 1
Expand Down Expand Up @@ -235,8 +235,8 @@ genesis:
params:
# TODO_MAINNET: Determine realistic amount for minimum gateway stake amount.
min_stake:
amount: "1000000" # 1 POKT
denom: upokt
amount: "1000000" # 1 POKT
denom: upokt
gatewayList:
- address: pokt15vzxjqklzjtlz7lahe8z2dfe9nm5vxwwmscne4
stake:
Expand Down
2 changes: 1 addition & 1 deletion docusaurus/docs/develop/contributing/observability.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ func (k msgServer) CreateClaim(...) (_ *types.MsgCreateClaimResponse, err error)
### Histogram
TODO: Add a code example, link to usage, and screenshot of the output.
TODO_DOCUMENT: Add a code example, link to usage, and screenshot of the output.
## Logs
Expand Down
16 changes: 8 additions & 8 deletions docusaurus/docs/develop/developer_guide/debug_tips.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@ If you have a tip you'd like to share with others, please open a PR to add it he
- [`itest` - Investigating Flaky Tests](#itest---investigating-flaky-tests)
- [`itest` Usage](#itest-usage)
- [`itest` Example](#itest-example)
- [TODO: pprof](#todo-pprof)
- [TODO: dlv](#todo-dlv)
- [`poktrolld query tx` - Investigating Failed Transactions](#poktrolld-query-tx---investigating-failed-transactions)
- [`poktrolld query tx` Example](#poktrolld-query-tx-example)

- [TODO_DOCUMENT: pprof](#todo_document-pprof)
- [TODO_DOCUMENT: dlv](#todo_document-dlv)

## `itest` - Investigating Flaky Tests

We developed a tool called `itest` to help with debugging flaky tests. It runs
Expand All @@ -43,11 +43,11 @@ make itest 5 10 ./pkg/client/tx/... -- -run TxClient_SignAndBroadcast_Succeeds

## `poktrolld query tx` - Investigating Failed Transactions

_tl;dr Submitted Transaction != Committed Transaction_
_tl;dr Submitted Transaction != Committed Transaction_

After a transaction (e.g. staking a new service) is successfully sent to an RPC node, we have to wait
until the next block, when a proposer will try to commit to the network's state, to see if its valid.
If the transaction's (TX) state transition is invalid, it will not be committed.
If the transaction's (TX) state transition is invalid, it will not be committed.

In other words, receiving a transaction (TX) hash from the `poktrolld` CLI doesn't mean it was committed.
However, the transaction (TX) hash can be used to investigate the failed transaction.
Expand Down Expand Up @@ -91,7 +91,7 @@ state transition.

:::note

If you are reading this and the `9E4CA...` hash is no longer valid, we may have done a re-genesis of
If you are reading this and the `9E4CA...` hash is no longer valid, we may have done a re-genesis of
TestNet at this point. Please consider updating with a new one!

:::
Expand All @@ -115,6 +115,6 @@ The above command will produce the following output:

:::

### TODO: pprof
### TODO_DOCUMENT: pprof

### TODO: dlv
### TODO_DOCUMENT: dlv
4 changes: 2 additions & 2 deletions docusaurus/docs/develop/packages/client_package.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,13 +118,13 @@ go get github.com/pokt-network/poktroll/pkg/client
### Basic Example

```go
// TODO: Code example showcasing the use of TxClient or any other primary interface.
// TODO_DOCUMENT: Code example showcasing the use of TxClient or any other primary interface.
```

### Advanced Usage

```go
// TODO: Example illustrating advanced features or edge cases of the package.
// TODO_DOCUMENT: Example illustrating advanced features or edge cases of the package.
```

### Configuration
Expand Down
4 changes: 2 additions & 2 deletions docusaurus/docs/explore/rpc.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ poktrolld query block --type=height 0 --node https://shannon-testnet-grove-seed-

### gRPC

_TODO: Add a gRPC example_
_TODO_TECHDEBT: Add a gRPC example_

### REST

_TODO: Add a REST example_
_TODO_TECHDEBT: Add a REST example_
4 changes: 1 addition & 3 deletions docusaurus/docs/operate/run_a_node/appgate_server.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,6 @@ Please see the [Hardware Requirements](./hardware_requirements.md#appgate-server
Please refer to the `Deploying an AppGate Server` section in [poktroll-docker-compose-example](https://github.com/pokt-network/poktroll-docker-compose-example#deploying-an-appgate-server)
GitHub repository on how to deploy an AppGate Server using `docker-compose`.

_TODO: Move over the relevant information from the `poktroll-docker-compose-example` repository into the docs_

## Kubernetes Example

_TODO: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
_TODO_DOCUMENT: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
3 changes: 1 addition & 2 deletions docusaurus/docs/operate/run_a_node/full_node_docker.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ In blockchain networks, a Full Node retains a complete copy of the ledger.
You can visit the [Cosmos SDK documentation](https://docs.cosmos.network/main/user/run-node/run-node)
for more information on Full Nodes.


## Roles & Responsibilities

It is usually responsible for:
Expand Down Expand Up @@ -62,4 +61,4 @@ on how to deploy a Full Node using `docker-compose`.

## Kubernetes Example

_TODO: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
_TODO_DOCUMENT: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
4 changes: 2 additions & 2 deletions docusaurus/docs/operate/run_a_node/relay_miner.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ Please see the [Hardware Requirements](./hardware_requirements.md#relayminer) pa
Please refer to the `Deploying a RelayMiner` section in [poktroll-docker-compose-example](https://github.com/pokt-network/poktroll-docker-compose-example#deploying-a-relay-miner)
GitHub repository on how to deploy an AppGate Server using `docker-compose`.

_TODO: Move over the relevant information from the `poktroll-docker-compose-example` repository into the docs_
_TODO_DOCUMENT: Move over the relevant information from the `poktroll-docker-compose-example` repository into the docs_

## Kubernetes Example

_TODO: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
_TODO_DOCUMENT: Provide an example using [strangelove-ventures/cosmos-operator](https://github.com/strangelove-ventures/cosmos-operator)._
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ deep cryptographic validations needed:

:::note

TODO: Link to tokenomics and data integrity checks for discussion once they are written.
TODO_DOCUMENT: Link to tokenomics and data integrity checks for discussion once they are written.

:::

Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/0_settlement.feature
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Feature: Tokenomics Namespace
# The application stake should be less 420 * (1 + glbal_inflation) = 420 * 1.1 = 462
And the "application" stake of "app1" should be "462" uPOKT "less" than before

# TODO_ADDTEST: Implement the following scenarios
# TODO_TEST: Implement the following scenarios
# Scenario: Supplier revenue shares are properly distributed
# Scenario: TLM Mint=Burn when a valid claim is outside Max Limits
# - Ensure over serviced event is submitted
Expand Down
2 changes: 1 addition & 1 deletion e2e/tests/session.feature
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Feature: Session Namespace
And the user should wait for the "proof" module "ProofSubmitted" tx event to be broadcast
Then the claim created by supplier "supplier1" for service "anvil" for application "app1" should be successfully settled

# TODO_BLOCKER(@red-0ne): Make sure to implement and validate this test
# TODO_MAINNET(@red-0ne): Make sure to implement and validate this test
# One way to exercise this behavior is to close the `RelayMiner` port to prevent
# the `RelayRequest` from being received and processed then reopen it after the
# the defined number of blocks has passed.
Expand Down
2 changes: 1 addition & 1 deletion localnet/kubernetes/anvil.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ spec:
labels:
app: anvil
spec:
# TODO: Add resource limits
# TODO_IMPROVE: Add resource limits
containers:
- name: anvil
image: ghcr.io/foundry-rs/foundry:nightly-3fa02706ca732c994715ba42d923605692062375
Expand Down
2 changes: 1 addition & 1 deletion pkg/appgateserver/config/appgate_configs_reader.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
)

// YAMLAppGateServerConfig is the structure used to unmarshal the AppGateServer config file
// TODO_BETA: Rename self_signing parameter to `sovereign` in code, configs
// TODO_BETA(@red-0ne): Rename self_signing parameter to `sovereign` in code, configs
// and documentation
type YAMLAppGateServerConfig struct {
ListeningEndpoint string `yaml:"listening_endpoint"`
Expand Down
4 changes: 2 additions & 2 deletions pkg/appgateserver/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,9 @@ func NewAppGateServer(
app.signingInformation.AppAddress = appAddress.String()
}

// TODO_CONSIDERATION: Use app.listeningEndpoint scheme to determine which
// TODO_IMPROVE: Use app.listeningEndpoint scheme to determine which
// kind of server to create (HTTP, HTTPS, TCP, UNIX, etc...)
// TODO_RESEARCH(#590): Currently, the communication between the AppGateServer and the
// TODO_IMPROVE(#590): Currently, the communication between the AppGateServer and the
// RelayMiner uses HTTP. This could be changed to a more generic and performant
// one, such as pure TCP.
app.server = &http.Server{Addr: app.listeningEndpoint.Host}
Expand Down
24 changes: 12 additions & 12 deletions pkg/client/query/sharedquerier.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,10 @@ func (sq *sharedQuerier) GetParams(ctx context.Context) (*sharedtypes.Params, er
// GetClaimWindowOpenHeight returns the block height at which the claim window of
// the session that includes queryHeight opens.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite,#543): We also don't really want to use the current value of the params. Instead,
// TODO_MAINNET(@bryanchriswhite,#543): We also don't really want to use the current value of the params. Instead,
// we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetClaimWindowOpenHeight(ctx context.Context, queryHeight int64) (int64, error) {
sharedParams, err := sq.GetParams(ctx)
Expand All @@ -76,10 +76,10 @@ func (sq *sharedQuerier) GetClaimWindowOpenHeight(ctx context.Context, queryHeig
// GetProofWindowOpenHeight returns the block height at which the proof window of
// the session that includes queryHeight opens.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite,#543): We also don't really want to use the current value of the params. Instead,
// TODO_MAINNET(@bryanchriswhite,#543): We also don't really want to use the current value of the params. Instead,
// we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetProofWindowOpenHeight(ctx context.Context, queryHeight int64) (int64, error) {
sharedParams, err := sq.GetParams(ctx)
Expand All @@ -94,10 +94,10 @@ func (sq *sharedQuerier) GetProofWindowOpenHeight(ctx context.Context, queryHeig
// The grace period is the number of blocks after the session ends during which relays
// SHOULD be included in the session which most recently ended.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// TODO_MAINNET(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// Instead, we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetSessionGracePeriodEndHeight(
ctx context.Context,
Expand All @@ -113,10 +113,10 @@ func (sq *sharedQuerier) GetSessionGracePeriodEndHeight(
// GetEarliestSupplierClaimCommitHeight returns the earliest block height at which a claim
// for the session that includes queryHeight can be committed for a given supplier.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// TODO_MAINNET(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// Instead, we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetEarliestSupplierClaimCommitHeight(ctx context.Context, queryHeight int64, supplierOperatorAddr string) (int64, error) {
sharedParams, err := sq.GetParams(ctx)
Expand Down Expand Up @@ -146,10 +146,10 @@ func (sq *sharedQuerier) GetEarliestSupplierClaimCommitHeight(ctx context.Contex
// GetEarliestSupplierProofCommitHeight returns the earliest block height at which a proof
// for the session that includes queryHeight can be committed for a given supplier.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// TODO_MAINNET(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// Instead, we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetEarliestSupplierProofCommitHeight(ctx context.Context, queryHeight int64, supplierOperatorAddr string) (int64, error) {
sharedParams, err := sq.GetParams(ctx)
Expand All @@ -175,10 +175,10 @@ func (sq *sharedQuerier) GetEarliestSupplierProofCommitHeight(ctx context.Contex

// GetComputeUnitsToTokensMultiplier returns the multiplier used to convert compute units to tokens.
//
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last()` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// TODO_MAINNET(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// Instead, we should be using the value that the params had for the session which includes queryHeight.
func (sq *sharedQuerier) GetComputeUnitsToTokensMultiplier(ctx context.Context) (uint64, error) {
sharedParams, err := sq.GetParams(ctx)
Expand Down
4 changes: 2 additions & 2 deletions pkg/crypto/rings/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -269,10 +269,10 @@ func (rc *ringClient) GetRingAddressesAtBlock(
app *apptypes.Application,
blockHeight int64,
) ([]string, error) {
// TODO_TECHDEBT(#543): We don't really want to have to query the params for every method call.
// TODO_MAINNET(#543): We don't really want to have to query the params for every method call.
// Once `ModuleParamsClient` is implemented, use its replay observable's `#Last` method
// to get the most recently (asynchronously) observed (and cached) value.
// TODO_BLOCKER(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// TODO_MAINNET(@bryanchriswhite, #543): We also don't really want to use the current value of the params.
// Instead, we should be using the value that the params had for the session given by blockHeight.
sharedParams, err := rc.sharedQuerier.GetParams(ctx)
if err != nil {
Expand Down
4 changes: 2 additions & 2 deletions pkg/polylog/interface.go
Original file line number Diff line number Diff line change
Expand Up @@ -133,15 +133,15 @@ type Event interface {
// To customize the key name, use the appropriate option from the respective
// package when constructing a logger.
//
// TODO_UPNEXT(@bryanchriswhite): ensure implementations' godoc examples cover
// TODO_POST_MAINNET(@bryanchriswhite): ensure implementations' godoc examples cover
// options.
Err(err error) Event

// Timestamp adds the current local time as UNIX timestamp to the Event context
// with the "time" key. To customize the key name, use the appropriate option
// from the respective package when constructing a Logger.
//
// TODO_UPNEXT(@bryanchriswhite): ensure implementations' godoc examples cover
// TODO_POST_MAINNET(@bryanchriswhite): ensure implementations' godoc examples cover
// options.
//
// NOTE: It won't dedupe the "time" key if the Event (or *Context) has one
Expand Down
2 changes: 1 addition & 1 deletion pkg/relayer/config/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ type RelayMinerServerType int

const (
RelayMinerServerTypeHTTP RelayMinerServerType = iota
// TODO: Support other RelayMinerServerType:
// TODO_FUTURE: Support other RelayMinerServerType:
// RelayMinerServerTypeHTTPS
// RelayMinerServerTypeTCP
// RelayMinerServerTypeUDP
Expand Down
Loading

0 comments on commit 4c65e84

Please sign in to comment.