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

Spam-report for juice-shop pull requests and issues #29

Draft
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

hxrshxz
Copy link

@hxrshxz hxrshxz commented Feb 21, 2025

Description

Fetches spam-labeled closed PRs and issues from the last 30 days. it then stores them in a separate array and then tells about the total number of spam PRs and issues

Screencast.from.2025-02-22.03-06-25.mp4

Signed-off-by: Harsh Kumar <harshmastic@gmail.com>
Copy link
Member

@bkimminich bkimminich left a comment

Choose a reason for hiding this comment

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

Retrieving the last 30 days every time is not the way to go. Take a look at the other GitHub stats, we pull the data of the previous day and append it to a JSON, then commit to the repo. This means we have a growing permanent history. For the initial JSON you'd need to run the script for each day starting with the first day that ever had a spam PR/issue, then concatenate all subsequent days except the day that would be appended by the next CI run.

Also, the visualization is missing, and without the PR is too incomplete to merge.

Lastly, please remove your GitHub token. I think it works without - see the other GitHub stats again: https://github.com/juice-shop/juicy-statistics/blob/master/extractors/github.js

Signed-off-by: Harsh Kumar <harshmastic@gmail.com>
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
@hxrshxz
Copy link
Author

hxrshxz commented Feb 23, 2025

Retrieving the last 30 days every time is not the way to go. Take a look at the other GitHub stats, we pull the data of the previous day and append it to a JSON, then commit to the repo. This means we have a growing permanent history. For the initial JSON you'd need to run the script for each day starting with the first day that ever had a spam PR/issue, then concatenate all subsequent days except the day that would be appended by the next CI run.

Also, the visualization is missing, and without the PR is too incomplete to merge.

Lastly, please remove your GitHub token. I think it works without - see the other GitHub stats again: https://github.com/juice-shop/juicy-statistics/blob/master/extractors/github.js

I will be occupied with my university exams until March 7th 😅 . After that I will go through the codebase to understand it better and implement a similar approach for the spam-report and make the necessary changes

@hxrshxz hxrshxz marked this pull request as draft February 23, 2025 13:10
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
Signed-off-by: JuiceShopBot <61591748+JuiceShopBot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants