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

Type error when running stonks #6

Closed
ghost opened this issue May 21, 2020 · 2 comments
Closed

Type error when running stonks #6

ghost opened this issue May 21, 2020 · 2 comments

Comments

@ghost
Copy link

ghost commented May 21, 2020

$ stonks AMD
panic: interface conversion: interface {} is int, not graph.ChartTheme

goroutine 1 [running]:
main.main.func1(0xc0000eeb00, 0xc0000ad530, 0x1, 0x1)
/home/jc/Documents/finance/stonks/main.go:106 +0x1606
github.com/spf13/cobra.(*Command).execute(0xc0000eeb00, 0xc0000ba030, 0x1, 0x1, 0xc0000eeb00, 0xc0000ba030)
/home/jc/go/pkg/mod/github.com/spf13/cobra@v1.0.0/command.go:846 +0x29d
github.com/spf13/cobra.(*Command).ExecuteC(0xc0000eeb00, 0xc0000c4bc8, 0x910edb, 0x7)
/home/jc/go/pkg/mod/github.com/spf13/cobra@v1.0.0/command.go:950 +0x349
github.com/spf13/cobra.(*Command).Execute(...)
/home/jc/go/pkg/mod/github.com/spf13/cobra@v1.0.0/command.go:887
main.main()
/home/jc/Documents/finance/stonks/main.go:192 +0x605

OS: linux mint 19.2
Stonks was installed using go version go1.14.3 linux/amd64

Steps to reproduce:
$ stonks -s AMD
$ stonks

@ericm
Copy link
Owner

ericm commented May 21, 2020

Thanks. I'll fix that asap.

@FileGo
Copy link

FileGo commented May 21, 2020

This should do for main.go:106.

chartTheme := graph.ChartTheme(viper.GetInt("config.default_theme"))

@ericm ericm closed this as completed in 8678340 May 21, 2020
ericm added a commit that referenced this issue May 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants