Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: DXL Error Formats
Topic Summary:
Created On: 23-May-2006 15:46
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 23-May-2006 15:46
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

I'm going to write a function that accepts trapped DXL errors, and formats for suitable display to the user. I'd like to get rid of the line of code generating the errors.

---- I'd trap the errors like this:
noError()
do something
string ErrMess = lastError()

---- I'd turn an error like this:
-R-W- DXL: <Includes\Lib-Attrs.inc:276> no access to modify attribute 'Object Text'
---- into this:
no access to modify attribute 'Object Text'

I figured I'd use RegExp. Does anyone know of all the formats of DXL errors? The one above looks like "-R-W- DXL: <any characters>". Others may look like "-i- DXL: <any characters>".

- Louie
Report this to a Moderator Report this to a Moderator
 23-May-2006 16:52
User is offline View Users Profile Print this message


Dan Hopping

Posts: 75
Joined: 21-Nov-2002

If memory serves, I think the errors are fairly generic. Would it work for you to just parse out the generic portion and capture only the text at the end of the error message?
example...
string s = "\\-R\\-W\\- DXL: \\ no access to modify attribute \'Object Text\'"
Regexp re = regexp ".*DXL:.*<.*>(.*)"
re s
print "Original: " s "\n"
print "Printed Error: " s[match 1]
Report this to a Moderator Report this to a Moderator
 23-May-2006 18:07
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Yes, but I don't know the different generic forms. One form is "-R-W- DXL: <name of file> actual message". Yes, RegExp can be used to isolate "actual message".

I was wondering what the other forms might look like, "-I-" for example.
Report this to a Moderator Report this to a Moderator
 24-May-2006 15:15
User is offline View Users Profile Print this message


Tony Goodman

Posts: 1098
Joined: 12-Sep-2002

I managed to generate the following that all look much the same apart from the backtrace example.

-R-E- DXL: <Line:1> null Object parameter was passed into argument position 1
-I- DXL: execution halted

-R-E- DXL: <Line:1> incorrect argument for operator (/), (0)
-I- DXL: execution halted

-E- DXL: <Line:1> could not open include file (foobar) (No such file or directory)
-I- DXL: all done with 1 error and 0 warnings

-E- DXL: <Line:2> incorrect arguments for (=)
-I- DXL: all done with 1 error and 0 warnings

-R-E- DXL: <Line:1> Stack Overflow (current limit is 4096)
-I- DXL: execution halted

-E- DXL: <n:/dxl/my_dxl_library/locks/test.dxl:38> incorrect arguments for function (vdsShare)
Included from:
<Line:1>
-E- DXL: <n:/dxl/my_dxl_library/locks/test.dxl:38> undeclared variable (s)
Included from:
<Line:1>
-I- DXL: all done with 2 errors and 0 warnings

-------------------------
Tony Goodman
http://www.smartdxl.com
Report this to a Moderator Report this to a Moderator
 25-May-2006 22:06
User is offline View Users Profile Print this message


Louie Landale

Posts: 2070
Joined: 12-Sep-2002

Run time errors, then, seem to be limited to:
[1] -R-W- DXL: <optional path> Message part I care about.
[2] -R-E- DXL: <optional path> Message part I care about.

Perhaps "-R-E-" means "Runtime Error"; "-R-W-" means "Runtime Access Issue"; "-I" means "Interpreted"; and "-E'" means "Ediot: you cannot type good".

- Louie
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.