You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by "Tobias Wehrum (JIRA)" <de...@tapestry.apache.org> on 2008/08/25 11:45:44 UTC
[jira] Created: (TAPESTRY-2619) Event Handler adds a new JSONObject
to my JSONObject return
Event Handler adds a new JSONObject to my JSONObject return
-----------------------------------------------------------
Key: TAPESTRY-2619
URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
Project: Tapestry
Issue Type: Bug
Affects Versions: 5.0.14
Reporter: Tobias Wehrum
Priority: Critical
When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Commented: (TAPESTRY-2619) Event Handler adds a new
JSONObject to my JSONObject return
Posted by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625943#action_12625943 ]
Howard M. Lewis Ship commented on TAPESTRY-2619:
------------------------------------------------
Yep, that's the issue all right.
Because its going through a form.
The event doesn't get cancelled properly because of how the Form, the event handler method, its return value, and the @Ajax ComponentEventResultProcessor interact.
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Priority: Critical
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Commented: (TAPESTRY-2619) Event Handler adds a new
JSONObject to my JSONObject return
Posted by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625429#action_12625429 ]
Howard M. Lewis Ship commented on TAPESTRY-2619:
------------------------------------------------
I vaguely remember seeing that bug before and thought it was fixed.
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Priority: Critical
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Updated: (TAPESTRY-2619) Event Handler adds a new JSONObject
to my JSONObject return
Posted by "Tobias Wehrum (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tobias Wehrum updated TAPESTRY-2619:
------------------------------------
Attachment: example.rar
Example showing said behavoir
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Priority: Critical
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Commented: (TAPESTRY-2619) Event Handler adds a new
JSONObject to my JSONObject return
Posted by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625933#action_12625933 ]
Howard M. Lewis Ship commented on TAPESTRY-2619:
------------------------------------------------
The difference could be between a normal Ajax request and a form submission.
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Priority: Critical
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Closed: (TAPESTRY-2619) Event Handler adds a new JSONObject
to my JSONObject return
Posted by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Howard M. Lewis Ship closed TAPESTRY-2619.
------------------------------------------
Resolution: Fixed
Fix Version/s: 5.0.15
Assignee: Howard M. Lewis Ship
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Assignee: Howard M. Lewis Ship
> Priority: Critical
> Fix For: 5.0.15
>
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org
[jira] Commented: (TAPESTRY-2619) Event Handler adds a new
JSONObject to my JSONObject return
Posted by "Howard M. Lewis Ship (JIRA)" <de...@tapestry.apache.org>.
[ https://issues.apache.org/jira/browse/TAPESTRY-2619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12625932#action_12625932 ]
Howard M. Lewis Ship commented on TAPESTRY-2619:
------------------------------------------------
I'm having trouble reproducing this in 5.0.15-SNAPSHOT.
For example, the DatePicker does exactly this:
JSONObject onParse()
{
String input = request.getParameter(INPUT_PARAMETER);
JSONObject response = new JSONObject();
try
{
Date date = format.parse(input);
response.put(RESULT, date.toString());
}
catch (ParseException ex)
{
response.put(ERROR, ex.getMessage());
}
return response;
}
And, I've verified using FireBug, it works correctly.
> Event Handler adds a new JSONObject to my JSONObject return
> -----------------------------------------------------------
>
> Key: TAPESTRY-2619
> URL: https://issues.apache.org/jira/browse/TAPESTRY-2619
> Project: Tapestry
> Issue Type: Bug
> Affects Versions: 5.0.14
> Reporter: Tobias Wehrum
> Priority: Critical
> Attachments: example.rar
>
>
> When trying to create an AJAX handler to process a form submit, instead of returning my JSONObject simply as " {"somekey":"somevalue"} ", it returns " {"somekey":"somevalue"}{} ", which is clearly an invalid JSON object. The {} seems to be added at org.apache.tapestry5.internal.services.AjaxComponentEventRequestHandler:108.
> See attached file for an example project showing this behavior.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org