tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: suggested pkglint change: error on missing comment for patch



In article <20090104091506.GA11260%arresum.veego.de@localhost> Bernd wrote:
: On Sun, Jan 04, 2009 at 02:47:51AM +0000, David Holland wrote:
: > On Sat, Jan 03, 2009 at 07:39:28PM +0100, Thomas Klausner wrote:
: >  > I'd like pkglint to report errors from now on if a patch doesn't have
: >  > a comment.
: >  > 
: >  > The comment should be one of:
: >  > . upstream bugtracker link for bug report associated with this patch
: >  > . upstream scm link, if patch is from (newer) upstream
: >  > . comment explaining why this patch is needed for portability but not
: >  >   fed upstream
: > 
: > While this is in general a good idea, I have some reservations.
: > 
: > Most packages probably don't have formal upstream bugtrackers. So I
: > don't think you can enforce anything more than "some text"; maybe
: > that's enough to accomplish something useful, maybe not.
: > 
: > Plus as things stand you need one comment per patch hunk, not one
: > comment per file, because unrelated changes to the same source file go
: > into the same patch file.
: > 
: > Also, it's probably better not to introduce any new barriers to fixing
: > broken packages.
: [..]

: Having no comment what this patch should fix makes it nearly impossible
: for some patches to update a package. A cvs log doesn't reveal why    
: it was done, because it was either added in the first import or part
: of a normal update without beeing mentioned.
: So at least add a comment why this patch has to be modified.

  Exactly.

  Also, add a comment mentioning the status with regard to sending the
patch upstream.  Could basically be one of the following three:

(1) pkgsrc only patch, not needed upstream (e.g. adapt to our build structure)
(2) sent (including bug tracker id if available)
(3) not yet sent

  So the additional barrier (add a one line comment) is minimal, and
we at least know which patches still need to be sent.  We should
probably formalize (3) above so we can grep for it.

                                   yours,
                                   dillo


Home | Main Index | Thread Index | Old Index