I'm building an PB 10 application that will be do the
getLatestVersion automatically for the developers. Our
source control is VSS (Microsoft Visual SourceSafe). I have
a DWFind WorkSpace, and a DWFind2 Target and App.
I have built the config file that Orca will execute with the
following script:
start session
SCC get connect properties
"D:\attps\des\fin\sgr\PB10\Util\DWFind\DWFind.pbw"
SCC Connect
SCC set target
"D:\attps\des\fin\sgr\PB10\Util\DWFind2\dwfind2.pbt"
"outofdate exclude_checkout"
scc refresh target incremental
SCC Close
end session
Although it seems right to me, it doesn't do the getLatest,
and the log file comes with 2 message for every object:
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
All the properties are properly set for the WorkSpace, like
userid.
The objects, as seen from PB, are all in VSS, and I can do a
GetLatest from PB with no problems.
The complete log is right here:
12/11/2007 16:21 Source Management Initialization...
Scc Provider: Microsoft Visual SourceSafe
UserID: dcferreira
Project Path: "$/ATTPS/DES/FIN/SGR/PB10", SXGBBAAA
Aux Project Path: \\attbhzs027\vss2\,
Local Project Path: d:\attps\des\fin\sgr\pb10
Connection to source control established
PBORCA_SccSetTarget:
d:\attps\des\fin\sgr\pb10\util\dwfind2\dwfind2.pbt
Target settings: REFRESH OUT OF DATE | EXCLUDE CHECKOUT
App Name: dwfind2 App Lib:
d:\attps\des\fin\sgr\pb10\util\dwfind2\dwfind2.pbl
Library List:
d:\attps\des\fin\sgr\pb10\util\dwfind2\dwfind2.pbl
d:\attps\des\fin\sgr\pb10\util\dwfind2\teste.pbl
PBORCA_SccRefreshTarget. Incremental Rebuild
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
(repeat previous 2 lines 11 times (11 objects in my app)
Calling cm_rebuild_application(CM_REBUILD_INCREMENTAL).
PBORCA_SccClose
12/11/2007 16:21 Source control terminated
Do you guys have any suggestion on what else I should do to
get the GLV working??
Thank you again!
PS. I'm using PB 10.2.1 Build 9914
Visual SourceSafe 6.0a Build 8835
Windows XP.
Since you are seeing a failure in writing to a file, perhaps the pbl
file is not writable. Make sure it isn't readonly, isn't locked by
another process, and that the user running the ORCA process has
sufficient NT file permissions.
The files on mmy working folder on drive D: are not
read-only (I removed the flags and tried again), and also
I'm a system admin on my PC. I even generated an EXE of my
app that calls the OrcaScript, to be able to quit all
instances of PB before running the OrcaScript, but the
problem persisted.
Do you think VSS could have some read-only files on my PC
when I try the getLatest? I can't find it. Still, thru PB,
the GetLatest works fine.
Any ideas? Thank you!!!
By the way, the build of the executable works fine, just the
GetLatest doesn't....
Open the .PBW file, and look at how the target is referenced in there. It's
relative to the local root folder - .\util\DWFind2\dwfind2.pbt', or
something to that effect. Try experimenting with that.
Also, VSS has this strange property, designed to protect you from yourself,
where it doesn't allow you to edit the local copies of source unless the
objects are first checked out. It's called "make local files writeable" or
something to that effect. Make sure that's OFF. Otherwise, nothing can
overwrite the local .sr* files unless VSS sees them as checked out.
Also, do you have "Delete PB-Generated Source Files" (it's a workspace SCC
property) on or off? I think it should be OFF for VSS.
Paul Horan[TeamSybase]
<Daniel @ attps.com.br> wrote in message
news:4738c57e.1c8...@sybase.com...
Thank you very much for the try, but still no success. Maybe
I'm missing some configuration, maybe there's something to
be configured at VSS server... I don't know. Please, see if
you have any clues. Thank you again.
Here is all the info I could find:
On the PBW:
Log all activity to pbscc100.log (the file is at the end of
the post)
Checked items:
Require comments on check-in
Perform diff on status update
Unchecked items:
This project requires that I sometimes work offline
Delete Powerbuilder-generated object files
Suppress prompts to overwrite read-only files
My workspace (dont get confused, I have two targets: DWFind,
my real application that I'm trying to get to work, and
DWFind2, my test target application)
Save Format v3.0(19990112)
@begin Unchecked
@end;
@begin Targets
0 "dwfind.pbt";
2 "..\\DWFind2\\dwfind2.pbt";
@end;
DefaultTarget "dwfind.pbt";
DefaultRemoteTarget "dwfind.pbt";
The Target for DWFind:
Save Format v3.0(19990112)
appname "dwfind";
applib "dwfind.pbl";
liblist "dwfind.pbl";
type "pb";
The Target for DWFind2:
Save Format v3.0(19990112)
@begin Projects
0 "1&dwfind2&dwfind2.pbl";
@end;
appname "dwfind2";
applib "dwfind2.pbl";
LibList "dwfind2.pbl;teste.pbl";
type "pb";
My Config.orca (The orca script file that I call from
orcascr100.exe
start session
SCC get connect properties
"D:\attps\des\fin\sgr\PB10\Util\DWFind\DWFind.pbw"
SCC Connect
SCC set target "..\\DWFind2\\dwfind2.pbt" "outofdate
exclude_checkout"
scc refresh target incremental
SCC Close
end session
My app log file (part of it)
Press any key to continue . . .
Sybase (R) OrcaScript interpreter version 10.0.
Using source file Config.orca.
startSession
scc get connect properties
"D:\attps\des\fin\sgr\PB10\Util\DWFind\DWFind.pbw"
scc connect
scc set target "..\\DWFind2\\dwfind2.pbt" "OUTOFDATE |
EXCLUDE_CHECKOUT"
Lib List for SccTarget
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\dwfind2.pbl
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\teste.pbl
scc refresh target incremental
scc close
endSession
Press any key to continue . . .
The workSpace's log file, the one mentioned at the begining:
pbscc100.log
13/11/2007 15:23 Source Management Initialization...
Scc Provider: Microsoft Visual SourceSafe
UserID: dcferreira
Project Path: "$/ATTPS/DES/FIN/SGR/PB10", SXGBBAAA
Aux Project Path: \\attbhzs027\vss2\,
Local Project Path: d:\attps\des\fin\sgr\pb10
Connection to source control established
PBORCA_SccSetTarget:
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\dwfind2.pbt
Target settings: REFRESH OUT OF DATE | EXCLUDE CHECKOUT
App Name: dwfind2 App Lib:
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\dwfind2.pbl
Library List:
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\dwfind2.pbl
d:\attps\des\fin\sgr\pb10\util\\dwfind2\\teste.pbl
PBORCA_SccRefreshTarget. Incremental Rebuild
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Operating System Error 6 occurred performing WriteFile.
SccDiff() failed because object is not under source control.
Calling cm_rebuild_application(CM_REBUILD_INCREMENTAL).
PBORCA_SccClose
13/11/2007 15:23 Source control terminated
--------------------------------------------------
13/11/2007 15:26 Source Management Initialization...
Scc Provider: Microsoft Visual SourceSafe
UserID: dcferreira
Project Path: "$/ATTPS/DES/FIN/SGR/PB10", SXGBBAAA
Aux Project Path: \\attbhzs027\vss2\,
Local Project Path: D:\attps\des\fin\sgr\PB10
Scc multi-threading defaulting to TRUE
Paul Horan[TeamSybase]
<Daniel @ attps.com.br> wrote in message
news:4739e12a.37a...@sybase.com...
But the thing I noticed is this: when I execute the script,
I do see all the source files (*.sr?) as read-only on the
apps folder (I deleted them, but after running the script
they where there again). Is this a VSS bug? Is there a way
to send a dos command to unflag these files, after they are
retrieved from VSS, in the Orca script?
How does it work? Is this it?
1) Orca sends a command to VSS to get the source files;
2) VSS responds putting the .sr files in the directory, but
with the read-only flag set;
3) Orca tries to import these files to a PBL, but since they
are read-only, it doesn't work.
Thank you!!!
Not quite. It's:
- Is this object out of sync with the repository? (With VSS, it has to do a
GET to perform a full text compare, because VSS can't do a "diff by version
number" operation
- If yes, then import the changed object. If not, then don't.
- If "Delete PB-generated Object Files" is on, then remove the .sr* files.
Now - you mentioned that you have two different targets. Why? Just get one
working before you add a second. The message "this object is not under
source control" makes me think that something with that second target is
messing things up.
>
> Thank you!!!
pbg files include path information relative to the local root folder.
Make sure this second target of yours has these paths specified
correctly.
One funny thing about the "new" PBG is that it has 2 entries
for every PB object in my app. Is this how it should look? I
remember that PB8 had only one entry!
Example:
"DWFind2\\dwfind2.sra" "DWFind2\\dwfind2.pbl";
"Util\\DWFind2\\dwfind2.sra" "Util\\DWFind2\\dwfind2.pbl";
Is there a way to make orca log all the objects it updated?
When I have messed up PBG, is there a way to easily rebuilt
it? Or I have to delete all objects from VSS and then add
them again, so that the PBG is rebuilt?
And one last question: Is there a way, on the exe generation
step in Orca, to make the exe be built as specified in the
apps' project? (Instead of that "build executable app.exe
app.icon app.pbr YN (for PBDs))
Oh, and why when I reply to the forum, why my msg doesn't
appear alligned in the msg I replied, only appears as a
reply to the mais post?? :D
Thanks again guys, I'll have a better day today!!!
Daniel
Thank you!!
<Daniel @ attps.com.br> wrote in message
news:473af673.529...@sybase.com...
> Guys, thank you so much! It worked!!
> I excluded the PBG file from VSS (actually I removed all
> files) and added them again. When I added the files again,
> thru PB of course, the PBG was different and it worked!!
You should NEVER have to use the VSS interface to add/remove/checkout
objects. The only time you'd ever need it, as an administrator, would be to
create new users, create branches/pins, etcetera. So, your statement that
"you excluded the PBG file from VSS" confuses me. The PBG files absolutely
MUST be registered as source-controlled in VSS. That's critical. But - YOU
don't have to do it. PB completely manages the .PBG files for you
automatically.
>
> One funny thing about the "new" PBG is that it has 2 entries
> for every PB object in my app. Is this how it should look? I
> remember that PB8 had only one entry!
>
> Example:
> "DWFind2\\dwfind2.sra" "DWFind2\\dwfind2.pbl";
> "Util\\DWFind2\\dwfind2.sra" "Util\\DWFind2\\dwfind2.pbl";
Yes. That's screwed up. A lot of PB's source control functionality depends
on where the .PBW file is in relation to the PBTs and PBLs. I typically
construct my projects with the .PBW as the ONLY file in the Local Root
Folder. All the PBLs, PBTs, PBGs, etc, go in subfolders under that.
I would start over.
- Change the source control to "None".
- Delete and recreate the VSS project
- Delete the .PBG files in your local folders.
- Change the source control back to 'VSS', and re-connect to the project.
- RMB on the target, and select "Add to Source Control..." / "Files
contained in this target".
>
> Is there a way to make orca log all the objects it updated?
Not sure what you mean. Updated? As in "get latest version"?
>
> When I have messed up PBG, is there a way to easily rebuilt
> it? Or I have to delete all objects from VSS and then add
> them again, so that the PBG is rebuilt?
You can change the SCC provider to PBNative, re-register the objects to a
dummy PBNative folder. That will create new .PBG files in your local folder
AND in the PBNative folder. Then, change the source provider back to VSS,
and force a checkin of the .PBG files from the PBNative folder (otherwise
VSS will just re-extract them and overwrite your changes).
>
> And one last question: Is there a way, on the exe generation
> step in Orca, to make the exe be built as specified in the
> apps' project? (Instead of that "build executable app.exe
> app.icon app.pbr YN (for PBDs))
Look at the BUILD PROJECT command in OrcaScript.
a.. build project pblName projectName [ serverName serverPort ]