Improve the developer experience for blockchain developers.
Origin Document
I encountered a handful of problems going through #359, ranging from bugs, issues and institutional knowledge that we have to capture and iterate on.
Goals
Reduce friction to onboard new developers
Share knowledge on tips & tricks for day-to-day tooling
Remove hidden expected undefined behaviour such as I know this doesn't work that others might not be aware of
Build small tools or add small pieces of documentation that can greatly make everyone more effective
Deliverables
[ ] [E2E Testing] Make it easier to run a single E2E test. Formulating the following CLI command is non-trivial and there is an opportunity to have a make helper to just put in a fuzzy matched name
go test -v -tags=test,e2e -count=1 -run \
TestFeatures/Tokenomics_Namespaces/Basic_tokenomics_validation_that_Supplier_mint_equals_Application_burn \
./e2e/tests/...
[ ] [Tooling] Make it easier to run any poktrolld command w/ default flags during development. Formulating the following CLI command is non-trivial and there is an opportunity to have a make helper to just put in a fuzzy matched name.
[x] [Infra] Make it easier to maintain state across LocalNet restarts. Currently, every time we click Trigger Update, the blockchain restarts from height=1
[x] [Infra] Enable hot reloading. This is not in place today unless we click Trigger Update explicitly.
[x] [Infra] Document the order of operations if the Sequencer is restarted. Specifically, relayminers and appgateservers need to have Trigger Update clicked AFTER the sequencer is back up for things to function normally
[ ] [Logging] Document how on-chain logging should be done as a best practice. For example
The default cosmos-sdk logger is not very practical when used at the "debug" level as it's overwhelmed with cosmos-sdk specific output.
We should prefer using the "debug" level for any log that doesn't require node operator attention (e.g. handling invalid requests). I think this represents (or it should) the majority of logger calls.
Search each module for usages of logger.Info() and logger.Error(). Places where an error is logged and returned are prime examples of mis-leveled logs.
[x] [Debugging] Make it easier to sift through logs. Specifically:
[ ] Document how to filter them
[ ] Understand how to parse the JSON from logger
[ ] Understand how to parse the stack trace from on-chain code
[ ] Understand why sequencer showed no errors even through the relayminer show a panic tx timeout
Objective
Improve the developer experience for blockchain developers.
Origin Document
I encountered a handful of problems going through #359, ranging from bugs, issues and institutional knowledge that we have to capture and iterate on.
Goals
hidden expected undefined
behaviour such asI know this doesn't work
that others might not be aware ofDeliverables
[ ]
[E2E Testing]
Make it easier to run a single E2E test. Formulating the following CLI command is non-trivial and there is an opportunity to have amake
helper to just put in a fuzzy matched name[ ]
[Tooling
] Make it easier to run anypoktrolld
command w/ default flags during development. Formulating the following CLI command is non-trivial and there is an opportunity to have amake
helper to just put in a fuzzy matched name.[x]
[Infra]
Make it easier to maintain state across LocalNet restarts. Currently, every time we clickTrigger Update
, the blockchain restarts fromheight=1
[x]
[Infra]
Enable hot reloading. This is not in place today unless we clickTrigger Update
explicitly.[x]
[Infra]
Document the order of operations if theSequencer
is restarted. Specifically,relayminers
andappgateservers
need to haveTrigger Update
clicked AFTER thesequencer
is back up for things to function normally[ ]
[Logging]
Document howon-chain
logging should be done as a best practice. For exampleConsider which logger should be used:
Search each module for usages of
logger.Info()
andlogger.Error()
. Places where an error is logged and returned are prime examples of mis-leveled logs.[x]
[Debugging]
Make it easier to sift through logs. Specifically:JSON
fromlogger
stack trace
from on-chain codesequencer
showed no errors even through therelayminer
show apanic tx timeout
Non-goals / Non-deliverables
General deliverables
Creator: @Olshansk Co-Owners: @red-0ne @okdas