-
Notifications
You must be signed in to change notification settings - Fork 54
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
Eclipse-CS does not refresh Checkstyle's External Resource list #465
Comments
The issue is the way Eclipse-CS runs Checkstyle.
Checker assumes the instance is always re-created on a run, so Modules are never set to reload files they have loaded after the first time. There is no check for an external resource has changed. There is just loading and destroying. For fixing this, it seems the only way may be to remove the cache on Checker in Eclipse-CS. I doubt Checkstyle will want to build a reloading lifestyle that it currently doesn't support and also technically can't use in it's own run lifecycle. While checker manages the external resources from the configuration and modules, it only does so to pass that information to the internal cache it manages when it is enabled. Maybe Eclipse-CS could make use of Checkstyle's caching module and use that to trigger a reset, but this isn't supported by RootModule's in general (which Eclipse-CS also doesn't support) and even if it was, it only supports giving a file string and does not provide any feedback that Eclipse-CS could really use. |
use ctrl-3, purge... to get rid of the eclipsecs cache. |
While working on #454 ,
I noticed when I changed the regular expression header file and did a clean build to re-run Checkstyle, Eclipse-CS kept using the old header file not matter what I did to try to get it to see the new one.
Checkstyle did not recognize the new header file changes until I re-saved the Configuration file, even though it had no more changes at that point.
It seems to me Eclipse-CS is caching something in memory to avoid having Checkstyle recreate the config in memory for each run and is causing issues when it doesn't see something as changed.
Checkstyle's External Resource Info: https://checkstyle.org/writingchecks.html#Declare_check.27s_external_resource_locations
The text was updated successfully, but these errors were encountered: