Ticket: Fusion reports unreadable error message

9 messages Options
Embed this post
Permalink
Christine Bao

Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Some javascript/style in this post has been disabled (why?)

Hi,

 

I’ve created a ticket http://trac.osgeo.org/fusion/ticket/270 and attached patch http://trac.osgeo.org/fusion/attachment/ticket/270/FusionErrorMessage.patch for it. Would you please review? Thank you!

 

If no comments before July 22, I’ll submit code.

 

Thanks & regards,

Christine

 


_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Jason Birch

RE: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Some javascript/style in this post has been disabled (why?)

Is there any way of making the request URL available to users in a pop-up window or something?

 

I agree that the current mechanism is not user-friendly, but providing the ability to copy/paste the exact error and http request that caused the exception would be useful.  Trying to track these down through server request and error logs can be painful.

 

Jason

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of Christine Bao
Sent: Monday, July 20, 2009 3:07 AM
To: Paul Spencer (External); [hidden email]
Subject: [fusion-dev] Ticket: Fusion reports unreadable error message

 

Hi,

 

I’ve created a ticket http://trac.osgeo.org/fusion/ticket/270 and attached patch http://trac.osgeo.org/fusion/attachment/ticket/270/FusionErrorMessage.patch for it. Would you please review? Thank you!

 

If no comments before July 22, I’ll submit code.

 

Thanks & regards,

Christine

 


_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Paul Spencer-2

Re: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Would a configurable option to run in 'debug' mode vs production mode  
be practical for this sort of this?  It could be added to the existing  
config.json and used in various places for reporting problems vs  
either suppressing them or providing less ominous looking errors ...

Paul

On 20-Jul-09, at 11:37 AM, Jason Birch wrote:

> Is there any way of making the request URL available to users in a  
> pop-up window or something?
>
> I agree that the current mechanism is not user-friendly, but  
> providing the ability to copy/paste the exact error and http request  
> that caused the exception would be useful.  Trying to track these  
> down through server request and error logs can be painful.
>
> Jason
>
> From: [hidden email] [mailto:[hidden email]
> ] On Behalf Of Christine Bao
> Sent: Monday, July 20, 2009 3:07 AM
> To: Paul Spencer (External); [hidden email]
> Subject: [fusion-dev] Ticket: Fusion reports unreadable error message
>
> Hi,
>
> I’ve created a ticket http://trac.osgeo.org/fusion/ticket/270 and  
> attached patch http://trac.osgeo.org/fusion/attachment/ticket/270/FusionErrorMessage.patch 
>  for it. Would you please review? Thank you!
>
> If no comments before July 22, I’ll submit code.
>
> Thanks & regards,
> Christine
>


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://research.dmsolutions.ca/

_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Jason Birch

RE: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
I'm not sure.  I was initially going to suggest that, but I often don't get trouble reports until after an application has been signed off, moved to production, etc...  I'd hate to leave a debug flag turned on in production if it had performance implications made the interface totally developer-centric, and I'd be concerned that calling the config option "debug" would lead to this.  

If it was called "extendedErrors" or something like that it might be better?  Or if there were different debug levels (none, error, information)?

Another option would be a link that says "Email Problem Report" where user can fill in information about what they were doing, and all debug info is automatically added to the report. :)

Jason

-----Original Message-----
From: Paul Spencer
Sent: Monday, July 20, 2009 10:56 AM
Subject: Re: Ticket: Fusion reports unreadable error message

Would a configurable option to run in 'debug' mode vs production mode  
be practical for this sort of this?  It could be added to the existing  
config.json and used in various places for reporting problems vs  
either suppressing them or providing less ominous looking errors ...

Paul
_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Paul Spencer-2

Re: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
This sounds more application-specific than I am willing to put into  
the library as core functionality.  So to accommodate this, I would  
prefer that we expose 'extended' error conditions through event  
notifications that developers can use to implement their own handling  
system.  In this case, Fusion would never alert an error but rather  
would trigger error events (some of this happens already) and pass  
both basic and extended information.

In this case, Christine's patch should be modified to fire an error  
event instead of an alert.  Perhaps that is beyond the scope of the  
current change :)

Paul

On 20-Jul-09, at 2:13 PM, Jason Birch wrote:

> I'm not sure.  I was initially going to suggest that, but I often  
> don't get trouble reports until after an application has been signed  
> off, moved to production, etc...  I'd hate to leave a debug flag  
> turned on in production if it had performance implications made the  
> interface totally developer-centric, and I'd be concerned that  
> calling the config option "debug" would lead to this.
>
> If it was called "extendedErrors" or something like that it might be  
> better?  Or if there were different debug levels (none, error,  
> information)?
>
> Another option would be a link that says "Email Problem Report"  
> where user can fill in information about what they were doing, and  
> all debug info is automatically added to the report. :)
>
> Jason
>
> -----Original Message-----
> From: Paul Spencer
> Sent: Monday, July 20, 2009 10:56 AM
> Subject: Re: Ticket: Fusion reports unreadable error message
>
> Would a configurable option to run in 'debug' mode vs production mode
> be practical for this sort of this?  It could be added to the existing
> config.json and used in various places for reporting problems vs
> either suppressing them or providing less ominous looking errors ...
>
> Paul


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://research.dmsolutions.ca/

_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Paul Deschamps

Re: Re: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Perhaps someone would like to develop a "error / debug" widget where it can display / store these messages. 

Hmm didn't chameleon have this :) experiencing a "deJa vu" here

Cheers

Paul D.

On Mon, Jul 20, 2009 at 3:26 PM, Paul Spencer <[hidden email]> wrote:
This sounds more application-specific than I am willing to put into the library as core functionality.  So to accommodate this, I would prefer that we expose 'extended' error conditions through event notifications that developers can use to implement their own handling system.  In this case, Fusion would never alert an error but rather would trigger error events (some of this happens already) and pass both basic and extended information.

In this case, Christine's patch should be modified to fire an error event instead of an alert.  Perhaps that is beyond the scope of the current change :)

Paul


On 20-Jul-09, at 2:13 PM, Jason Birch wrote:

I'm not sure.  I was initially going to suggest that, but I often don't get trouble reports until after an application has been signed off, moved to production, etc...  I'd hate to leave a debug flag turned on in production if it had performance implications made the interface totally developer-centric, and I'd be concerned that calling the config option "debug" would lead to this.

If it was called "extendedErrors" or something like that it might be better?  Or if there were different debug levels (none, error, information)?

Another option would be a link that says "Email Problem Report" where user can fill in information about what they were doing, and all debug info is automatically added to the report. :)

Jason

-----Original Message-----
From: Paul Spencer
Sent: Monday, July 20, 2009 10:56 AM
Subject: Re: Ticket: Fusion reports unreadable error message

Would a configurable option to run in 'debug' mode vs production mode
be practical for this sort of this?  It could be added to the existing
config.json and used in various places for reporting problems vs
either suppressing them or providing less ominous looking errors ...

Paul


__________________________________________

  Paul Spencer
  Chief Technology Officer
  DM Solutions Group Inc
  http://research.dmsolutions.ca/

_______________________________________________



--
   Paul Deschamps
   Applications Specialist
   DM Solutions Group Inc.

   Office: (613) 565-5056 x28
   [hidden email]
   http://www.dmsolutions.ca
   http://research.dmsolutions.ca
   


_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Christine Bao

RE: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
In reply to this post by Paul Spencer-2
Hi Paul,

   Currently Fusion actually fires an error event.
   Fusion.js:
            if (r.status >= 400) {
                Fusion.reportError(new Fusion.Error(Fusion.Error.FATAL,
                  'xml2json: invalid XML document: ' + r.statusText  + " : " + r.request.url));
                return;
            }
   This will fire an error event, and the event is registered in MapGuide.
   MapGuide template:    
                Fusion.registerForEvent(Fusion.Event.FUSION_ERROR, fusionError);

                var fusionError = function(eventId, error) {
    alert('Fusion Error: \n' + error.toString());    
                }
    In this way, I can handle the error message in MapGuide template, parse them and only show the exception message. This solution will not affect fusion. How do you like this idea?

Thanks & regards,
Christine

-----Original Message-----
From: Paul Spencer [mailto:[hidden email]]
Sent: Tuesday, July 21, 2009 3:27 AM
To: Jason Birch
Cc: Christine Bao; [hidden email]
Subject: Re: Ticket: Fusion reports unreadable error message

