recently I worked on a Grails 2.4.x project in GGTS 3.6. After some coding, refactoring and reconfiguration, debugging stopped working with the following error message:
Error | /Users/jolo/Documents/workspace-ggts-3.6.0.M1/FeedHarvesterGPars does not appear to be part of a Grails application. The following commands are supported outside of a project: add-proxy clear-proxy create-app create-multi-project-build create-plugin help install-app-templates list-plugins package-plugin plugin-info remove-proxy set-proxy |Run 'grails help' for a complete list of available scripts.
The weird thing was, that grails run-app still worked, while only debugging wasn’t possible anymore.
In a first attempt, I did the standard routines, deleted the local caches (e.g. rm -rf .grails) and run the typical grails commands:
grails clean grails compile grails refresh-dependencies
With the result, that
was still successful, but
grails run-app -debug-fork
failed again, with the error message above.
With that kind of error message, it is almost impossible to track down the root cause. Especially when grails run-app works, and grails run-app -debug does not. These are the moments I dislike GGTS/Grails and all of its magic.
After I lost a reasonable amount of my precious time with guessing what the heck is going on, the problem was caused by a pull of the project from the local GGTS repository to a new local git repository!
To solve the issue, do in GGTS:
- choose Run -> Debug Configurations
- search the Grails section,
- mark the corresponding configuration and
- delete it with a right mouse click.
So be warned, if you move your project to a local git repository!