Executing read functions on Sway playground consumes gas

Hi,
While exploring and interacting with the Sway playground, I found an issue while reading the state. To take the example of the default contract (counter). After compiling and deploying the contract, during the interaction, calling the get function requires gas to get the current state of the counter. I assume, all the function components are mapped to the same read-write functionality whereas it should be differentiated as read & read-write. Also, read functions don’t require a dry run as it will just return the current state.

I appreciate the feedback @keshavsharma25. Read only calls shouldn’t require a wallet interaction, our internal team will investigate. :slight_smile:

1 Like