-
Notifications
You must be signed in to change notification settings - Fork 33
[PB-4948]: fix/allow uploading empty files #1782
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
base: master
Are you sure you want to change the base?
Conversation
Deploying drive-web with
|
| Latest commit: |
97c4f9c
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://16da61b4.drive-web.pages.dev |
| Branch Preview URL: | https://feature-upload-empty-files.drive-web.pages.dev |
| if (!fileId) { | ||
| throw new FileIdRequiredError(); | ||
| } |
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.
I left this comment in order to check if the upload of empty files are already implemented in backend for workspaces in order to remove this check
|
|
||
| const isWorkspacesUpload = workspaceId && workspacesToken; | ||
|
|
||
| if (isFileEmpty(file.content) && !isWorkspacesUpload) { |
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.
I left this comment in order to check if the upload of empty files are already implemented in backend for workspaces to remove this condition && !isWorkspacesUpload
|
|
||
| export class RetryableFileError extends Error { | ||
| constructor(public file: FileToUpload) { | ||
| super('Retryable file'); |
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.
What is 'Retryable file' error means?
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.
It is an error already throw for us when the downloaded file does not have file ID. You can check it here, where I just extracted the error from the service, but it was already used.
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.
why it's not FileIdRequiredError then?
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.
I see that the error is only used there. Another teammate added it in the past, but not sure why. I'm going to update it using the name you suggested or similar, yes.
|
@xabg2 79,2% Almost!!! |
|



Description
Allow the user to create empty files.
Related Issues
Related Pull Requests
Checklist
Testing Process
Additional Notes
The status of this PR has been updated back to “Draft” because we must wait for the other platforms to allow empty files to upload/download empty files, but the request can be reviewed in the meantime so that it can be implemented when necessary.