Comments (19)
@wagnernegrao Good catch.
I think before posting it on twitter, checking the issue date will be a good option to fix this.
Any thoughts?
from first-issues.
No, I also think will be a good option to fix this.
from first-issues.
Feel free to send a PR for this if you like
from first-issues.
@arshadkazmi42 has funded $5.00 to this issue.
- Submit pull request via IssueHunt to receive this reward.
- Want to contribute? Chip in to this issue via IssueHunt.
- Checkout the IssueHunt Issue Explorer to see more funded issues.
- Need help from developers? Add your repository on IssueHunt to raise funds.
from first-issues.
Hi @arshadkazmi42 I would like to take a shot at resolving this. Just making sure I have the problem understood:
Would you like the first issue bot to see when the initial issue was created to see if it is posting a repeat?
from first-issues.
@senatormailman Yes. Thats Correct. I think it will be a bit difficult to check for duplicate.
I think we just want to check the issue status, if the issue is open or not.
If the issue is closed we don't want to post it on twitter.
For now I think this would be fine.
Let me know you if have any other thoughts or suggestions for this.
from first-issues.
can take this up?
from first-issues.
@isaac-philip Sure. Go ahead.
from first-issues.
Is this still open?
from first-issues.
@isaac-philip are you still working on this? Or @therajdeepbiswas could take it up.
from first-issues.
Yes please go ahead.
Apologies for the delay to respond.
from first-issues.
@arshadkazmi42 from this conversation, what I understand of the requirement is: if the issue is a good first issue
and it is open
, only then add it to the database. Is my understanding correct?
from first-issues.
I have observed in first_timers.py
that an issue's is:open
is accounted for. I am a little confused about the problem at hand; it's observed that db.json
is updated from scratch (not appended) everytime run.py
is executed. Hence it is expected that the twitter bot might post the same issue more than once (provided if the updated json contains the same issue but is still open
).
So what is our desired behavior now? If the same issue still continues to be open
, is it okay to post it again? If that is so, this is how your (present) code already works.
If not, our other option is to never post the same issue twice (even if it is open); one way to handle this would be to keep track of every issue that has ever been posted.
The above will require us to maintain another json (or other form of) database to keep track of. Let me know what sounds good to you or if there is something more which you'd like to add to this.
from first-issues.
@therajdeepbiswas I know its difficult to track the duplicate. So I thought lets just add a check to post the issue only if its open
I am don't remember exactly if the check is already present. If its already present, I don't think we can do much about it.
For handling duplicates, I don't think we should over engineer things, since the bot does not uses any database, its going to be a complex task.
I also had a thought around this for just adding a check for how old the issue is. How about checking the date of creation of the issue and if its older than 15 days, lets not tweet that. So we will have only fresh issues posted with that the check for the issue should not be in closed state.
Any thoughts on this?
from first-issues.
@arshadkazmi42 Yes, your code does check for is:open
, you've passed that in with your API call (first_timers.py: line 10
), so we already have that taken care of.
Checking the age of the issue sounds good to me. (Question) How often does your bot post on twitter (if there is an active one)? Let's say we synchronize the 15
days, which you mention, with the bot. The bot will only post once every 15 days and when it does, it will only be issues created in (the same) last 15 days, and repeat. That way we won't miss anything and also prevent duplicates, I believe.
Just a note; I agree that managing a database of historical IDs (even if in a simple text file) would require to overengineer things between fetching the json and selectively saving it into a file, so let's not do that.
I'll create a PR once I have a confirmation from your end if the former mentioned thing is what you'd like to go with.
from first-issues.
@therajdeepbiswas The bot runs every 1 minute and tweets all the issues it has found with the label. Since if we have long delays for running of bot it will tweet alot of tweets in one go and twitter blocks those type of accounts. So we run it every 1 minute to minimize the number of tweets in one go.
Just having 15 days check for now should be good enough. Also, lets keep this day easily configurable so if we want to change it later we will be able to do it easily.
from first-issues.
@arshadkazmi42 I have opened PR #61. Do take a look
from first-issues.
@therajdeepbiswas Thank you for the PR. I will have look at it ASAP.
from first-issues.
@arshadkazmi42 has rewarded $3.50 to @therajdeepbiswas. See it on IssueHunt
💰 Total deposit: $5.00🎉 Repository reward(20%): $1.00🔧 Service fee(10%): $0.50
from first-issues.
Related Issues (20)
- Change LICENSE to MIT HOT 3
- Change github workflow to run on pull request HOT 2
- emojies makes readme file to undestand better !!! HOT 3
- Build failing HOT 1
- No License Change to MIT? HOT 2
- Dockerize the bot
- Limting number of # tags in tweet HOT 2
- Deploy HOT 1
- Looking for a sponsor HOT 5
- Add code of conduct.md HOT 1
- Remove contributors section from README
- Remove .github directory HOT 2
- Deploy new version
- Configure test discovery as per pytest good practices HOT 2
- Install a Makefile to automate tasks HOT 1
- Why are the links failing, or is it just me? HOT 1
- Some code refactoring may be needed
- Add Logging Module HOT 9
- Lines too long
- Add missing documentation for functions
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from first-issues.