* Fix liuqid notarization (#191)
* Fix liuqid notarization - 2nd part (#193)
* fixed missing unmarshaling
* fixed message formatting issue
* fixed config parsing issue (#194)
* [util] Supply fees
But only where we want to see the transaction succeed. The other ones we
let in a broken state.
* Added logger a logger struct to log with a TAG (#198)
Signed-off-by: Jürgen Eckel <juergen@riddleandcode.com>
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
Co-authored-by: Jürgen Eckel <eckelj@users.noreply.github.com>
* [lib] Refactor `getClientContextAndTxFactory()`
So that we can pass the account number and sequence number from
outside.
* [lib] Add `BroadcastTxWithFileLock()`
This implements "offline mode" via RPC, but instead of keeping track of
the sequence numbers, we write them into a file and lock them. This way, we can synchronize multiple processes using the same address, trying to
send transactions simultaneously.
// Closes https://github.com/rddl-network/issues/issues/46
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* [lib] Introduce variable for error
* [lib] Improve error handling in `broadcastTx()`
* Use `BroadcastTxWithFileLock()`
// See https://github.com/rddl-network/issues/issues/46
---------
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* [tests] Avoid potential data races
* Revert "[lib] Switch from RPC (REST) to gRPC (#183)"
This reverts commit db5f4fb3fe6899bcfdadf3471f826a6a97035440.
* [lib] DRY: Use build and broadcast tx from cosmos-sdk
This is in preparation for: https://github.com/rddl-network/issues/issues/46
Without this patch broadcasting a transaction in "offline mode" (setting
the sequence number manually) would not work consistently. Every so
often the endpoint would report back, that it got an unexpected sequence
number. Executing the request with the same sequence number couple of
seconds later would be successful.
I decided to better use the same source code, that the CLI uses, because
I know that offline mode works there.
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* [linter] Add `musttag`
Enforce field tags in (un)marshaled structs.
* [linter] Add `nestif`
Reports deeply nested if statements.
* [linter] Add `noctx`
Finds sending http request without context.Context.
* [linter] Add `paralleltest`
Paralleltest detects missing usage of t.Parallel() method in your Go
test.
* [linter] Add `tagalign`
Check that struct tags are well aligned.
* [linter] Add `tagliatelle`
Checks the struct tags.
* [linter] Add `whitespace`
Tool for detection of leading and trailing whitespace.
* [paralleltest] Exclude files bc of data race in tests
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* [linter] Remove unused exclusions
Linter `nosnakecase` was removed in 1e1138d0268a9896a1bd058e9b65b808eb20666e.
* [linter] Add tool for code clone detection
* [linter] Add `errorlint`
Find code that will cause problems with the error wrapping scheme
introduced in Go 1.13.
* [linter] Add `exhaustive`
Check exhaustiveness of enum switch statements.
* [linter] Add `forcetypeassert`
Finds type assertions which did forcely such as below:
```
func f() {
var a interface{}
_ = a.(int) // type assertion must be checked
}
```
* [linter] Add `gocritic`
Provides diagnostics that check for bugs, performance and style issues.
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* distributed & result msgs
* added DistributionResult
* added RDDL token conversion methods
* set proper validatoraddress within the testcases for e2e/dao
* set proper root dir for test cases
* fixed some wordings
---------
Signed-off-by: Jürgen Eckel <juergen@riddleandcode.com>
* add MintAddress to params.proto
* ignite scaffold message update-params params:Params --module dao
* add dao get and set params
* make dao.MsgUpdateParams.Params non-nullable
* use GetMintAddress in ante handler
* adjust dao e2e test suit for mint address param
* change msg creator to authority and set gov module as default in gov proposal
* fix staticcheck error
* remove depricated config param
* fix linter errors
Signed-off-by: Lorenz Herzberger <lorenzherzberger@gmail.com>
Golang uses:
- Camel Case for variable names, e.g. `firstName`
- Camel Case for private function names, e.g. `getFirstName`
- Pascal Case for public function names, e.g. `GetFirstName`
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
To align with cosmos-sdk and make interoperability easier.
* Fix typo: blockheight -> blockHeight
* Generate protobuf and openapi
Signed-off-by: Julian Strobl <jmastr@mailbox.org>
* hotfix: inconsistent logging of block-proposer results on the chain. These results need to be consensed via an explicit message instead of an error output.
Signed-off-by: Jürgen Eckel <juergen@riddleandcode.com>
When downloading the `vendor/` directory with:
```
$ go mod vendor
```
and then e.g. run `ignite chain init` this error happens:
* specify the path to your chain's main package in your
config.yml>build.main: multiple main packages found
Signed-off-by: Julian Strobl <jmastr@mailbox.org>