You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by "Jeremy F. Kassis" <jk...@jkassis.com> on 2007/01/11 09:50:45 UTC

XHR Exception Not Rendering to Browser

Hi again,

Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.

One of my XHR Ajax requests is returning an exception. Here is the XHR
response:

<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD
XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
<!ENTITY nbsp '&#160;'>
]>
<ajax-response><response id="bumpq:PageErrorPage" type="exception">
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<!-- Application: bumpq -->
<!-- Page: bumpq:PageErrorPage -->
<!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
<html>
<head>
<meta name="generator" content="Tapestry Application Framework, version
4.1.1" />
<meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
etc...

Problem is that this isn't popping up in Firefox. I'm actually getting a
Dojo Warning as follows:

WARNING: 12:42:47 AM: No ajax-response elements recieved.

Is there anything I've got to do to get XHR exceptions to popup like they
did in Tap 4.0.2?

Many thanks,
Jeremy
-- 
View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273738
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: XHR Exception Not Rendering to Browser

Posted by "Jeremy F. Kassis" <jk...@jkassis.com>.
Note for the update guide:

If you are using a custom Exception Page, make sure you check out the
changes made to the default exception page. In particular, your exception
page won't render correctly after an XHR request unless it renders with an
empty or null DOCTYPE.

Jeremy



Jeremy F. Kassis wrote:
> 
> OK. I think I've got this mostly figured out.
> 
> As it turned out, I had already configured the exceptionPageName using the
> tapestry.InfrastructureOverrides configuration point. When I was on Tap
> 4.0.2, it looked like this:
> 
> 	<contribution configuration-id="tapestry.InfrastructureOverrides">
> 		<property name="exceptionPageName" value="PageErrorPage'" />
> 	</contribution>
> 
> Also in Tap 4.0.2, I had done some funky stuff with
> PageSpecificationResolver and ComponentSpecificationResolver so that the
> application could resolve "PageErrorPage" without the library prefix.
> 
> When I went to Tap 4.1.1, I started moving everything toward a stock
> configuration, including the specification resolvers, to get the basics
> working right. So I also changed the tapestry.InfrastructureOverrides
> configuration point to look like this:
> 
> 	<contribution configuration-id="tapestry.InfrastructureOverrides">
> 		<property name="exceptionPageName" value="bumpq:PageErrorPage'" />
> 	</contribution>
> 
> At that point, the basic XHR capability was working, but the exceptions
> weren't coming up. So it seems that the core.js machinery has trouble
> recognizing and presenting error pages with a library prefix. Not a major
> deal, but perhaps a bug.
> 
> Many thanks for your help Jessek!
> 
> jeremy
> 
> 
> 
> 
> 
> 
> Jeremy F. Kassis wrote:
>> 
>> Hi Jessek!
>> 
>> This sounds right on.
>> 
>> Since a few service points, including DojoAjaxResponseBuilder get the
>> exceptionPageName from the Infrastructure service point, I tried to add a
>> contribution to the Infrastructure service point configuration as
>> follows:
>> 
>>   <contribution configuration-id="tapestry.Infrastructure">
>>     <property name="exceptionPageName" value="bumpq:Exception"/>
>>   </contribution>  
>> 
>> But Hivemind doesn't seem to like that. I'm getting this exception...
>> 
>> - Allocate exception for servlet bumpq
>> org.apache.hivemind.ApplicationRuntimeException: Error at
>> jar:file:/C:/Documents
>> %20and%20Settings/Jeremy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-IN
>> F/lib/tapestry-framework-4.1.1.jar!/META-INF/tapestry.error.xml, line
>> 110, colum
>> n 59: Infrastructure contribution for property 'exceptionPageName' (mode
>> 'null')
>>  conflicts with a prior contribution (at context:/WEB-INF/hivemodule.xml,
>> line 5
>> 2, column 65) and has been ignored.
>> [jar:file:/C:/Documents%20and%20Settings/Jer
>> emy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-INF/lib/tapestry-framew
>> ork-4.1.1.jar!/META-INF/tapestry.error.xml, line 110, column 59]
>>         at
>> org.apache.hivemind.impl.StrictErrorHandler.error(StrictErrorHandler.
>> java:39)
>>         at
>> org.apache.hivemind.impl.ErrorLogImpl.error(ErrorLogImpl.java:40)
>>         at
>> org.apache.tapestry.services.impl.InfrastructureImpl.buildMapFromCont
>> ributions(InfrastructureImpl.java:345)
>> 
>> Maybe it's just been a while since I went digging in hivemind, but I
>> thought this would work. I'll try overridding the DojoAjaxResponeBuilder
>> configuration just to see if it fixes the primary issue.
>> 
>> Jeremy
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> Jessek wrote:
>>> 
>>> The DojoAjaxResponseBuilder handler currently gets configured with the
>>> names of pages representing exceptions in order to detect an exception
>>> page and properly render the response so it is presented properly for
>>> ajax requests.
>>> 
>>> This configuration currently is done via hivemind :
>>> 
>>> http://tapestry.apache.org/tapestry4.1/tapestry-framework/hivedoc/service/tapestry.services.DojoAjaxResponseContributor.html
>>> 
>>> This could possibly be a bug on my part but I'm not sure? Either way
>>> your feedback would be greatly appreciated, hopefully I can use your
>>> issues to enhance the 4.0->4.1 upgrade guide.
>>> 
>>> On 1/11/07, Jeremy F. Kassis <jk...@jkassis.com> wrote:
>>>>
>>>> I just noticed something that seems related. The browser reports a
>>>> syntax
>>>> error in dojo/src/browser_debug.js:
>>>>
>>>> missing } after function body
>>>> browser_debug.js (line 17)
>>>> document.write("<script
>>>> type='text/javascript'>dojo.hostenv._global_omit_module_check =
>>>> false;</script>");dojo.hostenv._loadedUrisListStart = 0;if
>>>> (!willCallAgain)
>>>> {dj_eval = old_dj_eval;dojo.hostenv.loadUri =
>>>> dojo.hostenv.oldLoadUri;}}
>>>>
>>>> Since this file comes from the official Tapestry 4.1.1 release, I'd
>>>> assume
>>>> that others have experienced the same problem, but I don't see any
>>>> mention
>>>> of it in these forums.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> Jeremy F. Kassis wrote:
>>>> >
>>>> > Hi again,
>>>> >
>>>> > Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.
>>>> >
>>>> > One of my XHR Ajax requests is returning an exception. Here is the
>>>> XHR
>>>> > response:
>>>> >
>>>> > <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC
>>>> "-//W3C//DTD
>>>> > XHTML 1.0 Transitional//EN"
>>>> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
>>>> > <!ENTITY nbsp '&#160;'>
>>>> > ]>
>>>> > <ajax-response><response id="bumpq:PageErrorPage" type="exception">
>>>> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>>>> > "http://www.w3.org/TR/html4/loose.dtd">
>>>> >
>>>> > <!-- Application: bumpq -->
>>>> > <!-- Page: bumpq:PageErrorPage -->
>>>> > <!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
>>>> > <html>
>>>> > <head>
>>>> > <meta name="generator" content="Tapestry Application Framework,
>>>> version
>>>> > 4.1.1" />
>>>> > <meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
>>>> > etc...
>>>> >
>>>> > Problem is that this isn't popping up in Firefox. I'm actually
>>>> getting a
>>>> > Dojo Warning as follows:
>>>> >
>>>> > WARNING: 12:42:47 AM: No ajax-response elements recieved.
>>>> >
>>>> > Is there anything I've got to do to get XHR exceptions to popup like
>>>> they
>>>> > did in Tap 4.0.2?
>>>> >
>>>> > Many thanks,
>>>> > Jeremy
>>>> >
>>>>
>>>> --
>>>> View this message in context:
>>>> http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273906
>>>> Sent from the Tapestry - User mailing list archive at Nabble.com.
>>>>
>>>>
>>>> ---------------------------------------------------------------------
>>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>>
>>>>
>>> 
>>> 
>>> -- 
>>> Jesse Kuhnert
>>> Tapestry/Dojo team member/developer
>>> 
>>> Open source based consulting work centered around
>>> dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
>>> 
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>> 
>>> 
>>> 
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8286924
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: XHR Exception Not Rendering to Browser

Posted by "Jeremy F. Kassis" <jk...@jkassis.com>.
OK. I think I've got this mostly figured out.

As it turned out, I had already configured the exceptionPageName using the
tapestry.InfrastructureOverrides configuration point. When I was on Tap
4.0.2, it looked like this:

	<contribution configuration-id="tapestry.InfrastructureOverrides">
		<property name="exceptionPageName" value="PageErrorPage'" />
	</contribution>

Also in Tap 4.0.2, I had done some funky stuff with
PageSpecificationResolver and ComponentSpecificationResolver so that the
application could resolve "PageErrorPage" without the library prefix.

When I went to Tap 4.1.1, I started moving everything toward a stock
configuration, including the specification resolvers, to get the basics
working right. So I also changed the tapestry.InfrastructureOverrides
configuration point to look like this:

	<contribution configuration-id="tapestry.InfrastructureOverrides">
		<property name="exceptionPageName" value="bumpq:PageErrorPage'" />
	</contribution>

At that point, the basic XHR capability was working, but the exceptions
weren't coming up. So it seems that the core.js machinery has trouble
recognizing and presenting error pages with a library prefix. Not a major
deal, but perhaps a bug.

Many thanks for your help Jessek!

jeremy






Jeremy F. Kassis wrote:
> 
> Hi Jessek!
> 
> This sounds right on.
> 
> Since a few service points, including DojoAjaxResponseBuilder get the
> exceptionPageName from the Infrastructure service point, I tried to add a
> contribution to the Infrastructure service point configuration as follows:
> 
>   <contribution configuration-id="tapestry.Infrastructure">
>     <property name="exceptionPageName" value="bumpq:Exception"/>
>   </contribution>  
> 
> But Hivemind doesn't seem to like that. I'm getting this exception...
> 
> - Allocate exception for servlet bumpq
> org.apache.hivemind.ApplicationRuntimeException: Error at
> jar:file:/C:/Documents
> %20and%20Settings/Jeremy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-IN
> F/lib/tapestry-framework-4.1.1.jar!/META-INF/tapestry.error.xml, line 110,
> colum
> n 59: Infrastructure contribution for property 'exceptionPageName' (mode
> 'null')
>  conflicts with a prior contribution (at context:/WEB-INF/hivemodule.xml,
> line 5
> 2, column 65) and has been ignored.
> [jar:file:/C:/Documents%20and%20Settings/Jer
> emy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-INF/lib/tapestry-framew
> ork-4.1.1.jar!/META-INF/tapestry.error.xml, line 110, column 59]
>         at
> org.apache.hivemind.impl.StrictErrorHandler.error(StrictErrorHandler.
> java:39)
>         at
> org.apache.hivemind.impl.ErrorLogImpl.error(ErrorLogImpl.java:40)
>         at
> org.apache.tapestry.services.impl.InfrastructureImpl.buildMapFromCont
> ributions(InfrastructureImpl.java:345)
> 
> Maybe it's just been a while since I went digging in hivemind, but I
> thought this would work. I'll try overridding the DojoAjaxResponeBuilder
> configuration just to see if it fixes the primary issue.
> 
> Jeremy
> 
> 
> 
> 
> 
> 
> 
> Jessek wrote:
>> 
>> The DojoAjaxResponseBuilder handler currently gets configured with the
>> names of pages representing exceptions in order to detect an exception
>> page and properly render the response so it is presented properly for
>> ajax requests.
>> 
>> This configuration currently is done via hivemind :
>> 
>> http://tapestry.apache.org/tapestry4.1/tapestry-framework/hivedoc/service/tapestry.services.DojoAjaxResponseContributor.html
>> 
>> This could possibly be a bug on my part but I'm not sure? Either way
>> your feedback would be greatly appreciated, hopefully I can use your
>> issues to enhance the 4.0->4.1 upgrade guide.
>> 
>> On 1/11/07, Jeremy F. Kassis <jk...@jkassis.com> wrote:
>>>
>>> I just noticed something that seems related. The browser reports a
>>> syntax
>>> error in dojo/src/browser_debug.js:
>>>
>>> missing } after function body
>>> browser_debug.js (line 17)
>>> document.write("<script
>>> type='text/javascript'>dojo.hostenv._global_omit_module_check =
>>> false;</script>");dojo.hostenv._loadedUrisListStart = 0;if
>>> (!willCallAgain)
>>> {dj_eval = old_dj_eval;dojo.hostenv.loadUri = dojo.hostenv.oldLoadUri;}}
>>>
>>> Since this file comes from the official Tapestry 4.1.1 release, I'd
>>> assume
>>> that others have experienced the same problem, but I don't see any
>>> mention
>>> of it in these forums.
>>>
>>>
>>>
>>>
>>>
>>>
>>> Jeremy F. Kassis wrote:
>>> >
>>> > Hi again,
>>> >
>>> > Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.
>>> >
>>> > One of my XHR Ajax requests is returning an exception. Here is the XHR
>>> > response:
>>> >
>>> > <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC
>>> "-//W3C//DTD
>>> > XHTML 1.0 Transitional//EN"
>>> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
>>> > <!ENTITY nbsp '&#160;'>
>>> > ]>
>>> > <ajax-response><response id="bumpq:PageErrorPage" type="exception">
>>> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>>> > "http://www.w3.org/TR/html4/loose.dtd">
>>> >
>>> > <!-- Application: bumpq -->
>>> > <!-- Page: bumpq:PageErrorPage -->
>>> > <!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
>>> > <html>
>>> > <head>
>>> > <meta name="generator" content="Tapestry Application Framework,
>>> version
>>> > 4.1.1" />
>>> > <meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
>>> > etc...
>>> >
>>> > Problem is that this isn't popping up in Firefox. I'm actually getting
>>> a
>>> > Dojo Warning as follows:
>>> >
>>> > WARNING: 12:42:47 AM: No ajax-response elements recieved.
>>> >
>>> > Is there anything I've got to do to get XHR exceptions to popup like
>>> they
>>> > did in Tap 4.0.2?
>>> >
>>> > Many thanks,
>>> > Jeremy
>>> >
>>>
>>> --
>>> View this message in context:
>>> http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273906
>>> Sent from the Tapestry - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>>> For additional commands, e-mail: users-help@tapestry.apache.org
>>>
>>>
>> 
>> 
>> -- 
>> Jesse Kuhnert
>> Tapestry/Dojo team member/developer
>> 
>> Open source based consulting work centered around
>> dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
>> 
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>> 
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8286617
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: XHR Exception Not Rendering to Browser

Posted by "Jeremy F. Kassis" <jk...@jkassis.com>.
Hi Jessek!

This sounds right on.

Since a few service points, including DojoAjaxResponseBuilder get the
exceptionPageName from the Infrastructure service point, I tried to add a
contribution to the Infrastructure service point configuration as follows:

  <contribution configuration-id="tapestry.Infrastructure">
    <property name="exceptionPageName" value="bumpq:Exception"/>
  </contribution>  

But Hivemind doesn't seem to like that. I'm getting this exception...

- Allocate exception for servlet bumpq
org.apache.hivemind.ApplicationRuntimeException: Error at
jar:file:/C:/Documents
%20and%20Settings/Jeremy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-IN
F/lib/tapestry-framework-4.1.1.jar!/META-INF/tapestry.error.xml, line 110,
colum
n 59: Infrastructure contribution for property 'exceptionPageName' (mode
'null')
 conflicts with a prior contribution (at context:/WEB-INF/hivemodule.xml,
line 5
2, column 65) and has been ignored.
[jar:file:/C:/Documents%20and%20Settings/Jer
emy/My%20Documents/eclipse%20workspace/bumpq/context/WEB-INF/lib/tapestry-framew
ork-4.1.1.jar!/META-INF/tapestry.error.xml, line 110, column 59]
        at
org.apache.hivemind.impl.StrictErrorHandler.error(StrictErrorHandler.
java:39)
        at org.apache.hivemind.impl.ErrorLogImpl.error(ErrorLogImpl.java:40)
        at
org.apache.tapestry.services.impl.InfrastructureImpl.buildMapFromCont
ributions(InfrastructureImpl.java:345)

Maybe it's just been a while since I went digging in hivemind, but I thought
this would work. I'll try overridding the DojoAjaxResponeBuilder
configuration just to see if it fixes the primary issue.

Jeremy







Jessek wrote:
> 
> The DojoAjaxResponseBuilder handler currently gets configured with the
> names of pages representing exceptions in order to detect an exception
> page and properly render the response so it is presented properly for
> ajax requests.
> 
> This configuration currently is done via hivemind :
> 
> http://tapestry.apache.org/tapestry4.1/tapestry-framework/hivedoc/service/tapestry.services.DojoAjaxResponseContributor.html
> 
> This could possibly be a bug on my part but I'm not sure? Either way
> your feedback would be greatly appreciated, hopefully I can use your
> issues to enhance the 4.0->4.1 upgrade guide.
> 
> On 1/11/07, Jeremy F. Kassis <jk...@jkassis.com> wrote:
>>
>> I just noticed something that seems related. The browser reports a syntax
>> error in dojo/src/browser_debug.js:
>>
>> missing } after function body
>> browser_debug.js (line 17)
>> document.write("<script
>> type='text/javascript'>dojo.hostenv._global_omit_module_check =
>> false;</script>");dojo.hostenv._loadedUrisListStart = 0;if
>> (!willCallAgain)
>> {dj_eval = old_dj_eval;dojo.hostenv.loadUri = dojo.hostenv.oldLoadUri;}}
>>
>> Since this file comes from the official Tapestry 4.1.1 release, I'd
>> assume
>> that others have experienced the same problem, but I don't see any
>> mention
>> of it in these forums.
>>
>>
>>
>>
>>
>>
>> Jeremy F. Kassis wrote:
>> >
>> > Hi again,
>> >
>> > Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.
>> >
>> > One of my XHR Ajax requests is returning an exception. Here is the XHR
>> > response:
>> >
>> > <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC
>> "-//W3C//DTD
>> > XHTML 1.0 Transitional//EN"
>> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
>> > <!ENTITY nbsp '&#160;'>
>> > ]>
>> > <ajax-response><response id="bumpq:PageErrorPage" type="exception">
>> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
>> > "http://www.w3.org/TR/html4/loose.dtd">
>> >
>> > <!-- Application: bumpq -->
>> > <!-- Page: bumpq:PageErrorPage -->
>> > <!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
>> > <html>
>> > <head>
>> > <meta name="generator" content="Tapestry Application Framework, version
>> > 4.1.1" />
>> > <meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
>> > etc...
>> >
>> > Problem is that this isn't popping up in Firefox. I'm actually getting
>> a
>> > Dojo Warning as follows:
>> >
>> > WARNING: 12:42:47 AM: No ajax-response elements recieved.
>> >
>> > Is there anything I've got to do to get XHR exceptions to popup like
>> they
>> > did in Tap 4.0.2?
>> >
>> > Many thanks,
>> > Jeremy
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273906
>> Sent from the Tapestry - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
>> For additional commands, e-mail: users-help@tapestry.apache.org
>>
>>
> 
> 
> -- 
> Jesse Kuhnert
> Tapestry/Dojo team member/developer
> 
> Open source based consulting work centered around
> dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8285684
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: XHR Exception Not Rendering to Browser

Posted by Jesse Kuhnert <jk...@gmail.com>.
The DojoAjaxResponseBuilder handler currently gets configured with the
names of pages representing exceptions in order to detect an exception
page and properly render the response so it is presented properly for
ajax requests.

This configuration currently is done via hivemind :

http://tapestry.apache.org/tapestry4.1/tapestry-framework/hivedoc/service/tapestry.services.DojoAjaxResponseContributor.html

This could possibly be a bug on my part but I'm not sure? Either way
your feedback would be greatly appreciated, hopefully I can use your
issues to enhance the 4.0->4.1 upgrade guide.

