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

import "github.com/uber/jaeger-client-go" issue #1537

Closed
caiuskong opened this issue Apr 8, 2023 · 2 comments · Fixed by #1541
Closed

import "github.com/uber/jaeger-client-go" issue #1537

caiuskong opened this issue Apr 8, 2023 · 2 comments · Fixed by #1541
Labels
area/core bug Something isn't working

Comments

@caiuskong
Copy link

The following program sample.go triggers an unexpected result

package main

import (
    "fmt"
    "github.com/uber/jaeger-client-go"
)

func main() {
  fmt.Println(jaeger.JaegerClientVersion)
}

Expected result

Go-2.30.0

Got

scope.go:220: nil type
panic: nil type

goroutine 1 [running]:
log.Panic({0x14002117678, 0x1, 0x1})
        /opt/hostedtoolcache/go/1.17.5/x64/src/log/log.go:354 +0x98
github.com/traefik/yaegi/interp.(*scope).add(0x1400026ca20, 0x0)
        /home/runner/work/yaegi/yaegi/interp/scope.go:220 +0x58
github.com/traefik/yaegi/interp.(*Interpreter).cfg.func1(0x1400165f9e0)
        /home/runner/work/yaegi/yaegi/interp/cfg.go:192 +0x38a8
github.com/traefik/yaegi/interp.(*node).Walk(0x1400165f9e0, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:285 +0x38
github.com/traefik/yaegi/interp.(*node).Walk(0x1400165f560, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x1400165f440, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x1400165f320, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x1400163b9e0, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x140015758c0, 0x14002117cb0, 0x14002117c78)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*Interpreter).cfg(0x14000368000, 0x140015758c0, 0x1400026ca20, {0x140005a1b01, 0x25}, {0x14000e83ef0, 0xb})
        /home/runner/work/yaegi/yaegi/interp/cfg.go:62 +0x1ac
github.com/traefik/yaegi/interp.(*Interpreter).importSrc(0x14000368000, {0x140013da820, 0x20}, {0x140005a1b01, 0x25}, 0x1)
        /home/runner/work/yaegi/yaegi/interp/src.go:125 +0x71c
github.com/traefik/yaegi/interp.(*Interpreter).gta.func1(0x14000553c20)
        /home/runner/work/yaegi/yaegi/interp/gta.go:237 +0x1c10
github.com/traefik/yaegi/interp.(*node).Walk(0x14000553c20, 0x14002118a58, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:285 +0x38
github.com/traefik/yaegi/interp.(*node).Walk(0x140005538c0, 0x14002118a58, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x14000553680, 0x14002118a58, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*Interpreter).gta(0x14000368000, 0x14000553680, {0x140013da820, 0x20}, {0x140001151a1, 0x20}, {0x1400200dc00, 0x6})
        /home/runner/work/yaegi/yaegi/interp/gta.go:20 +0x17c
github.com/traefik/yaegi/interp.(*Interpreter).importSrc(0x14000368000, {0x1400011f9d0, 0x4}, {0x140001151a1, 0x20}, 0x1)
        /home/runner/work/yaegi/yaegi/interp/src.go:108 +0xfa4
github.com/traefik/yaegi/interp.(*Interpreter).gta.func1(0x14000373d40)
        /home/runner/work/yaegi/yaegi/interp/gta.go:237 +0x1c10
github.com/traefik/yaegi/interp.(*node).Walk(0x14000373d40, 0x14002119828, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:285 +0x38
github.com/traefik/yaegi/interp.(*node).Walk(0x14000373320, 0x14002119828, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*node).Walk(0x140003730e0, 0x14002119828, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:289 +0x88
github.com/traefik/yaegi/interp.(*Interpreter).gta(0x14000368000, 0x140003730e0, {0x1400011f9d0, 0x4}, {0x1400011f9d0, 0x4}, {0x1400011f9d0, 0x4})
        /home/runner/work/yaegi/yaegi/interp/gta.go:20 +0x17c
github.com/traefik/yaegi/interp.(*Interpreter).gtaRetry(0x14000368000, {0x1400024fa40, 0x1, 0x1}, {0x1400011f9d0, 0x4}, {0x1400011f9d0, 0x4})
        /home/runner/work/yaegi/yaegi/interp/gta.go:346 +0x150
github.com/traefik/yaegi/interp.(*Interpreter).CompileAST(0x14000368000, {0x101899a70, 0x140002d6280})
        /home/runner/work/yaegi/yaegi/interp/program.go:77 +0x184
github.com/traefik/yaegi/interp.(*Interpreter).compileSrc(0x14000368000, {0x14000476f00, 0x2182}, {0x16f102b4d, 0xb}, 0x0)
        /home/runner/work/yaegi/yaegi/interp/program.go:52 +0x110
github.com/traefik/yaegi/interp.(*Interpreter).eval(0x14000368000, {0x14000476f00, 0x2182}, {0x16f102b4d, 0xb}, 0x0)
        /home/runner/work/yaegi/yaegi/interp/interp.go:606 +0x50
github.com/traefik/yaegi/interp.(*Interpreter).EvalPath(0x14000368000, {0x16f102b4d, 0xb})
        /home/runner/work/yaegi/yaegi/interp/interp.go:508 +0xe8
main.runFile(0x14000368000, {0x16f102b4d, 0xb}, 0x0)
        /home/runner/work/yaegi/yaegi/cmd/yaegi/run.go:153 +0xb0
main.run({0x140001921a0, 0x1, 0x1})
        /home/runner/work/yaegi/yaegi/cmd/yaegi/run.go:116 +0xe14
main.main()
        /home/runner/work/yaegi/yaegi/cmd/yaegi/yaegi.go:133 +0xf4

Yaegi Version

0.11.2

Additional Notes

yaegi 0.15.0 and 0.15.1 still error

@caiuskong
Copy link
Author

"go.opentelemetry.io/otel" // unsupported, include unsafe

@mvertes mvertes added bug Something isn't working area/core labels Apr 11, 2023
mvertes added a commit to mvertes/yaegi that referenced this issue Apr 12, 2023
Only structures with one embedded field can be marked anonymous,
due to golang/go#15924. Also check only that the method is defined,
do not verify its complete signature, as the receiver may or not
be defined in the arguments of the method.

Fixes traefik#1537.
@mvertes mvertes modified the milestone: v0.15.x Apr 12, 2023
traefiker pushed a commit that referenced this issue Apr 13, 2023
Only structures with one embedded field can be marked anonymous, due to golang/go#15924. Also check only that the method is defined, do not verify its complete signature, as the receiver may or not be defined in the arguments of the method.

Fixes #1537.
@caiuskong
Copy link
Author

hi @mvertes,
I see that the code has been merged to master long ago, when is the new version of yaegi expected to be released, I would like to use it in the traefik local plugin...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/core bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants