mirror of
https://github.com/fsouza/fake-gcs-server.git
synced 2026-04-25 21:55:56 +03:00
[GH-ISSUE #410] Setting blob.custom_time doesn't work, returns always None #79
Labels
No labels
bug
compatibility-issue
docker
documentation
enhancement
help wanted
needs information
pull-request
question
stale
unfortunate
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/fake-gcs-server#79
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @oittaa on GitHub (Feb 4, 2021).
Original GitHub issue: https://github.com/fsouza/fake-gcs-server/issues/410
I have a piece of code like the following:
If I set
custom_timebefore uploading, even the real Google server erases it from the blob. That's why I patch it after the upload. The fake server unfortunately loses it even afterpatch.results in
None@oittaa commented on GitHub (Feb 5, 2021):
To me it looks like the
Custom-Timeis completely missing from objects.github.com/fsouza/fake-gcs-server@297b8cdcd2/fakestorage/object.go (L25-L43)https://cloud.google.com/storage/docs/metadata#custom-time
https://pkg.go.dev/cloud.google.com/go/storage#ObjectAttrsToUpdate
@oittaa commented on GitHub (Feb 6, 2021):
The original Google Cloud issue about missing
custom_timebefore patching is tracked here. https://github.com/googleapis/python-storage/issues/372@fsouza commented on GitHub (Feb 15, 2021):
Thanks for reporting and linking the docs!
@mar-pan commented on GitHub (Dec 23, 2022):
Hello @fsouza is there any chance that this could be assigned to someone and resolved? It looks like that Google resolved issue on their side and I can confirm that it works with "real" API
@fsouza commented on GitHub (Dec 28, 2022):
I opened #1024 (big round-number!) as a draft, in case someone wants to work on it. It's unlikely I'll be able to pick it back up in the next couple of weeks.
@RachitSharma2001 commented on GitHub (Jan 7, 2023):
@fsouza I believe I have a solution that fixes this issue and updates
CustomTimecorrectly. I am ready to submit a pr but since my solution is based off the changes I made to this PR (specifically the changes added toPatchObjectmethod inobject.go) I just want to make sure that those changes are good before submitting a pr to fix this issue.@fsouza commented on GitHub (Jan 7, 2023):
@RachitSharma2001 hey, I'm going to look at your PR later today (in 2 hours or so). If you prefer, you can open another PR on top of that one, or we can wait.
Apologies for the delayed review.