News for hackers. Stuff that matters.
Re:How ‘open’ should your open source be? by FartyMcFarter on Sunday May 14, 2023 @08:51AM (#35937575)
Complex projects need to have extensive tests if they are to accept contributions from everyone. I don't mean just unit tests - also extensive integration tests run with sanitizers and static analyzers as well. Without this kind of tests, you accept a significant probability of frequent bugs popping up (especially if you allow contributions from people unfamiliar with the code).

It's perfectly fine for authors to decide they don't want to follow this route and simply disallow most contributions (instead of investing into the test infrastructure required to enable them).

Re:How ‘open’ should your open source be? by josephg on Sunday May 14, 2023 @10:32AM (#35938301)
Yep. I have a strict policy of requiring unit tests to be added before I merge any new feature in a pull request. For small features, all the contributor needs to do is add a couple of test functions to the existing testing infrastructure, but I find it still drops the number of PRs by about 5x or something. It’s really remarkable. And I haven’t found a downside to this policy yet.
Re:How ‘open’ should your open source be? by MoreQARespect on Sunday May 14, 2023 @10:52AM (#35938449)
I have this too, but with a specification-by-example integration test with a brief explanation that autogenerates readable "step by step" markdown how-to docs.

The idea being that new features should be fully tested and clearly documented before being merged - ideally with a minimum of overhead. Because if you defer either, it likely won't get done.

Re:How ‘open’ should your open source be? by jmathai on Sunday May 14, 2023 @11:06AM (#35938547)
At some size, a project grows beyond the scope of what one person can do.

Until then it’s possible that taking contributions is more work that the author doing it themselves.

In any case, extensive test coverage is a the only way I think you can take contributions for even a medium size project.

I have a o(10k) loc project that takes contributions. The contributions are more for community building than anything else. I evaluate pull requests based on code quality and if the tests pass - I don’t ever manually test it.

It’s a lot of work to do even just that when the project falls off my priority list.

Re:How ‘open’ should your open source be? by johannes1234321 on Sunday May 14, 2023 @12:45PM (#35939271)
It's not about testing only. All future features have to be vetted against the design decisions made in those contributions. Maybe the primary maintainer, after accepting a contribution, has to mind consistency with a feature, they now have to make Tain they don't care about from the start and is in the way for a feature they'd like.

Taking contributions has long-term cost.

Re:How ‘open’ should your open source be? by cxr on Sunday May 14, 2023 @04:55PM (#35941286)
I don't understand how this is supposed to be a response to what I wrote.
Re:How ‘open’ should your open source be? by FartyMcFarter on Thursday May 18, 2023 @06:11AM (#35986029)
I was agreeing with you and expanding on what you said about reward vs investment.