Interface Assertions not Working in Specific Cases
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 13.2k
- Forks
- 573
- PR merge metrics
- No merged PRs in 30d
Description
I'm not sure what exactly causes this. I tried to narrow this down but, unfortunately, no matter what I tried, the narrowed down code worked as expected. However, the code that I originally found the problem in is available. The tests for a project I'm working on fail in GopherJS but work fine in standard Go. In GopherJS, it panics with the line
interface conversion: io.Writer is not io.writer: missing method Write
Somewhat complicating the matter is that the io package in question is not the standard library's io package; it's a different package that's part of the aforementioned project.
I'll keep trying to narrow it down and update if I find the cause, but I figured I'd post this with the information I have so far in case someone's able to figure it out faster.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the wdte project tests with standard Go and GopherJS, then compare the interface assertion that produces the reported panic. The issue does not identify a source file or reduced reproduction, so done means isolating the failing case and making the GopherJS result match standard Go.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100