-
Notifications
You must be signed in to change notification settings - Fork 375
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
io.Writer panic: name Write not declared #788
Comments
To fix this, we can try:
@schollz: consider working on another PoC while waiting for 1. or 3. to be addressed. Edit: the port will probably be harder than expected since |
I'll explore a related topic to support additional content-types, while maintaining our markdown-first approach. This includes investigating the implementation of a secure SVG image generation or simple PNG alternatives for the gno blog. However, it's important to note that while these features are of interest to me and can push the limits of Gno, they are not critical to the mainnet and will be a secondary priority or potentially blocked to keep the mainnet as streamlined as possible. See #439: rendering extensions |
Thanks Manfred.
This is the approach I was going towards, but for now I'll leave this and move onto other PoCs! |
I've assigned myself to the issue to try improving the error message. Though I think I'll also consider working on reflection as a larger thing I'll want to try work on (or at least make a PoC to start a discussion on inclusion and implementation). @schollz as for your POC, I think you could actually add encoding/binary to our stdlibs for now without the reflection parts. Reflection in encoding/binary is only used as a fallback and for complex data structures (slices and structs), as most others work simply on type switches. |
Good idea, I will take a stab at that. |
Okay to circle back to this and to make a signpost for future travelers: I did try to port My workaround is simply to create a custom Here's my gno working example for reference: https://github.com/schollz/gno/blob/bytebeat/examples/gno.land/p/demo/audio/riff/riff.gno This is not as easy as importing |
We have support for encoding/binary limited to BigEndian/LittleEndian; we don't have I'm closing this issue in favour of #1267 for tracking changes to the standard libraries. The error message is hard to improve; I'm more interested in unifying the standard libraries and providing no-op shims in the stdlibs for methods like this one instead, so that the error doesn't show up. |
I'm a little stumped. I have valid Go code (tested by converting to
.go
and running tests). But it seems not to be valid Gno code. It is usingio
and doesn't like using the.Write()
even though I can see thatio
and that function seem to be integrated into Gno. I wonder if I'm not importing thing correctly? I could use help figuring out whats going on.Here is my Gno package + test: d8d6297
Its just a small piece of a
.wav
file encoder (I'm working on a music application).I'm running
And getting the following error:
But if I change
.gno
to.go
I have no errors:If something needs to be added to the Gno library, I'm happy to work on that. I thought asking here would be the fastest way to find out if its just me doing something I'm not supposed to..
The text was updated successfully, but these errors were encountered: