feat: attribute typing #40
Merged
0xmuralik
merged 24 commits from 2022-11-15 06:21:14 +00:00
murali/attribute-typing into main
Dismiss Review
Are you sure you want to dismiss this review?
Labels
Clear labels
C:CLI
C:Crypto
C:Encoding
C:Proto
C:Types
Status: Stale
Type: ADR
Type: Build
Type: CI
Type: Docs
Type: Tests
bug
dependencies
docker
documentation
duplicate
enhancement
go
good first issue
help wanted
high priority
in progress
invalid
javascript
low priority
medium priority
question
urgent
wontfix
Copied from Github
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Something isn't working
Pull requests that update a dependency file
Pull requests that update Docker code
Improvements or additions to documentation
This issue or pull request already exists
New feature or request
Pull requests that update Go code
Good for newcomers
Extra attention is needed
currently working on
This doesn't seem right
Pull requests that update Javascript code
Further information is requested
Top priority issue
This will not be worked on
An issue or PR manually copied from GitHub.
Breaking change that won't be backward compatible
Something is not working
Documentation changes
Improve existing functionality
New functionality
This is security issue
Issue or pull request related to testing
Priority
Critical
The priority is critical
Priority
High
The priority is high
Priority
Low
The priority is low
Priority
Medium
The priority is medium
Reviewed
Confirmed
Issue has been confirmed
Reviewed
Duplicate
This issue or pull request already exists
Reviewed
Invalid
Invalid issue
Reviewed
Won't Fix
This issue won't be fixed
Status
Abandoned
Somebody has started to work on this but abandoned work
Status
Blocked
Something is blocking this issue or pull request
Status
Need More Info
Feedback is required to reproduce issue or to continue work
Milestone
No items
No Milestone
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: cerc-io/laconicd-deprecated#40
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Fixes part of: #27
Description
For contributor use:
docs/) or specification (x/<module>/spec/)godoccomments.Unreleasedsection inCHANGELOG.mdFiles changedin the Github PR explorerFor admin use:
WIP,R4R,docs, etc)@@ -233,1 +289,3 @@k.InsertRecordExpiryQueue(ctx, record.ToRecordObj())recordObj, err := record.ToRecordObj()if err != nil {return errthe value in the range statement should be _ unless copying a map: want: for key := range m
the value in the range statement should be _ unless copying a map: want: for key := range m
Show more details
the value in the range statement should be _ unless copying a map: want: for key := range m
expected exactly 1 statement (either append, delete, or copying to another map) in a range with a map, got 2
Show more details
the value in the range statement should be _ unless copying a map: want: for key := range m
expected exactly 1 statement (either append, delete, or copying to another map) in a range with a map, got 2
Show more details
@@ -233,1 +289,3 @@k.InsertRecordExpiryQueue(ctx, record.ToRecordObj())recordObj, err := record.ToRecordObj()if err != nil {return errgot *ast.IfStmt; expected exactly 1 statement (either append or delete) in a range with a map
got *ast.IfStmt; expected exactly 1 statement (either append or delete) in a range with a map
Show more details
got *ast.IfStmt; expected exactly 1 statement (either append or delete) in a range with a map
expected exactly 1 statement (either append, delete, or copying to another map) in a range with a map, got 2
Show more details
Codecov Report
Additional details and impacted files
0.00% <0.00%> (ø)0.80% <0.00%> (ø)54.54% <11.11%> (-6.86%)52.77% <40.00%> (+29.59%)48.64% <45.11%> (+3.15%)93.75% <100.00%> (ø)97.96% <100.00%> (ø)100.00% <100.00%> (ø)100.00% <100.00%> (ø)96.21% <100.00%> (ø)LGTM just a couple minor questions/comments. Thanks!
@@ -151,1 +148,4 @@# signingKey: "${{ secrets.CACHIX_SIGNING_KEY }}"# - name: 'instantiate integration test env'# run: nix-store -r $(nix-instantiate tests/integration_tests/shell.nix)Do these tests need to be commented out?
Let's add a small comment above like the other prefixes e.g. "PrefixAttributesIndex is the prefix for the nameservice Record.Attributes -> Record.ID index".
@@ -41,3 +41,3 @@sdk.NewAttribute(types.AttributeKeyBondID, msg.GetBondId()),sdk.NewAttribute(types.AttributeKeyPayload, msg.Payload.String()),sdk.NewAttribute(types.AttributeKeyPayload, msg.Payload.Record.Id),),I like this change, seems better to emit only the ID, but want to double-check with Ashwin as to whether or not there was any reason to encode the entire payload into a tendermint event. Was there a specific motivation for this change?
@@ -41,3 +41,3 @@sdk.NewAttribute(types.AttributeKeyBondID, msg.GetBondId()),sdk.NewAttribute(types.AttributeKeyPayload, msg.Payload.String()),sdk.NewAttribute(types.AttributeKeyPayload, msg.Payload.Record.Id),),Now that the attributes are of type codectypes.Any, We cant unmarshal PayLoad to a string type. There can be a workaround to convert it to the specific Payload type based on attribute type, If that's necessary.
@@ -151,1 +148,4 @@# signingKey: "${{ secrets.CACHIX_SIGNING_KEY }}"# - name: 'instantiate integration test env'# run: nix-store -r $(nix-instantiate tests/integration_tests/shell.nix)The upload-cache test needs the
integration testwhich has an issue with nixOS because of the added gql dependency as stated in a previous PR.Commented out the upload-cache test as all the tests in test.yml file were being ignored because of this dependency error.