This sounds more application-specific than I am willing to put into  
the library as core functionality.  So to accommodate this, I would  
prefer that we expose 'extended' error conditions through event  
notifications that developers can use to implement their own handling  
system.  In this case, Fusion would never alert an error but rather  
would trigger error events (some of this happens already) and pass  
both basic and extended information.

In this case, Christine's patch should be modified to fire an error  
event instead of an alert.  Perhaps that is beyond the scope of the  
current change :)

Paul

On 20-Jul-09, at 2:13 PM, Jason Birch wrote:

> I'm not sure.  I was initially going to suggest that, but I often  
> don't get trouble reports until after an application has been signed  
> off, moved to production, etc...  I'd hate to leave a debug flag  
> turned on in production if it had performance implications made the  
> interface totally developer-centric, and I'd be concerned that  
> calling the config option "debug" would lead to this.
>
> If it was called "extendedErrors" or something like that it might be  
> better?  Or if there were different debug levels (none, error,  
> information)?
>
> Another option would be a link that says "Email Problem Report"  
> where user can fill in information about what they were doing, and  
> all debug info is automatically added to the report. :)
>
> Jason
>
> -----Original Message-----
> From: Paul Spencer
> Sent: Monday, July 20, 2009 10:56 AM
> Subject: Re: Ticket: Fusion reports unreadable error message
>
> Would a configurable option to run in 'debug' mode vs production mode
> be practical for this sort of this?  It could be added to the existing
> config.json and used in various places for reporting problems vs
> either suppressing them or providing less ominous looking errors ...
>
> Paul


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://research.dmsolutions.ca/

_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Paul Spencer-2

Re: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Excellent!

On 20-Jul-09, at 10:22 PM, Christine Bao wrote:

> Hi Paul,
>
>   Currently Fusion actually fires an error event.
>   Fusion.js:
>            if (r.status >= 400) {
>                Fusion.reportError(new Fusion.Error(Fusion.Error.FATAL,
>                  'xml2json: invalid XML document: ' + r.statusText  
> + " : " + r.request.url));
>                return;
>            }
>   This will fire an error event, and the event is registered in  
> MapGuide.
>   MapGuide template:
> Fusion.registerForEvent(Fusion.Event.FUSION_ERROR, fusionError);
>
> var fusionError = function(eventId, error) {
>     alert('Fusion Error: \n' + error.toString());
> }
>    In this way, I can handle the error message in MapGuide template,  
> parse them and only show the exception message. This solution will  
> not affect fusion. How do you like this idea?
>
> Thanks & regards,
> Christine
>
> -----Original Message-----
> From: Paul Spencer [mailto:[hidden email]]
> Sent: Tuesday, July 21, 2009 3:27 AM
> To: Jason Birch
> Cc: Christine Bao; [hidden email]
> Subject: Re: Ticket: Fusion reports unreadable error message
>
> This sounds more application-specific than I am willing to put into
> the library as core functionality.  So to accommodate this, I would
> prefer that we expose 'extended' error conditions through event
> notifications that developers can use to implement their own handling
> system.  In this case, Fusion would never alert an error but rather
> would trigger error events (some of this happens already) and pass
> both basic and extended information.
>
> In this case, Christine's patch should be modified to fire an error
> event instead of an alert.  Perhaps that is beyond the scope of the
> current change :)
>
> Paul
>
> On 20-Jul-09, at 2:13 PM, Jason Birch wrote:
>
>> I'm not sure.  I was initially going to suggest that, but I often
>> don't get trouble reports until after an application has been signed
>> off, moved to production, etc...  I'd hate to leave a debug flag
>> turned on in production if it had performance implications made the
>> interface totally developer-centric, and I'd be concerned that
>> calling the config option "debug" would lead to this.
>>
>> If it was called "extendedErrors" or something like that it might be
>> better?  Or if there were different debug levels (none, error,
>> information)?
>>
>> Another option would be a link that says "Email Problem Report"
>> where user can fill in information about what they were doing, and
>> all debug info is automatically added to the report. :)
>>
>> Jason
>>
>> -----Original Message-----
>> From: Paul Spencer
>> Sent: Monday, July 20, 2009 10:56 AM
>> Subject: Re: Ticket: Fusion reports unreadable error message
>>
>> Would a configurable option to run in 'debug' mode vs production mode
>> be practical for this sort of this?  It could be added to the  
>> existing
>> config.json and used in various places for reporting problems vs
>> either suppressing them or providing less ominous looking errors ...
>>
>> Paul
>
>
> __________________________________________
>
>    Paul Spencer
>    Chief Technology Officer
>    DM Solutions Group Inc
>    http://research.dmsolutions.ca/
>


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://research.dmsolutions.ca/

