Re: Can't debug client code from Eclipse

2010-04-06 Thread Rajeev Dayal
Glad its working. Do you mind filing an issue for this?

On Tue, Apr 6, 2010 at 12:42 PM, Dan Dumont  wrote:

> It was a scoping problem.I needed to use a closure in the native js
> method to wrap the callback, because even though passing the function ref
> works in js, to run in java it needs the context.
>
> It would be cool if the documentation explicitly called that out because i
> didn't realize gwt would barf like that in developer mode.  It does make
> sense now though.
>
> On Tue, Apr 6, 2010 at 10:47 AM, Rajeev Dayal  wrote:
>
>> Hi,
>>
>> Are you sure the callback is not firing in development mode, or is the
>> breakpoint not being hit? If the breakpoint is not being hit, you may be
>> running into this issue (if you're using hotswap):
>>
>> http://code.google.com/p/google-web-toolkit/issues/detail?id=4704
>>
>> If you're not actually getting the callback to fire in development mode,
>> can you paste a code snippet that shows what you're doing?
>>
>>
>> Thanks,
>> Rajeev
>>
>>
>> On Fri, Apr 2, 2010 at 5:07 PM, Dan  wrote:
>>
>>> I'm having a similar problem though the only place breakpoints don't
>>> seem to work is in my AsyncCallback.
>>>
>>> I see no errors in firebug or anywhere in eclipse.
>>>
>>> The method that accepts the callback is a native js method.   the js
>>> calls the callback onSuccess.
>>> With compiled code, I can see this actually works, but running in
>>> development mode, i cannot get the callback to fire at all.
>>>
>>> please advise.
>>>
>>> On Mar 3, 12:01 pm, Rajeev Dayal  wrote:
>>> > Glad you got it working. If you wouldn't mind, could you file a bug for
>>> > this? Provide details about your Eclipse version, JDK version, and OS.
>>> >
>>> >
>>> >
>>> > On Tue, Mar 2, 2010 at 6:17 PM, urbanus  wrote:
>>> > > On Feb 10, 2:53 am, Rajeev Dayal  wrote:
>>> > > > Try upgrading your JDK and see if you still experience the problem.
>>> >
>>> > > Actually I found the problem.  I was setting the breakpoint on the
>>> > > method definition line, i.e.:
>>> >
>>> > > public void onSuccess(String result) {
>>> >
>>> > > Those breakpoints never hit.  If I place breakpoints on any lines
>>> > > *within* that method, they hit just fine.
>>> >
>>> > > Note that under normal circumstances if you put a breakpoint on a
>>> > > method line, execution will break at the immediately following line.
>>> > > It seems that client-side asynchronous GWT code doesn't behave that
>>> > > way.  I wouldn't consider this to be a serious issue: just something
>>> > > to be aware of.
>>> >
>>> > > Thanks for your advice.
>>> >
>>> > > Dave
>>> >
>>> > > --
>>> > > You received this message because you are subscribed to the Google
>>> Groups
>>> > > "Google Web Toolkit" group.
>>> > > To post to this group, send email to
>>> google-web-tool...@googlegroups.com.
>>> > > To unsubscribe from this group, send email to
>>> > > google-web-toolkit+unsubscr...@googlegroups.com>> cr...@googlegroups.com>
>>> > > .
>>> > > For more options, visit this group at
>>> > >http://groups.google.com/group/google-web-toolkit?hl=en.
>>>
>>> --
>>> You received this message because you are subscribed to the Google Groups
>>> "Google Web Toolkit" group.
>>> To post to this group, send email to google-web-toolkit@googlegroups.com
>>> .
>>> To unsubscribe from this group, send email to
>>> google-web-toolkit+unsubscr...@googlegroups.com
>>> .
>>> For more options, visit this group at
>>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>>
>>>
>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Google Web Toolkit" group.
>> To post to this group, send email to google-web-tool...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> google-web-toolkit+unsubscr...@googlegroups.com
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-04-06 Thread Dan Dumont
It was a scoping problem.I needed to use a closure in the native js
method to wrap the callback, because even though passing the function ref
works in js, to run in java it needs the context.

It would be cool if the documentation explicitly called that out because i
didn't realize gwt would barf like that in developer mode.  It does make
sense now though.

On Tue, Apr 6, 2010 at 10:47 AM, Rajeev Dayal  wrote:

> Hi,
>
> Are you sure the callback is not firing in development mode, or is the
> breakpoint not being hit? If the breakpoint is not being hit, you may be
> running into this issue (if you're using hotswap):
>
> http://code.google.com/p/google-web-toolkit/issues/detail?id=4704
>
> If you're not actually getting the callback to fire in development mode,
> can you paste a code snippet that shows what you're doing?
>
>
> Thanks,
> Rajeev
>
>
> On Fri, Apr 2, 2010 at 5:07 PM, Dan  wrote:
>
>> I'm having a similar problem though the only place breakpoints don't
>> seem to work is in my AsyncCallback.
>>
>> I see no errors in firebug or anywhere in eclipse.
>>
>> The method that accepts the callback is a native js method.   the js
>> calls the callback onSuccess.
>> With compiled code, I can see this actually works, but running in
>> development mode, i cannot get the callback to fire at all.
>>
>> please advise.
>>
>> On Mar 3, 12:01 pm, Rajeev Dayal  wrote:
>> > Glad you got it working. If you wouldn't mind, could you file a bug for
>> > this? Provide details about your Eclipse version, JDK version, and OS.
>> >
>> >
>> >
>> > On Tue, Mar 2, 2010 at 6:17 PM, urbanus  wrote:
>> > > On Feb 10, 2:53 am, Rajeev Dayal  wrote:
>> > > > Try upgrading your JDK and see if you still experience the problem.
>> >
>> > > Actually I found the problem.  I was setting the breakpoint on the
>> > > method definition line, i.e.:
>> >
>> > > public void onSuccess(String result) {
>> >
>> > > Those breakpoints never hit.  If I place breakpoints on any lines
>> > > *within* that method, they hit just fine.
>> >
>> > > Note that under normal circumstances if you put a breakpoint on a
>> > > method line, execution will break at the immediately following line.
>> > > It seems that client-side asynchronous GWT code doesn't behave that
>> > > way.  I wouldn't consider this to be a serious issue: just something
>> > > to be aware of.
>> >
>> > > Thanks for your advice.
>> >
>> > > Dave
>> >
>> > > --
>> > > You received this message because you are subscribed to the Google
>> Groups
>> > > "Google Web Toolkit" group.
>> > > To post to this group, send email to
>> google-web-tool...@googlegroups.com.
>> > > To unsubscribe from this group, send email to
>> > > google-web-toolkit+unsubscr...@googlegroups.com> cr...@googlegroups.com>
>> > > .
>> > > For more options, visit this group at
>> > >http://groups.google.com/group/google-web-toolkit?hl=en.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Google Web Toolkit" group.
>> To post to this group, send email to google-web-tool...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> google-web-toolkit+unsubscr...@googlegroups.com
>> .
>> For more options, visit this group at
>> http://groups.google.com/group/google-web-toolkit?hl=en.
>>
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-04-06 Thread Rajeev Dayal
Hi,

Are you sure the callback is not firing in development mode, or is the
breakpoint not being hit? If the breakpoint is not being hit, you may be
running into this issue (if you're using hotswap):

http://code.google.com/p/google-web-toolkit/issues/detail?id=4704

If you're not actually getting the callback to fire in development mode, can
you paste a code snippet that shows what you're doing?


Thanks,
Rajeev

On Fri, Apr 2, 2010 at 5:07 PM, Dan  wrote:

> I'm having a similar problem though the only place breakpoints don't
> seem to work is in my AsyncCallback.
>
> I see no errors in firebug or anywhere in eclipse.
>
> The method that accepts the callback is a native js method.   the js
> calls the callback onSuccess.
> With compiled code, I can see this actually works, but running in
> development mode, i cannot get the callback to fire at all.
>
> please advise.
>
> On Mar 3, 12:01 pm, Rajeev Dayal  wrote:
> > Glad you got it working. If you wouldn't mind, could you file a bug for
> > this? Provide details about your Eclipse version, JDK version, and OS.
> >
> >
> >
> > On Tue, Mar 2, 2010 at 6:17 PM, urbanus  wrote:
> > > On Feb 10, 2:53 am, Rajeev Dayal  wrote:
> > > > Try upgrading your JDK and see if you still experience the problem.
> >
> > > Actually I found the problem.  I was setting the breakpoint on the
> > > method definition line, i.e.:
> >
> > > public void onSuccess(String result) {
> >
> > > Those breakpoints never hit.  If I place breakpoints on any lines
> > > *within* that method, they hit just fine.
> >
> > > Note that under normal circumstances if you put a breakpoint on a
> > > method line, execution will break at the immediately following line.
> > > It seems that client-side asynchronous GWT code doesn't behave that
> > > way.  I wouldn't consider this to be a serious issue: just something
> > > to be aware of.
> >
> > > Thanks for your advice.
> >
> > > Dave
> >
> > > --
> > > You received this message because you are subscribed to the Google
> Groups
> > > "Google Web Toolkit" group.
> > > To post to this group, send email to
> google-web-tool...@googlegroups.com.
> > > To unsubscribe from this group, send email to
> > > google-web-toolkit+unsubscr...@googlegroups.com cr...@googlegroups.com>
> > > .
> > > For more options, visit this group at
> > >http://groups.google.com/group/google-web-toolkit?hl=en.
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-04-03 Thread Dan
I'm having a similar problem though the only place breakpoints don't
seem to work is in my AsyncCallback.

I see no errors in firebug or anywhere in eclipse.

The method that accepts the callback is a native js method.   the js
calls the callback onSuccess.
With compiled code, I can see this actually works, but running in
development mode, i cannot get the callback to fire at all.

please advise.

On Mar 3, 12:01 pm, Rajeev Dayal  wrote:
> Glad you got it working. If you wouldn't mind, could you file a bug for
> this? Provide details about your Eclipse version, JDK version, and OS.
>
>
>
> On Tue, Mar 2, 2010 at 6:17 PM, urbanus  wrote:
> > On Feb 10, 2:53 am, Rajeev Dayal  wrote:
> > > Try upgrading your JDK and see if you still experience the problem.
>
> > Actually I found the problem.  I was setting the breakpoint on the
> > method definition line, i.e.:
>
> > public void onSuccess(String result) {
>
> > Those breakpoints never hit.  If I place breakpoints on any lines
> > *within* that method, they hit just fine.
>
> > Note that under normal circumstances if you put a breakpoint on a
> > method line, execution will break at the immediately following line.
> > It seems that client-side asynchronous GWT code doesn't behave that
> > way.  I wouldn't consider this to be a serious issue: just something
> > to be aware of.
>
> > Thanks for your advice.
>
> > Dave
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Google Web Toolkit" group.
> > To post to this group, send email to google-web-tool...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > google-web-toolkit+unsubscr...@googlegroups.com > cr...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/google-web-toolkit?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-03-03 Thread Rajeev Dayal
Glad you got it working. If you wouldn't mind, could you file a bug for
this? Provide details about your Eclipse version, JDK version, and OS.

On Tue, Mar 2, 2010 at 6:17 PM, urbanus  wrote:

> On Feb 10, 2:53 am, Rajeev Dayal  wrote:
> > Try upgrading your JDK and see if you still experience the problem.
>
> Actually I found the problem.  I was setting the breakpoint on the
> method definition line, i.e.:
>
> public void onSuccess(String result) {
>
> Those breakpoints never hit.  If I place breakpoints on any lines
> *within* that method, they hit just fine.
>
> Note that under normal circumstances if you put a breakpoint on a
> method line, execution will break at the immediately following line.
> It seems that client-side asynchronous GWT code doesn't behave that
> way.  I wouldn't consider this to be a serious issue: just something
> to be aware of.
>
> Thanks for your advice.
>
>
> Dave
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-03-02 Thread urbanus
On Feb 10, 2:53 am, Rajeev Dayal  wrote:
> Try upgrading your JDK and see if you still experience the problem.

Actually I found the problem.  I was setting the breakpoint on the
method definition line, i.e.:

public void onSuccess(String result) {

Those breakpoints never hit.  If I place breakpoints on any lines
*within* that method, they hit just fine.

Note that under normal circumstances if you put a breakpoint on a
method line, execution will break at the immediately following line.
It seems that client-side asynchronous GWT code doesn't behave that
way.  I wouldn't consider this to be a serious issue: just something
to be aware of.

Thanks for your advice.


Dave

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-02-09 Thread Rajeev Dayal
Actually, setting a breakpoint in async callback code should definitely
work. In the sample, I set a breakpoint in the "onSuccess" method of the RPC
callback, and it breaks there.

Try upgrading your JDK and see if you still experience the problem.



On Sat, Feb 6, 2010 at 7:28 AM, urbanus  wrote:

> > What happens if you set the breakpoint in the onModuleLoad() method
> within
> > your entry point?
>
> Thanks for your advice.  I found that breakpoints work in the
> onModuleLoad() method, but not in any asynchronous callback code.
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-02-06 Thread urbanus
> What happens if you set the breakpoint in the onModuleLoad() method within
> your entry point?

Thanks for your advice.  I found that breakpoints work in the
onModuleLoad() method, but not in any asynchronous callback code.


-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.



Re: Can't debug client code from Eclipse

2010-02-05 Thread Rajeev Dayal
There have been problems with versions of JDK 1.6.0_X, where X is between
0-15, where breakpoints are not hit when debugging. However, it is odd that
your server breakpoints consistently work, but your client breakpoints do
not; in those cases where the JDK has been the source of the problem, the
breakpoints don't work at all (on either side).

What is the URL that you're pasting into your browser? Can you provide a
screenshot of what the development mode view looks like (I want to make sure
that there is an entry for the web browser)?

What happens if you set the breakpoint in the onModuleLoad() method within
your entry point?


On Thu, Feb 4, 2010 at 11:16 PM, urbanus  wrote:

> Debugging a default "GreetingService" application from Eclipse works
> fine -- including breakpoints in the server code -- but breakpoints in
> the client code aren't triggered.
>
> I installed GWT 2.0.1, plus the GWT 2.0.1 plugin for Eclipse.  I
> generated a new, default project from the command-line, added it as an
> Eclipse project, went to "Properties" and set the "Web Toolkit" to
> 2.0.1.  I can debug it as a "Web Application" and it appears on the
> new "Development Mode" panel in Eclipse.
>
> I pasted the URL into Firefox and was prompted to install the plugin
> -- OK.  Restarted Firefox, the plugin seems to be talking to Eclipse
> (if I stop Development Mode in Eclipse, the page is greyed out and
> "GWT Code Server Disconnected" is displayed).
>
> Debugging works fine in the *server* code: I can set breakpoints in
> GreetingServiceImpl.java and step, etc.  But if I set a breakpoint in
> the *client* code (such as the sendNameToServer() method) the code
> runs but the breakpoints are never hit.
>
> System: Eclipse 3.5, Fedora 11, Java "1.6.0_0" "build 14.0-b16".
>
>
> Thanks,
> Dave
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To post to this group, send email to google-web-tool...@googlegroups.com.
> To unsubscribe from this group, send email to
> google-web-toolkit+unsubscr...@googlegroups.com
> .
> For more options, visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-tool...@googlegroups.com.
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.