![]() |
Telelogic DOORS (steve huntington) | ![]() |
new topic :
profile :
search :
help :
dashboard :
calendar :
home
|
||
Latest News:
|
|
Topic Title: Suspected Bug for locking/unlocking in combination with links Topic Summary: Created On: 3-Sep-2008 16:40 Status: Post and Reply |
Linear : Threading : Single : Branch |
![]() |
![]()
|
![]() |
|
Hello all,
I have tried to update some linked requirements to get the content from the head requirement there. So I created a module containing one section with three requirements (one which is filled and two to update). Heading - Req 1 (Inlink from Req 2, Req 3) - Req 2 (Outlink from Req 1) - Req 3 (Outlink from Req 1) My code works fine until I tried it a second time. Since I used a DXL attribute Doors directly exited without a hint or error message. After this I reduced my code step by step to get the critical part. I identified the following part (still crashes when executing from Req 1). Anyone have an idea? Thanks for your advice. Edited: 3-Sep-2008 at 16:51 by Tobias Gündel |
|
![]() |
|
![]() |
|
This is attr-DXL?
You should use variable 'obj' instead of 'current Object'. You need to make sure the source module is open before attempting to access the source object. In this case your variable 'oLinked' can easily be undefined, yet you don't check for that. Maybe these objects have more than the links than you described. You are using Attr-DXL to unlock and save sections in another module??? Why on earth would you do that? You don't seem to check if the source module is open Shareable; as is required for the lock-unlock commands. I'm not too familiar with the lock-unlock commands, but you seem to be first locking the source object's section and then unlocking it. These commands will only work when there are in fact shared sections defined in the module. I see no results from your DXL to place as the Attr-DXL value; obj.attrDXLName = <Results>. Don't know why DOORS would exit without any ceremony. Consider placing 'noError' before the suspect code and then string ErrMess = lastError() afterwards, in an attempt to trap the errors. - Louie |
|
![]() |
|
![]() |
|
Hello,
I first used Attr-DXL, but Doors exited without any hint. So I run the code on the object (in this case Req 1) instead (so this is why there is a current object) and like I said I created a module containing my linked objects (which have only the Links I described) to avoid opening other modules with LinkRef (of course the complete code includes it). This module was prepared with share sections and was opened shareable. If you ran the code manually you get the following error: -I- DXL: execution halted and regarding to the Diagnostic lock: I would not be such concerned since it works the first time... PS: I only used a DXL- Attr for testing purpose, later the code will be triggered. EDIT: The error occurs only if the source and target objects are in the same section otherwise it works fine. Edited: 4-Sep-2008 at 07:40 by Tobias Gündel |
|
![]() |
|
![]() |
|
Just a wild guess, but perhaps the lock and unlock commands somehow change the 'Current Object'. Add the following before the loop and at the bottom of the loop: print "Current = " identifier(currrent Object) "\n".
If it changes, then you should change your loop parameter as follows: Object oCurr = current for lnk in oCurr <-"*" do - Louie |
|
![]() |
|
![]() |
|
@Louie
Thanks for the hint, but unfortunatly it doesn't work ![]() --- I opened a case and will report Telelogics answer. |
|
![]() |
|
![]() |
|
Tobias, I have no idea what it is you are trying to do, but my advice is NEVER change data automatically in another module, especially using attribute DXL. This is dangerous stuff. Just do changes in your current module and open others read-only.
Anyway, with regards to your code: I suspect that messing with objects within the in-link loop is the cause of the errors. My experiments suggest that lock() and unlock() do not change the current object, but who knows what is going on in the depths of doors with regards to how it deals with links... Change your code so that you get a list of source objects in a sklip list, then loop through the skip list. Also, you should check for the section being locked before attempting to lock it, i.e. call isLockedByUser() then if not locked call lock(). P.S Bet you a penny that Telelogic's answer is the same as mine :-) ------------------------- Tony Goodman Smart DXL limited www.smartdxl.com Edited: 5-Sep-2008 at 08:43 by Tony Goodman |
|
![]() |
FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.