Skip to content
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

[Storage] Allow renaming a bucket #2201

Merged
merged 8 commits into from
Aug 1, 2022
Merged

[Storage] Allow renaming a bucket #2201

merged 8 commits into from
Aug 1, 2022

Conversation

Tbaut
Copy link
Collaborator

@Tbaut Tbaut commented Jun 23, 2022

closes #2183

@render
Copy link

render bot commented Jun 23, 2022

@render
Copy link

render bot commented Jun 23, 2022

@render
Copy link

render bot commented Jun 23, 2022

@Tbaut
Copy link
Collaborator Author

Tbaut commented Jul 27, 2022

it's ready to go now that https://github.com/ChainSafe/files-api/issues/2380 is in.

@Tbaut Tbaut marked this pull request as ready for review July 27, 2022 09:57
Copy link
Contributor

@juans-chainsafe juans-chainsafe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! main functionality is working perfect, but I found some issues:
When you try to rename the bucket with an empty input,the dialog box is cut off in the screen:
Screen Shot 2022-07-27 at 09 08 52
Based on renaming an empty folder/file I think the box should say: "A name is required."

The second error, is when you try to rename the bucket with a bucket name that already exists, basically nothing happens, I see in the https://stage-api.chainsafe.io/api/v1/buckets/fef85ff2-23b1-4b53-bbf6-c83c022938ba API response that throw the error '...[E11000 duplicate key error collection...' so we have 2 possible solutions here:

  • Show an error message that can't be renamed with an existing name
  • Do the same that we do when renaming a folder: add '(1)' (or the corresponding number) at the end of the bucket name

@Tbaut
Copy link
Collaborator Author

Tbaut commented Jul 28, 2022

The second error, is when you try to rename the bucket with a bucket name that already exists, basically nothing happens, I see in the https://stage-api.chainsafe.io/api/v1/buckets/fef85ff2-23b1-4b53-bbf6-c83c022938ba API response that throw the error '...[E11000 duplicate key error collection...' so we have 2 possible solutions here:

Ah thanks for testing it, this is something that should be handled on the api level. I opened https://github.com/ChainSafe/files-api/issues/2500

I'll fix the other issue with the error

@Tbaut Tbaut requested a review from juans-chainsafe July 28, 2022 14:38
@Tbaut
Copy link
Collaborator Author

Tbaut commented Jul 28, 2022

The error message overflow is fixed now thanks for checking this out

Copy link
Contributor

@juans-chainsafe juans-chainsafe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Design error in the dialog box was fixed!
So, everything doable in the UI is done, so I will approve it and check again the 'rename with existing name' when the API tickets is closed.

Copy link
Contributor

@tanmoyAtb tanmoyAtb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to go!

@tanmoyAtb tanmoyAtb merged commit 84b396e into dev Aug 1, 2022
@tanmoyAtb tanmoyAtb deleted the tbaut-rename-bucket-2183 branch August 1, 2022 15:47
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.

[Storage] Add ability to rename a Bucket
5 participants