We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
https://go.dev/play/p/eotrEMU7U2Z
My initial goal is to have a duplicate function.
I'm using this function (with a recover) in my production environment with copier version 0.3.4 without problem.
When I'm trying with 0.3.5 I have some troubles.
Firstly, is that my dpulicate function is not working anymore, but without understand why.
dpulicate
panic: reflect: call of reflect.Value.Type on zero Value goroutine 1 [running]: reflect.Value.Type({0x0, 0x0, 0xc00010e750}) /usr/local/go-faketime/src/reflect/value.go:2262 +0x12e github.com/jinzhu/copier.copier({0x4e6e20, 0xc0001083a0}, {0x4e7260, 0xc000106200}, {0x68, 0x9e, {0x0, 0x1, 0x5de0e0}}) /tmp/gopath4171674566/pkg/mod/github.com/jinzhu/[email protected]/copier.go:262 +0x2626 github.com/jinzhu/copier.CopyWithOption(...) /tmp/gopath4171674566/pkg/mod/github.com/jinzhu/[email protected]/copier.go:76 main.duplicate({0x4e7260, 0xc000106200}) /tmp/sandbox2567366000/prog.go:64 +0x265 main.main() /tmp/sandbox2567366000/prog.go:51 +0x265
In a more classic case, copying from a structure to another one (line 46), copier.CopyWithOption is working but not well.
copier.CopyWithOption
Indeed, elts field is not empty despite the `copier:"-"` tag.
elts
`copier:"-"`
Moreover, if I use copier.Copy instead of copier.CopyWithOption:
copier.Copy
UT
The text was updated successfully, but these errors were encountered:
jinzhu
No branches or pull requests
Reproducible Example
https://go.dev/play/p/eotrEMU7U2Z
Description
My initial goal is to have a duplicate function.
I'm using this function (with a recover) in my production environment with copier version 0.3.4 without problem.
When I'm trying with 0.3.5 I have some troubles.
Error 1
Firstly, is that my
dpulicate
function is not working anymore, but without understand why.Case 2
In a more classic case, copying from a structure to another one (line 46),
copier.CopyWithOption
is working but not well.Indeed,
elts
field is not empty despite the`copier:"-"`
tag.Moreover, if I use
copier.Copy
instead ofcopier.CopyWithOption
:UT
field is not emptyelts
field is not emptyThe text was updated successfully, but these errors were encountered: