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

Contract changes requiring a page refresh after deploy to be usable in a transaction #740

Open
Deewai opened this issue Sep 11, 2023 · 6 comments · Fixed by #742
Open

Contract changes requiring a page refresh after deploy to be usable in a transaction #740

Deewai opened this issue Sep 11, 2023 · 6 comments · Fixed by #742

Comments

@Deewai
Copy link

Deewai commented Sep 11, 2023

Describe the bug
Changes to a smart contract don't reflect in transactions(even after a redeploy) until after the page is reloaded. So if i add a new function to my contract and deploy, that function is not accessible in a transaction until i reload the page

To Reproduce
Steps to reproduce the behavior:

  • open the flow playground
  • add a new function access(all) fun hi(): String { return "hi" } to the default HelloWorld contract
  • deploy the contract
  • click on the Transaction file and try calling HelloWorld.hi()
  • and you'll get an error value of type HelloWorldhas no memberhi. unknown member

Expected behavior
Expect no error to occur and the transaction should be runnable

Screenshots
If applicable, add screenshots to help explain your problem.

Desktop (please complete the following information):

  • OS: MacOS
  • Browser chrome
  • Version 2.1.0

Additional context
Add any other context about the problem here.

@nvdtf
Copy link
Member

nvdtf commented Sep 11, 2023

To reproduce you have to deploy HelloWorld once, then subsequent updates (redeploys) need refreshes. Thanks for reporting!

@bthaile
Copy link
Contributor

bthaile commented Sep 20, 2023

Redeployed HelloWorld
logs say the original deployed contract is on 0x01 account. Then redeployed contracts to correct address. Def something fishy going on here.
image

@bthaile
Copy link
Contributor

bthaile commented Sep 20, 2023

I think this is an issue cuz we had to change account addresses from 0x01...0x05 to 0x05...0x09.
I'll do more testing.

@bthaile
Copy link
Contributor

bthaile commented Sep 20, 2023

I think I got the issue fixed. Thanks for reporting it.

@bthaile bthaile mentioned this issue Sep 20, 2023
6 tasks
@bthaile bthaile reopened this Sep 20, 2023
@bthaile
Copy link
Contributor

bthaile commented Sep 20, 2023

I'm still seeing that transactions don't evaluate contracts until there is a change.

@bthaile
Copy link
Contributor

bthaile commented Sep 21, 2023

Looks like there is a LS issue that is effecting playground and vscode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🏗 In Progress
Development

Successfully merging a pull request may close this issue.

3 participants