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

Generalized "GitHub Webhook + Contributor Role -> Rewards" No Config v1 #46

Open
Tracked by #22
0x4007 opened this issue Sep 25, 2024 · 65 comments · May be fixed by kingsley-einstein/contributions-scan#3
Open
Tracked by #22

Comments

@0x4007
Copy link
Member

0x4007 commented Sep 25, 2024

Dynamically map the config property name to count the amount of matching webhook events that occur in the issue/pull timeline, and credit accordingly. In which case, this plugin seems generally useful for mapping any value to any event, in the context of an issue or pull!

All this is intended to do is:

  1. get the timeline of events from the issue and the linked pulls
  2. assign a value of 1 to every event that is counted, per contributor.
  3. return sum totals.

In the next iteration, we should identify the user's "class" (specification author, assignee, collaborator, contributor)

In the final iteration, we should enable config.

@Apetree100122

This comment was marked as spam.

@0x4007
Copy link
Member Author

0x4007 commented Oct 7, 2024

301 based on a very quick Look

@Amit0617
Copy link

/start

Copy link

ubiquity-os bot commented Oct 10, 2024

! Please set your wallet address with the /wallet command first and try again.

@Amit0617
Copy link

/wallet 0x47c0C4eb25b0Aa4bC5D1E6341F5eE9A6aD2B596c

Copy link

ubiquity-os bot commented Oct 10, 2024

+ Successfully registered wallet address

@Amit0617
Copy link

/start

Copy link

ubiquity-os bot commented Oct 10, 2024

Deadline Fri, Oct 11, 7:06 AM UTC
Beneficiary 0x47c0C4eb25b0Aa4bC5D1E6341F5eE9A6aD2B596c

Tip

  • Use /wallet 0x0000...0000 if you want to update your registered payment wallet address.
  • Be sure to open a draft pull request as soon as possible to communicate updates on your progress.
  • Be sure to provide timely updates to us when requested, or you will be automatically unassigned from the task.

@Amit0617
Copy link

Wanted to be sure about how the pull request is supposed to be created? Should I create a new folder with all files, since there are probably going to be multiple plugins here?

@0x4007
Copy link
Member Author

0x4007 commented Oct 10, 2024

It should be one plugin. Fork the plugin template and link your pull here

@Amit0617

This comment was marked as outdated.

@Amit0617
Copy link

@0x4007 may I ask for reviewing above PR?

@0x4007
Copy link
Member Author

0x4007 commented Oct 30, 2024

It's closed because you didn't follow the necessary instructions

@Amit0617
Copy link

Amit0617 commented Oct 30, 2024

I was asking to review the one opened after the closed one (following instructions as suggested). Amit0617/contributor-rewards#3 particularly

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

It's up for review.

@gentlementlegen
Copy link
Member

@kingsley-einstein Your PR seems to target your own repo somehow, I cannot assign reviewers there.

@kingsley-einstein
Copy link

@kingsley-einstein Your PR seems to target your own repo somehow, I cannot assign reviewers there.

@gentlementlegen
It was forked from the template repo, and I'm not supposed to raise a PR against that repo.

@gentlementlegen
Copy link
Member

It doesn't make sense, your PR should be opened against Ubiquity's organization, there should be a repo that would accommodate your changes. If there is none at the moment ask for one to be created.

@kingsley-einstein
Copy link

It doesn't make sense, your PR should be opened against Ubiquity's organization, there should be a repo that would accommodate your changes. If there is none at the moment ask for one to be created.

@gentlementlegen I know that now. Could one be created now, so I switch origins locally, and commit my changes?

@EresDev
Copy link

EresDev commented Nov 11, 2024

You can test directly against the relevant PR, by running the slash command "/scan-contributions". For the env vars, you'll mostly need GITHUB_TOKEN set in a .dev.vars file.

I tried adding github token, but the issues are still there.

It turned out manifest file isn't being served correctly but the plugin should work smoothly with ubuiquity-os-kernel instances. I fixed manifest file issue and then the event being passed is null. So, it needs some attention to work smoothly with kernel as plugins are supposed to. Maybe try setting up a local instance to debug? Testing it only in your PR is helpful but it isn't sufficient.

@kingsley-einstein
Copy link

You can test directly against the relevant PR, by running the slash command "/scan-contributions". For the env vars, you'll mostly need GITHUB_TOKEN set in a .dev.vars file.

I tried adding github token, but the issues are still there.

It turned out manifest file isn't being served correctly but the plugin should work smoothly with ubuiquity-os-kernel instances. I fixed manifest file issue and then the event being passed is null. So, it needs some attention to work smoothly with kernel as plugins are supposed to. Maybe try setting up a local instance to debug? Testing it only in your PR is helpful but it isn't sufficient.

@EresDev
The task relies on just listening for issue comments, not all kinds of events. Also, to get it to work, you must send a payload with the same structure as Github event payloads.

@EresDev
Copy link

EresDev commented Nov 11, 2024

The task relies on just listening for issue comments, not all kinds of events.

Yes, the event I am trying is issue_comment.created and it is having problems in processing it.. The event is passed from github, so yes it is a real GitHub event payload. Only difference from your setup is that I have kernel, and plugin running on my local machine. I am testing here.

@Keyrxng
Copy link
Member

Keyrxng commented Nov 11, 2024

@0x4007 @gentlementlegen @EresDev

I already built this plugin and met the targets of each spec for the whole parent task including unit tests.

The org repo was deleted and my PR along with it for some reason before the task was broken into four steps.

I'd like to submit my plugin for consideration for these tasks considering I already put in the work and the PR was received well at the time and is ready to go.

  1. This plugin would sooner be live.
  2. My efforts would not have gone to waste and no-one need waste any more of theirs unnecessarily (both reviewers and contributors)

@0x4007
Copy link
Member Author

0x4007 commented Nov 12, 2024

@0x4007 @gentlementlegen @EresDev

I already built this plugin and met the targets of each spec for the whole parent task including unit tests.

The org repo was deleted and my PR along with it for some reason before the task was broken into four steps.

I'd like to submit my plugin for consideration for these tasks considering I already put in the work and the PR was received well at the time and is ready to go.

  1. This plugin would sooner be live.

  2. My efforts would not have gone to waste and no-one need waste any more of theirs unnecessarily (both reviewers and contributors)

If it works according to the spec and you can prove it then sure. Although we would probably need to recreate the issue because a lot of conversation that doesn't belong under the issue happened here.

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

It's under review

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

Still under review botty.

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

Still under review botty! Sheesh!

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

Still under review.

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

under review

2 similar comments
@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

under review

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

under review

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

1 similar comment
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

1 similar comment
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

@kingsley-einstein
Copy link

@kingsley-einstein, this task has been idle for a while. Please provide an update.

Still under review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment