GenesysGo / shadow-drive-cli

Shadow Drive CLI
Apache License 2.0
13 stars 10 forks source link

"Irregular" sizes breaks the creation of storage accounts #7

Closed robbestad closed 1 year ago

robbestad commented 2 years ago

Creating a storage account that's not whole sizes breaks the creation of drives. Example:

shdw-drive create-storage-account -kp walletfile -s 7.96gb -n somename
This is beta software running on Solana's Mainnet. Use at your own discretion.
✔ This storage account will require an estimated 1.99 SHDW to setup. Would you like to continue? … yes
✖ Error processing transaction. See below for details:
Error: Invalid character

while using an increment of .5 or 1 works fine:

shdw-drive create-storage-account -kp walletfile -s 8gb -n somename
This is beta software running on Solana's Mainnet. Use at your own discretion.
✔ This storage account will require an estimated 2 SHDW to setup. Would you like to continue? … yes
✔ Successfully created your new storage account of 8gb located at the following address on Solana: 8fdFb93XdP62eMNTfCJk2qzn2sEdtMd4Gj9yor1wNaTY
tracy-codes commented 2 years ago

@robbestad Can you please confirm what version of the CLI you're using here?

robbestad commented 2 years ago

0.3.4.

robbestad commented 2 years ago

if you can't replicate this and the other, then I can happily just use the cloud server. I won't be using my desktop for this in the future anyway.

tracy-codes commented 2 years ago

I'm actually able to replicate this with using 7.96gb as the size parameter. We'll dig in to see about resolving. Thank you for reporting!

tracy-codes commented 2 years ago

Submitted a pull request to the SDK that will resolve this once merged: https://github.com/GenesysGo/shadow-drive/pull/64