-
-
Notifications
You must be signed in to change notification settings - Fork 47
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
feat(server): add random suffix mode #69
Conversation
Codecov ReportPatch coverage:
❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more. Additional details and impacted files@@ Coverage Diff @@
## master #69 +/- ##
==========================================
- Coverage 68.94% 67.45% -1.50%
==========================================
Files 11 11
Lines 483 510 +27
==========================================
+ Hits 333 344 +11
- Misses 150 166 +16
Flags with carried forward coverage won't be shown. Click here to find out more.
☔ View full report in Codecov by Sentry. |
Can you please add tests to cover these changes? |
I have to look into it. I did of course my own testing: https://play.rust-lang.org/?version=stable&mode=debug&edition=2021&gist=fbd05ecc4a7979366febb168fafd43b5 |
Please let me know, whether I missed anything. Otherwise I'd hope for a 0.11.0 release soon. Haha. ;-) |
I cleaned up the implementation a little bit for better readability and added fixture tests. Can you also confirm that it works as expected? |
I'll test within the hour. What I could see from the code at a first glance, it should be the same behavior. Although I chose I'll comment on the result of my tests in a bit. |
Yeah, it makes sense to use |
Yep, the code works the same, but I found a bug in my code (I missed it in my earlier test cases), which of course propagated to the refactored one:
For the first file I can look into this later today. For now I just reverted the option name. |
All fixed. Good to go. ;-) Not sure why the test suite fails. If you run P.S.:
|
Looks good, thank you!
I will work on it tomorrow 🐻 |
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.
🥳🥳🥳
Unfortunately the current implementation does not retain multiple extensions. So if you upload
foo.tar.gz
, the resulting file will beeu7f92x1.gz
.This PR includes 2 changes:
eu7f92x1.tar.gz
)suffix_mode
(bool) torandom_url
(result:foo.eu7f92x1.tar.gz
)closes #41