- Justin Roeser
- PowerBuilder
- Tuesday, 26 July 2022 04:51 PM UTC
I'm new to PowerBuilder 2017 R3, and I am working on improving a build script written in powershell. At one point in the powershell script, we have a bootstrap.dat file passed as an argument to orcascr170.exe in order to build the application. Unfortunately, whenever we get to this point in the script, the script just "hangs" for a while (5-10 minutes) before moving on. What I would like to do is to see if there is any way to improve the perfomance of this, or at least have some way to give feedback to the user so that they aren't just staring at an empty window.
How exactly can I go about debugging this? At present, my approach has been commenting out lines and then running my powershell script to see which one is causing the hang up:
start session
...
...
...
scc set connect property localprojpath build_path
scc set connect property logfile orca_log_filename
scc set connect property logappend false
scc set connect property deletetempfiles true
scc connect offline
scc set target target_filename "refresh_all" importonly
scc refresh target 3pass
scc close
end session
It seems like the "scc refresh target 3pass" is what is causing the holdup. I would get the feedback by using this powershell command:
while (($str=$Process.StandardOutput.ReadLine()) -ne $null) {
Write-Host $str
}
The problem with this is that it's not like the .dat file is processed line by line, with me seeing the feedback every line. It's like orcascript is processing the whole .dat file at once, then giving me feedback afterwards.
I have never worked with OrcaScript before, and I'm new to PowerBuilder. I did come across this: https://docs.appeon.com/pb2022/orca_guide/ and this: https://docs.appeon.com/pb2019/pbug/apb.html. But I'm not seeing a lot in either of those for debugging or getting feedback.
So going back to my question, what's a good way I can debug or at least get more info from my orcascript batch file? I'm not opposed to switching things up with how the build process works (like using C or something).
Find Questions by Tag
Helpful?
If a reply or comment is helpful for you, please don’t hesitate to click the Helpful button. This action is further confirmation of their invaluable contribution to the Appeon Community.