_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev
Christine Bao

RE: Ticket: Fusion reports unreadable error message

Reply Threaded More More options
Print post
Permalink
Ok, let's take this solution.

-----Original Message-----
From: Paul Spencer [mailto:[hidden email]]
Sent: Tuesday, July 21, 2009 10:52 AM
To: Christine Bao
Cc: Jason Birch; [hidden email]
Subject: Re: Ticket: Fusion reports unreadable error message

Excellent!

On 20-Jul-09, at 10:22 PM, Christine Bao wrote:

> Hi Paul,
>
>   Currently Fusion actually fires an error event.
>   Fusion.js:
>            if (r.status >= 400) {
>                Fusion.reportError(new Fusion.Error(Fusion.Error.FATAL,
>                  'xml2json: invalid XML document: ' + r.statusText  
> + " : " + r.request.url));
>                return;
>            }
>   This will fire an error event, and the event is registered in  
> MapGuide.
>   MapGuide template:
> Fusion.registerForEvent(Fusion.Event.FUSION_ERROR, fusionError);
>
> var fusionError = function(eventId, error) {
>     alert('Fusion Error: \n' + error.toString());
> }
>    In this way, I can handle the error message in MapGuide template,  
> parse them and only show the exception message. This solution will  
> not affect fusion. How do you like this idea?
>
> Thanks & regards,
> Christine
>
> -----Original Message-----
> From: Paul Spencer [mailto:[hidden email]]
> Sent: Tuesday, July 21, 2009 3:27 AM
> To: Jason Birch
> Cc: Christine Bao; [hidden email]
> Subject: Re: Ticket: Fusion reports unreadable error message
>
> This sounds more application-specific than I am willing to put into
> the library as core functionality.  So to accommodate this, I would
> prefer that we expose 'extended' error conditions through event
> notifications that developers can use to implement their own handling
> system.  In this case, Fusion would never alert an error but rather
> would trigger error events (some of this happens already) and pass
> both basic and extended information.
>
> In this case, Christine's patch should be modified to fire an error
> event instead of an alert.  Perhaps that is beyond the scope of the
> current change :)
>
> Paul
>
> On 20-Jul-09, at 2:13 PM, Jason Birch wrote:
>
>> I'm not sure.  I was initially going to suggest that, but I often
>> don't get trouble reports until after an application has been signed
>> off, moved to production, etc...  I'd hate to leave a debug flag
>> turned on in production if it had performance implications made the
>> interface totally developer-centric, and I'd be concerned that
>> calling the config option "debug" would lead to this.
>>
>> If it was called "extendedErrors" or something like that it might be
>> better?  Or if there were different debug levels (none, error,
>> information)?
>>
>> Another option would be a link that says "Email Problem Report"
>> where user can fill in information about what they were doing, and
>> all debug info is automatically added to the report. :)
>>
>> Jason
>>
>> -----Original Message-----
>> From: Paul Spencer
>> Sent: Monday, July 20, 2009 10:56 AM
>> Subject: Re: Ticket: Fusion reports unreadable error message
>>
>> Would a configurable option to run in 'debug' mode vs production mode
>> be practical for this sort of this?  It could be added to the  
>> existing
>> config.json and used in various places for reporting problems vs
>> either suppressing them or providing less ominous looking errors ...
>>
>> Paul
>
>
> __________________________________________
>
>    Paul Spencer
>    Chief Technology Officer
>    DM Solutions Group Inc
>    http://research.dmsolutions.ca/
>


__________________________________________

    Paul Spencer
    Chief Technology Officer
    DM Solutions Group Inc
    http://research.dmsolutions.ca/

_______________________________________________
fusion-dev mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/fusion-dev