-
Notifications
You must be signed in to change notification settings - Fork 124
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
Reduce core dependencies #110
Conversation
By the way, I don't seem to have permissions to edit this PR. That, or I don't know how to do it:
I think I either have to be a collaborator, or I would have to create the PR, and then you edit it as the original creator. |
My bad, I have invited you as a collaborator. |
…ription of this doc.
Ok so I've made both of these optional features. The thing is, should any of them be included by default? I don't see A quick way to know what people use to authenticate is by checking GitHub repos:
Thus, more or less the 250/360 (69.4%) of the userbase needs the |
Agree, I think the use std::io;
match spotify_oauth.get_cached_token() {
Some(token_info) => Some(token_info),
None => {
request_token(spotify_oauth);
println!("Enter the URL you were redirected to: ");
let mut input = String::new();
match io::stdin().read_line(&mut input) {
Ok(_) => process_token(spotify_oauth, &mut input),
Err(_) => None,
}
}
} When there is no cache token exists, e.g |
Besides, of reducing core dependencies, I also plan to reduce some |
Agreed! The examples are quite repetitive and don't offer much help for real projects. I would add more advanced examples instead of lots of very simple ones. You can open a new issue or PR and I'll help you with that if you want. |
…otify into reduce-core-dependencies
I just open a new PR to reduce examples #113, feel free to contribute to it. |
Shouldn't we work on #95 first then? Did you figure something out? The error |
Yes, we should. The problem of tests is that the current test cases mostly depend on My intuition about fixing failed tests is just running them more times, for example, put a test case into a loop, and run it repeatedly(e.g 10 times), if any of them passes, the test passes. But it perhaps triggers the rate-limit strategy of |
Are you sure it's because of the Spotify rate limits anyway? Other Spotify API libraries like tekore have a 100% code coverage, meaning that they have even more tests than us, yet I don't recall them dealing with these issues. According to the issue I linked in the previous comment, it might have to do with |
To be honest, not sure, just my worry.
No clue about this issue. |
8f71992
to
d0f54a4
Compare
d0f54a4
to
9ee378b
Compare
I think this PR is ready to be merged now as well. Check out the changelog and documentation I wrote and let me know if you'd change anything. I also fixed a typo in Can you get rid of the GitGuardian security check? You have to log into GitGuardian as the owner of the repo and disable it. |
Merged :) |
Reducing core dependencies, check this issue #108 for more details:
rand
with a lightweight replacementgetrandom
dotenv
dependencybrowser
dependency