-
Notifications
You must be signed in to change notification settings - Fork 58
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
Can't get space length via tarantool.crud #394
Comments
To be honest, it's more weird that every (or almost every) other method returns explicit |
Thank you for the issue, are you sure that go-tarantool version is exactly v2.0.0? It should be fixed with: Please, write a // ExampleLenRequest demonstrates how to execute a LenRequest.
func ExampleLenRequest() {
conn := exampleConnect()
req := crud.MakeLenRequest(exampleSpace)
ret := crud.LenResult{}
if err := conn.Do(req).GetTyped(&ret); err != nil {
fmt.Printf("Failed to execute request: %s", err)
return
}
fmt.Println(ret.Value)
// Output:
// 4
} Please, make sure that go-tarantool version is release and v2.0.0 at least (or you could use v2.1.0 to make sure). |
I use Thank you. I'll try to update to 2.1.0 and will be back with feedback |
With the update to version 2.1.0 the problem disappeared. Thank you very much for the quick response |
Can't get space length via crud.len
I get an error:
array len doesn't match: 1
db - is connected ConnectionPool
>>> panic: array len doesn't match: 1
When I use Count query everything is ok.
If you look at what arrives, you can see that only 1 entry in the array arrives for crud.len. And for count there are 2 entries:
The error occurs precisely during serialization. Therefore the code below works
Crud is installed, everything works correctly via tarantoolctl crud.len works.
The error seems clear, but I can’t understand why tarantool returns 1 field when asking for length.
golang version: 1.21.1
lib: go-tarantool/v2 2.0.0
OS: MacOs
tarantool version: 2.11
The text was updated successfully, but these errors were encountered: