Kinook Software Forum

Go Back   Kinook Software Forum > Visual Build Professional > [VBP] General Discussion
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 03-06-2003, 09:53 PM
Guest
 
Posts: n/a
FAILSTEP_NAME not being set

The FAILSTEP_NAME does not seem to be set when an operation fails. Basic overview of my script is as follows..

STEP_1: Checks if any source files it needs are already checked out. If any files are checked out the script fails. To do this I am using a Visual Source Safe Action configured as a 'Status' operation.

STEP_2..STEP_X: Check out and compile etc. I also have a conditional failure step in my script. The condition is based on whether it fails on 'Step 1' or elsewhere. I have tried checking the FAILSTEP_NAME in the failure step but its value is always blank. I assumed it should equal the 'Name' field in the properties dialog for STEP_1. Anybody know where I'm going wrong?

I'm using Visual Build Pro v4.6b
Reply With Quote
  #2  
Old 03-06-2003, 09:55 PM
pjaquiery pjaquiery is online now
Registered User
 
Join Date: 01-20-2003
Location: Dunedin, New Zealand
Posts: 114
I've noticed this too. Could it be that following the first step in the Failure Steps the name is reset? A work around would be to have the first step save the step name to a macro.

Most of my failure processing sends email. I send the log file for the build as an attachment to the email.

Another trick I find useful is to use a global macro to override the system LOGFILE macro with:

%LogFilePath%%PROJROOT%Log.txt

so that log files are generated for each different build project. Helps a lot when a master build project invokes others.

I also often use %PROJROOT% in the body of the email so I know which build project generated the email.

Peter Jaquiery
Reply With Quote
  #3  
Old 03-06-2003, 09:56 PM
trippcr trippcr is online now
Registered User
 
Join Date: 12-10-2002
Posts: 4
Hello,
My experience has been that the FAILSTEP marcos are only available in the Failure Steps tab not in the Project Steps tab. Most of the time I don't want the build to stop on those step if they fail, rather I just record that they failed and move on to other steps. For those cases I use the LASTSTEP_STATUS macro to check the status and then record the name and output if there was a failure in the main Project steps tab.

-Corey
Reply With Quote
  #4  
Old 09-22-2006, 02:58 PM
marcstober marcstober is online now
Registered User
 
Join Date: 01-25-2005
Location: Boston, MA
Posts: 3
I just came across this issue as well. We were using these values in the Project Steps tab in Visual Build Pro 5.7. Now I'm getting an error now that we've upgraded to version 6.2. Maybe this is a regression bug? The only reason I can think we'd need them in project steps is if you specific to ignore failure for a step, but you still want to report that it failed.

-Marc
Reply With Quote
  #5  
Old 09-22-2006, 04:42 PM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 6,034
Hmmm, it was always documented and designed that the failed step info be available only from failure steps (if it did work, it was only incidental). What sort of additional reporting are you doing in this situation (if a step does fail but that condition is ignored, the failure information and status is already logged automatically)?

Some options:

1a) If all you're doing is writing extra info to the log, you can do that in the step's vbld_StepDone script event (of the step whose failure would be ignored):

Code:
If Step.BuildStatus = vbldStepStatFailed Then
   Builder.LogMessage "Error building step " & Step.Name ' etc.
End If
http://www.visualbuild.com/Manual/scriptevents.htm

1b) Centralize this logging in the global vbld_StepDoneProject script event (instead of for each step whose failure is ignored):

Code:
If Step.ContinueOnFailure And Step.BuildStatus = vbldStepStatFailed Then
   ' log failure info
End If
2) If you're using extra steps for this failure reporting (for instance, to send mail, etc.), configure the steps to build some failure steps (for instance, a failure subroutine called Report Failure) to report the additional info but continue building, rather than utilizing the failed step info from Project steps (this might also simplify your code if you have multiple steps that you're checking and reporting failure for).
Reply With Quote
  #6  
Old 09-25-2006, 08:38 AM
marcstober marcstober is online now
Registered User
 
Join Date: 01-25-2005
Location: Boston, MA
Posts: 3
Thanks for the feedback. We just had the %FAILSTEP_*% macros in the message body of a send e-mail step. I can't remember them returning a value in a long time (if ever), but it didn't cause the build to fail in 5.7, either. At this point we are fine with just removing them from the message body, but it's good to know there is another way to do this.

- Marc
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



All times are GMT -5. The time now is 07:17 PM.


Copyright © 1999-2023 Kinook Software, Inc.