You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a block where I set bucket_folder to be a prefix like /appname and I was attempting to write files with date partitioning like /2024/09/06/whatever.gz.
I expected this would write to /appname/2024/09/06/whatever.gz, but it doesn't. It'll instead spit out /2024/09/06/whatever.gz. Sending in a non-absolute path like 2024/09/06/whatever.gz does work.
So that's all correct behavior for Path, because resolving an absolute path against another directory should just give you the absolute path back. But it's surprising behavior for this code because I would assume the prefix would always apply.
Anyways, this is really minor, and I can work around it. I can send in a pull issue if you want, it should be pretty trivial to change.
Thanks so much.
Version info (prefect version output)
Version: 2.20.4
API version: 0.8.4
Python version: 3.10.10
Git commit: 3b951c35
Built: Wed, Aug 28, 2024 9:09 PM
OS/Arch: darwin/arm64
Profile: prod
Server type: server
Additional context
No response
The text was updated successfully, but these errors were encountered:
Bug summary
Hi Prefect friends, thanks so much for making this thing.
I found some minor unexpected behavior when using the prefect-aws library and writing files to S3.
The issue is specifically with this line in
S3Bucket._resolve_path
:I have a block where I set
bucket_folder
to be a prefix like/appname
and I was attempting to write files with date partitioning like/2024/09/06/whatever.gz
.I expected this would write to
/appname/2024/09/06/whatever.gz
, but it doesn't. It'll instead spit out/2024/09/06/whatever.gz
. Sending in a non-absolute path like2024/09/06/whatever.gz
does work.So that's all correct behavior for Path, because resolving an absolute path against another directory should just give you the absolute path back. But it's surprising behavior for this code because I would assume the prefix would always apply.
Anyways, this is really minor, and I can work around it. I can send in a pull issue if you want, it should be pretty trivial to change.
Thanks so much.
Version info (
prefect version
output)Additional context
No response
The text was updated successfully, but these errors were encountered: