-
Notifications
You must be signed in to change notification settings - Fork 14
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
panic("todo") when marshalling cbor tags #9
Comments
It is indeed a TODO for refmt :) This path is hit when marshalling traverses to struct value of a type which hasn't had explicit configuration in the atlas. If you add another The future plan is to make additional options to the overall atlas build for whether or not to silently try to autogenerate configuration for structs when they're encountered. This would be equivalent to what the stdlib json packages do. In refmt I think we'll probably keep that to off by default, based on the theology that explicit is better than implicit (and personally, mostly because I'm really frustrated whenever I find an Of course, the way this currently errors is more aggressively than it should, and the fact that the message doesn't really point you in the right direction is a pretty gross bug, and I'll try to at least improve those messages ASAP. |
Slightly improves the situation in issue #9. Signed-off-by: Eric Myhre <hash@exultant.us>
Error message should be more useful as of that commit on master ^ |
Thank you 👍 Interestingly enough the error went away when I switched to using the non pointer version of my struct, without changing anything else in the atlas. |
Ohhh. Hm, that's a thing that should have its own checks. The object used as the "type reference" in |
GC/closing because #11 covers it. |
Hey,
I am trying to use the new tag functionality discussed in #7. But I have run into a beautiful
panic todo
.You can see the trace below.
The
From what I gathered this seems to come from here: https://github.com/polydawn/refmt/blob/master/obj/marshalSlab.go#L141 but I am not sure if this is something I should fix in my code or this needs to be fixed in the library.
The text was updated successfully, but these errors were encountered: