Some guidance on reproducing, reporting and fixing issues #49
Replies: 5 comments 8 replies
-
Good points. I believe that the name should work if the button is replaced with And yes, good points on overall documentation to help contributors get into the code. Do you have any examples of projects that do this well? Regarding Ginkgo, I had actually come to the conclusion that it was a mistake, partly for the reasons you mention, that it's a barrier for contributors. So recently, whenever I've been working on a specific feature, I've started by converting the ginkgo suite to non-ginkgo. I was however migrating tests to "testify" test suites, so not pure std lib as you suggest. But testify does seem to be widely adopted, so it should be far less of a barrier of contributors. I started using ginkgo when I first used Go. Back then the ability to structure tests, e.g., using subtests were limited, and Ginkgo provided clear benefits. But this style of testing doesn't work as well in Go as it does in other languages (few match the elegance of RSpec, to mother of them all). So the other reason I'm abandoning Ginkgo is that with Go subtests, made easily consumable through testify suites, the benefit of Ginkgo just isn't that great anymore. I don't have plans at the moment to replace Gomega (an assertion library often used with Ginkgo) at the moment, as it allows expressive tests
I don't find that this should be as much of a barrier, as the intend of this code is very clear. But I will not enforce contributors to use this. As long as behavior is properly tested, I'm good. And simple assertions, such as simple equality or But one nice thing about Gomega is the implicit error return value check. But I'd love to hear your thoughts if you think I should completely abandon the use of testify suites, and Gomega for assertions? The v8go project uses raw stdlib for tests, and I am personally not happy about not even using an assertion library, a simple assertion takes 3 lines of code, because you need to wrap them in |
Beta Was this translation helpful? Give feedback.
-
But for the concrete issue, I will start refactoring tests regarding form behavior. If you would like to add the test for the issue, let me know. Then I'll just stop at the point when the tests are refactored. Btw, the |
Beta Was this translation helpful? Give feedback.
-
And thanks for feedback. I love to hear that this is being used, and the feedback is also extremely important in understanding the direction to take, and what to prioritize. And to keep me motivated. |
Beta Was this translation helpful? Give feedback.
-
Correction, the |
Beta Was this translation helpful? Give feedback.
-
Allright, I've identified the issue in your repro, and that's a bit embarrassing. So first of all, thanks for providing a repro. The Tests were passing because they verified the request body, and not the result of It's pushed as v0.3.1 HOWEVER My test application didn't exhibit any issues, and I believe that was because it was an HTMX post, so the bug in Gost's form post behaviour didn't affect that case, because it creates the headers on an XHR request. So while the patch fixes the case you made, if shouldn't apply to the original problem, as it uses
|
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey! Thank you once again for your effort!
I wanted to give a feedback / suggestions on how to make the project more friendly to early contributors (I myself try to adopt the project, and I'm trying to contribute as well.)
I've found probable bug in the way the form values are handled for buttons.
Long story short, this
would not submit
action="submit-btn-clicked"
in the form.Now I wanted to contribute, by adding a test that would reproduce the issue.
I've found following hurdles in doing so:
I'd expect that in the top level there are some references to integration / E2E tests that are usually a good place to start - if I could just add some subcase that would showcase my issue, and only then get deeper into the code - that would be great!
I hope this makes it easier to adapt the project and encourage contributors. I think it can bring a great value to go ecosystem.
Best
Arek
Beta Was this translation helpful? Give feedback.
All reactions