ton-blockchain / ton

Main TON monorepo
Other
2.95k stars 891 forks source link

Error running create-state #165

Closed leedioxin closed 4 years ago

leedioxin commented 4 years ago

When I try to run create state in the latest commit, I'm getting an error from the fift script CreateState

[ 1][t 0][1571676161.116434336][words.cpp:2906] CreateState.fif:194: pubkey>$: -? [ 1][t 0][1571676161.116489887][create-state.cpp:665] Error interpreting application-specific preamble file CreateState.fif: error interpreting included file CreateState.fif : CreateState.fif:194: pubkey>$: -? Check that correct include path is set by -I or by FIFTPATH environment variable, or disable standard preamble by -n.

It looks like I don't get this if I go back to before the last update to CreateState (commit 38c3e39066a9c3b8a62b2f4cad54df4dc6307360).

I was wondering if maybe a small bug was introduced?

ton-blockchain commented 4 years ago

Have you updated the standard Fift libraries such as TonUtil.fif?

leedioxin commented 4 years ago

Yes, I brought the whole repo up to date at the same time.

The only dirty file that shows up in status is validator-keys.

8< ----- snippet ------ >8 tonton@ip-10-5-1-13:~/source/ton$ git status On branch master Your branch is up to date with 'origin/master'.

Untracked files: (use "git add ..." to include in what will be committed)

    crypto/smartcont/validator-keys.pub

8< ------- end snippet ------ >8

And I'm on commit 9c9248a9ae1791152d88c9c36574b4becdf5e8b6 right now.

My FIFTPATH is pointing to the libs and source inside of the repo.

For building I made sure I did a make clean and then make.

== Still getting this ... tonton@ip-10-5-1-13:~/source/crypto$ ./create-state ../ton/crypto/smartcont/gen-zerostate-test.fif [ 1][t 0][1571751469.287052393][words.cpp:2906] CreateState.fif:194: pubkey>$: -? [ 1][t 0][1571751469.287115812][create-state.cpp:665] Error interpreting application-specific preamble file CreateState.fif: error interpreting included file CreateState.fif : CreateState.fif:194: pubkey>$: -? Check that correct include path is set by -I or by FIFTPATH environment variable, or disable standard preamble by -n.

ton-blockchain commented 4 years ago

Yes, so you probably set up FIFTPATH environment variable to a separate location not inside the local repository. Then CreateState.fif would load an older version of TonUtil.fif.

leedioxin commented 4 years ago

My FIFTPATH is pointed into my copy of the repo. I don't have another copy of TonUtil.fif.

I'm guessing nobody else is having this particular issue then?

ton-blockchain commented 4 years ago

We have managed to reproduce this problem. It will be fixed in a next commit. In the meantime, you can simply add "TonUtil.fif" include at the very beginning of CreateState.fif.

leedioxin commented 4 years ago

Oh, that's good news. Doing that does get me further.

Now it looks like one of the contracts in gen-zerostate-test isn't registering, but that's definitely a distinct issue. I'll poke around at it for a bit, and maybe open up a different issue.

I will close this one.

Thank you