Skip to content

Add share file with link expiration #292

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

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

onyx-and-iris
Copy link

@onyx-and-iris onyx-and-iris commented Mar 20, 2025

Hi, this expands on #287 (I wasn't sure how to modify the existing PR...).

This PR includes the following:

  • Snake case the expiredate kwarg to expire_date
  • expiration added to ShareInfo object returned by {Client}.share_file_with_link
  • test_share_with_link() has been expanded to include an expire_date.

When running the test suite TestPublicFolder.test_from_link kept failing with the error TypeError: can only concatenate str (not "int") to str due to line 401 so I added str(public_link_components.port).

This PR closes #287 and it closes #289.

Edit. I just noticed the last point is addressed by issue #291. So this PR overlaps and also closes #290 and closes #291.

@onyx-and-iris
Copy link
Author

On the final point, TypeError raised in {Client}.from_public_link(), I can see this was previously fixed in commit b0c02b7 but then reintroduced in 299a72c. So I suppose ":" + str(public_link_components.port) avoids the use of an f-string and prevents the TypeError.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

runtime error in from_public_link when port is not 80 Expiration date for public shared files
2 participants