Discussion:
Debug GWT plugin
Robert Mitwicki
2015-11-27 09:43:13 UTC
Permalink
Hi,

I am trying to debug gwt plugin (reviewers plugins ) but I am having some
problems with that.
According to the documentation I used python script to generate staff for
eclipse.
Then I created fresh workspace imported gerrit + reviewers plugin into the
workspace.
Duplicated the lunch configuration 'gerrit_gwt_debug' and added my module
which now looks like this:

-noprecompile -src ${resource_loc:/gerrit} -workDir
${resource_loc:/gerrit}/buck-out/gen/gerrit-gwtui
com.google.gerrit.GerritGwtUI
com.googlesource.gerrit.plugins.reviewers.ReviewersForm -- --console-log
--show-stack-trace -d ${resource_loc:/gerrit}/../gerrit_testsite


When I am trying to run it I am getting error:


Loading Java files in com.google.gerrit.GerritGwtUI.
Ignored 5 units with compilation errors in first pass.
Compile with -strict or with -logLevel set to TRACE or DEBUG to see all
errors.
Module setup completed in 16211 ms Loading inherited module
'com.googlesource.gerrit.plugins.reviewers.ReviewersForm'
[ERROR] Unable to find
'com/googlesource/gerrit/plugins/reviewers/ReviewersForm.gwt.xml' on your
classpath; could be a typo, or maybe you forgot to include a classpath
entry for source?


So editing the launch config again and in the Classpath tab -> Add Projects
... and select reviewers project.
Then when I am trying to run it again I am getting:

Loading Java files in com.google.gerrit.GerritGwtUI.
Ignored 5 units with compilation errors in first pass.
Compile with -strict or with -logLevel set to TRACE or DEBUG to see all
errors.
Module setup completed in 15665 ms
Loading Java files in
com.googlesource.gerrit.plugins.reviewers.ReviewersForm.
Ignored 184 units with compilation errors in first pass.
Compile with -strict or with -logLevel set to TRACE or DEBUG to see all
errors.
Finding entry point classes
[ERROR] Hint: Check that the type name
'com.googlesource.gerrit.plugins.reviewers.client.ReviewersPlugin' is
really what you meant
[ERROR] Hint: Check that your classpath includes all required source roots


Any idea what could be wrong? Did I missed something?

Thanks a lot in advance
best regards
Robert
--
--
To unsubscribe, email repo-discuss+***@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Ostrovsky
2015-11-27 14:10:57 UTC
Permalink
Post by Robert Mitwicki
Hi,
I am trying to debug gwt plugin (reviewers plugins ) but I am having some
problems with that.
According to the documentation I used python script to generate staff for
eclipse.
Then I created fresh workspace imported gerrit + reviewers plugin into the
workspace.
Duplicated the lunch configuration 'gerrit_gwt_debug' and added my module
-noprecompile -src ${resource_loc:/gerrit} -workDir
${resource_loc:/gerrit}/buck-out/gen/gerrit-gwtui
com.google.gerrit.GerritGwtUI
com.googlesource.gerrit.plugins.reviewers.ReviewersForm -- --console-log
--show-stack-trace -d ${resource_loc:/gerrit}/../gerrit_testsite
[...]
Any idea what could be wrong? Did I missed something?
You missed these lines in the documentation: [1]. You need something like:

-src ${resource_loc:/gerrit}/plugins/reviewers/src/main/java

*
[1] https://github.com/gerrit-review/gerrit/blob/master/Documentation/dev-eclipse.txt#L112-L126
--
--
To unsubscribe, email repo-discuss+***@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Robert Mitwicki
2015-12-01 13:58:52 UTC
Permalink
Post by David Ostrovsky
-src ${resource_loc:/gerrit}/plugins/reviewers/src/main/java
* [1]
https://github.com/gerrit-review/gerrit/blob/master/Documentation/dev-eclipse.txt#L112-L126
In deed I missed that, thanks a lot for pointing it out.
But even after adding that I am still having some issues. So my launcher
looks right now like this:

