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

kcl test tool produces reflect error when schema parameter has type hint #70

Closed
amyXia1994 opened this issue Oct 19, 2022 · 2 comments
Closed
Assignees

Comments

@amyXia1994
Copy link
Contributor

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

a. create a test file: <dir>/main_test.k with the following content

schema Person:
    name: str

schema GetName[p: Person]:
    result: str = p.name

b. run: kcl-test <dir>/...

2. What did you expect to see? (Required)

test pass

3. What did you see instead (Required)

err occurred: FAIL <dir> err: reflect.Set: value of type *ast.Identifier is not assignable to type ast.TypeInterface%

4. What is your KusionStack components version? (Required)

releaseVersion: v0.3.20-debug-73-test
gitInfo:
    latestTag: v0.3.20-debug-73-test
    commit: 87ea0e74d8001e05e2049baf08e2990bdcf768b0
    treeState: dirty
buildInfo:
    goVersion: go1.17.9
    GOOS: linux
    GOARCH: amd64
    numCPU: 80
    compiler: gc
    buildTime: "2022-08-05 04:24:34"
dependency:
    kclvmVersion: v0.4.2-alpha.9
    kclPluginVersion: v0.2.20
@Peefy
Copy link
Contributor

Peefy commented Oct 19, 2022

U can move the issue into kclvm-go repo.

@Peefy Peefy transferred this issue from kcl-lang/kcl Dec 15, 2022
@amyXia1994
Copy link
Contributor Author

This is a bug introduced by the old version of the test tool and should be resolved by newer version: kcl-lang/kcl#178

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

3 participants