metamodel-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kaspersorensen <...@git.apache.org>
Subject [GitHub] metamodel issue #156: Checkstyle integration
Date Thu, 31 Aug 2017 16:26:24 GMT
Github user kaspersorensen commented on the issue:

    https://github.com/apache/metamodel/pull/156
  
    Or we could omit having any rules about imports? I mean, it's never in the imports section
that I find anything hard to compare when looking at diffs. So even if it goes forwards-and-backwards
all the time, I don't personally care much.
    
    Other rules that I can think of:
    
    * Requiring a license header is legally required, so can't be discussed really :-)
    * Enforcing the same indentation is something I really want checkstyle to enforce. Thumbs
up for automating that fully.
    * Requiring `final` is nice, but takes a lot of effort to retrofit into all the places
where it doesn't exist. I would also argue that it's less important in many places, e.g. test
code and such. For me it is a perfectly fine thing to just take on a code review basis.
    * Maximum argument count is an annoying type of check IMO. Especially when building immutable
classes that often take a lot of constructor arguments. And I like immutability much more
than checkstyle :-) So I would vote against such a check.
    * Method and class complexity rules I also dislike. I've seen too many cases where I felt
that it made the code more complex to split it into tons of private methods and stuff like
that. I would be fine with a warning or something like that, but essentially this comes down
to a human judgement call where we have to evaluate "is this method appropriate in complexity
to the issue it is solving".


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message