-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Module Component #19
Comments
As pointed at #1 (review). The method was not a good implementation, for it just instantiate the class in the release version of checkstyle, and that is meaningless. I haven't think out a way to load the class from file and meanwhile avoid conflicts by now. |
For the branch version of checkstyle, we only have the java source code. If we want to use the From other point of view, I think we have some other way to avoid loading the branch version file by now. Currently, our goal is to judge whether a class is a checkstyle module. And we have the hardcode map in |
According to https://github.com/checkstyle/checkstyle/blob/master/src/main/resources/com/puppycrawl/tools/checkstyle/configuration_1_3.dtd, we have
|
I advise against asking free form questions in issue as it will cloud main discussion. This sounds like it would be better in gitter or google groups.
See checkstyle/checkstyle#2726 .
Configuration can override module's message.
See https://github.com/checkstyle/checkstyle/blob/ce21086e087661553f3a774c38362327ee88996a/src/main/java/com/puppycrawl/tools/checkstyle/ConfigurationLoader.java#L255-L256 .
I describe it as the chicken and the egg scenario. https://en.wikipedia.org/wiki/Chicken_or_the_egg |
Our goal right now is if something is a module. Eventually, we will need more than modules. We will need to know properties, their types, and possibly their default values, tokens, messages, acceptable parent (TreeWalker or Checker), etc.
We should avoid asking for changes in main project if we can. I am not against it, but it should be close to a last resort. There has been talk about having some file in Checkstyle with all this information so 3rd party plugins could make use of it for their own purposes.
Instead of installing, we would have to attach PR Checkstyle JAR to classpath at runtime. We must also be sure we never need runtime information from multiple branches, like master.
Your close to the same path I am thinking. My thinking was: @Luolc @romani What is your opinion and preference on how we should get this data from these 3 ways? |
I think it is a good idea. |
@Luolc So we don't slow down development waiting on final decision, can we work around this by using a hard-coded list of modules (and possibly their packages) and a very simple POJO? Expansion of properties and such will be in Issue #5 . |
@rnveach Got it. I would refer to the hardcode map in |
Meanwhile, we need to add some more POJOs for the config generator(i.e. to represent element module, property). These POJOs would be in |
known meta-data requirements:
it is good to know, but lets implement all scenarios step by step. I would focus on 1-2 scenarios and make all component work on them and only after that grow implementation to detect new scenarios and generation of configs to cover.
if smth is going to be generated by tool in separate clone of repo - no need to be added to ".gitignore". |
for general question how to grab meta data from checkstyle ...... it might be better to inject into checkstyle repo some functionality(classes) to generate files. All attempts to predict what will be useful for all plugins/tools is hard to analyze for now. So lets keep that functionality out of main repo. |
@Luolc Please confirm. |
@rnveach Ya I think so. |
Issue is done |
Taken from #2
We need to identify the type of file to restrict to only modules (for now). In the future, we also need to identify if the module has new/removed properties as they will need to be included in the regression.
The text was updated successfully, but these errors were encountered: