-
Notifications
You must be signed in to change notification settings - Fork 895
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
Don't make requests when importing subscriptions #5617
Don't make requests when importing subscriptions #5617
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't got round to testing this yet, but the code looks good.
@PikachuEXE found the issue, interestingly, this error could happen when not using this PR |
ee4aff6
to
91ef230
Compare
@PikachuEXE you're somehow subscribed to the same channel multiple times, not sure how that happened |
I think the double subscribe issue should be fixed here: 60a11d3 (you'll need to unsubscribe from the duplicate manually) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now. There are a few things that would be nice to have but are non-blocking:
- It's probably not worth keeping the progress bar logic anymore as the import is so fast now that there is probably more overhead in updating the progress than in the processing itself (additionally the progress bar has a 500ms animation, so when the import finishes in less than 60ms the progress bar will visually probably only reach 10% before we hide it).
- I was premature in suggesting that the
async
keyword should be removed, it's probably worthawait
ing thethis.updateProfile()
calls as they are asynchronous, so we only show theAll subscriptions have been successfully imported
toast once we know that the data has actually been saved. (if this is done, I would suggest adding back theThis might take a while, please wait
toast in all places that it was removed)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
works like a charm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Duplicate keys issue fixed
Don't make requests when importing subscriptions
Pull Request Type
Related issue
Description
A simplified version of #4340 that doesnt worry about having a lot of logic for fetching thumbnails if it's missing, the thumbnails can be fetched from other places (visiting the channel, refreshing subscriptions with local api + no rss)
Screenshots
Testing
See: #3735 (comment) & #4340
Change file extension
.txt
to.db
(Notice how much faster importing subscriptions is)
Desktop