-noprecompile -workDir ${resource_loc:/gerrit}/buck-out/gen/gerrit-gwtui
-src ${resource_loc:/gerrit}/plugins/cookbook-plugin/src/main/java -src
${resource_loc:/gerrit} com.google.gerrit.GerritGwtUI
com.googlesource.gerrit.plugins.cookbook.HelloForm -- --console-log
--show-stack-trace -d ${resource_loc:/gerrit}/../gerrit_testsite

And the issue:

Tracing compile failure path for type
'com.googlesource.gerrit.plugins.cookbook.client.CookBookPlugin'
[ERROR] Errors in
'file:/mnt/Storage1/Workspace/gerrit/source/gerrit/plugins/cookbook-plugin/src/main/java/com/googlesource/gerrit/plugins/cookbook/client/CookBookPlugin.java'

[ERROR] Line 23: No source code is available for type
com.google.gerrit.plugin.client.Plugin; did you forget to inherit a
required module?
[ERROR] Line 20: No source code is available for type
com.google.gerrit.plugin.client.PluginEntryPoint; did you forget to inherit
a required module?
[ERROR] Hint: Check that the type name
'com.googlesource.gerrit.plugins.cookbook.client.CookBookPlugin' is really
what you meant
[ERROR] Hint: Check that your classpath includes all required source roots


I tried that on clean eclipse setup according to the documentation with
branch stable-2.11.
Any hint?

Thanks a lot
best regards
Robert
--
--
To unsubscribe, email repo-discuss+***@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
David Ostrovsky
2015-12-01 20:37:41 UTC
Permalink
Post by Robert Mitwicki
Post by David Ostrovsky
-src ${resource_loc:/gerrit}/plugins/reviewers/src/main/java
* [1]
https://github.com/gerrit-review/gerrit/blob/master/Documentation/dev-eclipse.txt#L112-L126
In deed I missed that, thanks a lot for pointing it out.
But even after adding that I am still having some issues. So my launcher
-noprecompile -workDir ${resource_loc:/gerrit}/buck-out/gen/gerrit-gwtui
-src ${resource_loc:/gerrit}/plugins/cookbook-plugin/src/main/java -src
${resource_loc:/gerrit} com.google.gerrit.GerritGwtUI
com.googlesource.gerrit.plugins.cookbook.HelloForm -- --console-log
--show-stack-trace -d ${resource_loc:/gerrit}/../gerrit_testsite
Tracing compile failure path for type
'com.googlesource.gerrit.plugins.cookbook.client.CookBookPlugin'
[ERROR] Errors in
'file:/mnt/Storage1/Workspace/gerrit/source/gerrit/plugins/cookbook-plugin/src/main/java/com/googlesource/gerrit/plugins/cookbook/client/CookBookPlugin.java'
[ERROR] Line 23: No source code is available for type
com.google.gerrit.plugin.client.Plugin; did you forget to inherit a
required module?
[ERROR] Line 20: No source code is available for type
com.google.gerrit.plugin.client.PluginEntryPoint; did you forget to inherit
a required module?
[ERROR] Hint: Check that the type name
'com.googlesource.gerrit.plugins.cookbook.client.CookBookPlugin' is really
what you meant
[ERROR] Hint: Check that your classpath includes all required source roots
I tried that on clean eclipse setup according to the documentation with
branch stable-2.11.
Any hint?
You missed this change: [1]. May be it was not the best thing how to
document
SDM session for plugins, but the idea was to only mention extra parameters,
and skip already included in tools/eclipse/gerrit_gwt_debug.launch. Just add
this line and it should work:

-src ${resource_loc:/gerrit}/gerrit-plugin-gwtui/src/main/java

* [1] https://gerrit-review.googlesource.com/68971
--
--
To unsubscribe, email repo-discuss+***@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Robert Mitwicki
2015-12-02 07:24:05 UTC
Permalink
Post by David Ostrovsky
You missed this change: [1]. May be it was not the best thing how to
document
SDM session for plugins, but the idea was to only mention extra parameters,
and skip already included in tools/eclipse/gerrit_gwt_debug.launch. Just add
-src ${resource_loc:/gerrit}/gerrit-plugin-gwtui/src/main/java
* [1] https://gerrit-review.googlesource.com/68971
Thanks a lot! This did the job. Now is working.
Best regards
Robert
--
--
To unsubscribe, email repo-discuss+***@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss+***@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...