On 1/11/07, Jeremy F. Kassis <jk...@jkassis.com> wrote:
>
> I just noticed something that seems related. The browser reports a syntax
> error in dojo/src/browser_debug.js:
>
> missing } after function body
> browser_debug.js (line 17)
> document.write("<script
> type='text/javascript'>dojo.hostenv._global_omit_module_check =
> false;</script>");dojo.hostenv._loadedUrisListStart = 0;if (!willCallAgain)
> {dj_eval = old_dj_eval;dojo.hostenv.loadUri = dojo.hostenv.oldLoadUri;}}
>
> Since this file comes from the official Tapestry 4.1.1 release, I'd assume
> that others have experienced the same problem, but I don't see any mention
> of it in these forums.
>
>
>
>
>
>
> Jeremy F. Kassis wrote:
> >
> > Hi again,
> >
> > Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.
> >
> > One of my XHR Ajax requests is returning an exception. Here is the XHR
> > response:
> >
> > <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD
> > XHTML 1.0 Transitional//EN"
> > "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
> > <!ENTITY nbsp '&#160;'>
> > ]>
> > <ajax-response><response id="bumpq:PageErrorPage" type="exception">
> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
> > "http://www.w3.org/TR/html4/loose.dtd">
> >
> > <!-- Application: bumpq -->
> > <!-- Page: bumpq:PageErrorPage -->
> > <!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
> > <html>
> > <head>
> > <meta name="generator" content="Tapestry Application Framework, version
> > 4.1.1" />
> > <meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
> > etc...
> >
> > Problem is that this isn't popping up in Firefox. I'm actually getting a
> > Dojo Warning as follows:
> >
> > WARNING: 12:42:47 AM: No ajax-response elements recieved.
> >
> > Is there anything I've got to do to get XHR exceptions to popup like they
> > did in Tap 4.0.2?
> >
> > Many thanks,
> > Jeremy
> >
>
> --
> View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273906
> Sent from the Tapestry - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>


-- 
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: XHR Exception Not Rendering to Browser

Posted by "Jeremy F. Kassis" <jk...@jkassis.com>.
I just noticed something that seems related. The browser reports a syntax
error in dojo/src/browser_debug.js:

missing } after function body                                                 
browser_debug.js (line 17)
document.write("<script
type='text/javascript'>dojo.hostenv._global_omit_module_check =
false;</script>");dojo.hostenv._loadedUrisListStart = 0;if (!willCallAgain)
{dj_eval = old_dj_eval;dojo.hostenv.loadUri = dojo.hostenv.oldLoadUri;}} 

Since this file comes from the official Tapestry 4.1.1 release, I'd assume
that others have experienced the same problem, but I don't see any mention
of it in these forums.






Jeremy F. Kassis wrote:
> 
> Hi again,
> 
> Still working out some issues migrating from Tap 4.0.2 to Tap 4.1.1.
> 
> One of my XHR Ajax requests is returning an exception. Here is the XHR
> response:
> 
> <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD
> XHTML 1.0 Transitional//EN"
> "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
> <!ENTITY nbsp '&#160;'>
> ]>
> <ajax-response><response id="bumpq:PageErrorPage" type="exception">
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
> "http://www.w3.org/TR/html4/loose.dtd">
> 
> <!-- Application: bumpq -->
> <!-- Page: bumpq:PageErrorPage -->
> <!-- Generated: Thu Jan 11 00:42:47 PST 2007 -->
> <html>
> <head>
> <meta name="generator" content="Tapestry Application Framework, version
> 4.1.1" />
> <meta http-equiv="Content-Type" content="text/xml;charset=UTF-8" />
> etc...
> 
> Problem is that this isn't popping up in Firefox. I'm actually getting a
> Dojo Warning as follows:
> 
> WARNING: 12:42:47 AM: No ajax-response elements recieved.
> 
> Is there anything I've got to do to get XHR exceptions to popup like they
> did in Tap 4.0.2?
> 
> Many thanks,
> Jeremy
> 

-- 
View this message in context: http://www.nabble.com/XHR-Exception-Not-Rendering-to-Browser-tf2957595.html#a8273906
Sent from the Tapestry - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org