Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add group module proto definitions and basic types #9631

Merged
merged 8 commits into from
Jul 9, 2021

Conversation

blushi
Copy link
Contributor

@blushi blushi commented Jul 5, 2021

Description

ref: #7633

Following up on #9089, this PR is the first step towards the migration of x/group into the SDK. It introduces the group module proto definitions (types, tx, query) and other types.
The rest of the code (module, server, client, genesis...) is dependent on various other discussions (#9238, #9182, #9237, #7773) and will be added in follow-up PRs incrementally.


Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • included the correct type prefix in the PR title
  • added ! to the type prefix if API or client breaking change
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • followed the guidelines for building modules
  • included the necessary unit and integration tests
  • added a changelog entry to CHANGELOG.md
  • included comments for documenting Go code
  • updated the relevant documentation or specification
  • reviewed "Files changed" and left comments if necessary
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed ! in the type prefix if API or client breaking change
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic
  • reviewed API design and naming
  • reviewed documentation is accurate
  • reviewed tests and test coverage
  • manually tested (if applicable)

@blushi blushi changed the title ADR 042 - Add group module proto definitions and basic types feat: Add group module proto definitions and basic types Jul 5, 2021
@github-actions github-actions bot removed the C:x/gov label Jul 5, 2021
@codecov
Copy link

codecov bot commented Jul 5, 2021

Codecov Report

Merging #9631 (a2998c7) into master (d13d488) will decrease coverage by 0.02%.
The diff coverage is 4.16%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #9631      +/-   ##
==========================================
- Coverage   63.41%   63.39%   -0.03%     
==========================================
  Files         571      572       +1     
  Lines       37542    37551       +9     
==========================================
- Hits        23808    23806       -2     
- Misses      11876    11887      +11     
  Partials     1858     1858              
Impacted Files Coverage Δ
types/tx/msgs.go 0.00% <0.00%> (ø)
types/tx/types.go 6.31% <0.00%> (+0.37%) ⬆️
x/auth/tx/builder.go 73.01% <33.33%> (-0.43%) ⬇️

Copy link
Member

@aaronc aaronc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How about let's add a separate go.mod?

@@ -0,0 +1,244 @@
syntax = "proto3";

package cosmos.group.v1beta1;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's not release any more beta protos to production. We can keep this as is for now as long as we make sure to change to v1 after beta QA.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sounds good

@blushi
Copy link
Contributor Author

blushi commented Jul 7, 2021

How about let's add a separate go.mod?

We had this discussion with the orm package too and decided during some internal regen call to have it as a separate go module only when we migrate everything else (eg sdk modules) https://www.notion.so/regennetwork/ec16c9e6890f4241990e6575ff9b5cdc?v=bdd8303495c14680a6c92c220ee13458&p=5cb9a2cb6969475ba0317ec6d0fa2aa2
So I'm wondering if that should be the same for x/group or not? I don't have a strong opinion on that.

x/group/errors.go Outdated Show resolved Hide resolved
Copy link
Member

@tac0turtle tac0turtle left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK. Love the flatter module layout!

@tac0turtle
Copy link
Member

So I'm wondering if that should be the same for x/group or not? I don't have a strong opinion on that.

lets keep it under one go.mod for now. I dont think there has been a decision on modules as separate go.mods in the sdk.

@aaronc
Copy link
Member

aaronc commented Jul 8, 2021

So I'm wondering if that should be the same for x/group or not? I don't have a strong opinion on that.

lets keep it under one go.mod for now. I dont think there has been a decision on modules as separate go.mods in the sdk.

Let's discuss at the next architecture call. My thinking is that separate go.mod's will enable a quicker initial release cycle for new modules like x/group and x/nft. Do you have any objections @marbar3778 ?

@aaronc
Copy link
Member

aaronc commented Jul 8, 2021

I would like to add a MsgLeaveGroup via which one member can unilaterally leave the group. Opening a separate issue for this as I added automerge.

@aaronc aaronc added the A:automerge Automatically merge PR once all prerequisites pass. label Jul 8, 2021
Comment on lines +176 to +179
// TODO: do we want to support a withdrawn operation?
// A proposal can be deleted before the voting start time by the owner. When this happens the final status
// is Withdrawn.
// STATUS_WITHDRAWN = 4 [(gogoproto.enumvalue_customname) = "Withdrawn"];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this still an open question? Should we be tracking this with an issue?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good catch @ryanchristo! I have created an issue to track that: #9660

@mergify mergify bot merged commit 402148a into master Jul 9, 2021
@mergify mergify bot deleted the marie/7633-group-types branch July 9, 2021 07:36
@tac0turtle
Copy link
Member

Let's discuss at the next architecture call. My thinking is that separate go.mod's will enable a quicker initial release cycle for new modules like x/group and x/nft. Do you have any objections @marbar3778 ?

I like the idea of getting it out the door sooner! Lets give it a try

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A:automerge Automatically merge PR once all prerequisites pass. C:x/auth
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants