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
*wallet.ReadableWallet is not wallet.Wallet: missing method AddEntry #16
Comments
pull again, then run
Sometimes, golang does not recompile libraries after the source code is updated. |
That didn't fix it. Since you seem to think this is likely build related, I'll review the setup process again. I didn't exactly follow your guide, so this could be my fault. I'll update this again if I learn more. |
I added: So is the error here that (1) it should not be using ReadableWallet as a Wallet, OR (2) that ReadableWallet is supposed to implement Wallet (which it does not). If the error is (2), you can add "var _ Wallet = &ReadableWallet{}" to readable.go to catch such issues at compile time. I also tried deleteing all files in ~/.skycoin/ and it did not help. gateway.CreateWallet is commented as returning a *ReadableWallet, which is what it does return. walletHandlerPOST then tries to use it as a Wallet (so it can call "SetName"), which *ReadableWallet is not. I replaced the relevant code (where the panic trace points) in walletHandlerPOST (which used to type assert to wallet.Wallet) with:
which does not panic, but does not save the wallet (I see no same methods on wallet.ReadableWallet). This at least lets me have an address show up in the GUI. I don't think this is a build or configuration issue. The latest code on github seems to agree with what I'm seeing locally. Anyway, I don't know my way around the code yet, so I can't do much more than that. |
I'm still seeing this error. Looks like its line 75 now though: src/gui/wallet.go:75 It now only seems to happen when I press "New Wallet", which then creates 2 additional wallets (it used to not appear to add any wallets). |
Wallet is undergoing refactoring to use the new deterministic wallets. |
I get this panic printed out ever second or so when I run: ./run.sh -web-interface=true
I'm at commit a90649c: use deterministic wallet
[skycoin.daemon:INFO] Requesting DHT Peers
2014/03/23 16:34:31 http: panic serving 127.0.0.1:34004: interface conversion: _wallet.ReadableWallet is not wallet.Wallet: missing method AddEntry
goroutine 124 [running]:
net/http.func·009()
/usr/local/go/src/pkg/net/http/server.go:1093 +0xae
runtime.panic(0x798160, 0xc2105bda00)
/usr/local/go/src/pkg/runtime/panic.c:248 +0x106
github.com/skycoin/skycoin/src/gui.walletHandlerPOST(0xc210091240, 0x7fe1145e6bc8, 0xc2105d8c80, 0xc2105bfc30)
/home/craig/sky/src/github.com/skycoin/skycoin/src/gui/wallet.go:74 +0xf3
github.com/skycoin/skycoin/src/gui.func·010(0x7fe1145e6bc8, 0xc2105d8c80, 0xc2105bfc30)
/home/craig/sky/src/github.com/skycoin/skycoin/src/gui/wallet.go:103 +0x14f
net/http.HandlerFunc.ServeHTTP(0xc210094800, 0x7fe1145e6bc8, 0xc2105d8c80, 0xc2105bfc30)
/usr/local/go/src/pkg/net/http/server.go:1220 +0x40
net/http.(_ServeMux).ServeHTTP(0xc2100974b0, 0x7fe1145e6bc8, 0xc2105d8c80, 0xc2105bfc30)
/usr/local/go/src/pkg/net/http/server.go:1496 +0x163
net/http.serverHandler.ServeHTTP(0xc21001ea00, 0x7fe1145e6bc8, 0xc2105d8c80, 0xc2105bfc30)
/usr/local/go/src/pkg/net/http/server.go:1597 +0x16e
net/http.(_conn).serve(0xc2105cee00)
/usr/local/go/src/pkg/net/http/server.go:1167 +0x7b7
created by net/http.(_Server).Serve
/usr/local/go/src/pkg/net/http/server.go:1644 +0x28b
[skycoin.daemon:INFO] Requesting DHT Peers
The text was updated successfully, but these errors were encountered: