qslug Posted August 11, 2011 Report Share Posted August 11, 2011 I have implemented an after-checkin trigger which parses the changed files in order to kick off an automated build process. For some strange combination of changes (the failing checkin has updates, adds, ignores, renames, deletes) the python parsing the file list hangs while reading from stdin. It seems as though Plastic server is not sending an EOF. Fortunately this has only happened for one check-in, but I have yet to find a workaround. If I were on linux I could setup a SIGALRM to kill the read process after x seconds, but sadly I am on windows. Any advice for tracking down the root-cause? Is it possible to fetch the file list using cm query and bypass stdin? Link to comment Share on other sites More sharing options...
miller Posted August 11, 2011 Report Share Posted August 11, 2011 qslug, maybe by activating the logs you can track down the cause. How to enable and activate logs on client/server is fully described on this KB: http://www.plasticscm.com/infocenter/technical-articles/kb-enabling-logging-for-plastic-scm-part-i.aspx Try the command(s) cm help findchanged hope it helps, Miller Link to comment Share on other sites More sharing options...
qslug Posted August 11, 2011 Author Report Share Posted August 11, 2011 Thanks for the advice. I ended up bypassing stdin and use cm find instead. In the batch file which calls the pythons script I replace the read from stdin with: for /F "tokens=2,4,6 delims=:;@" %%A in ("%PLASTIC_CHANGESET%") do ( set CSID=%%A set BRANCH=%%B set REPO=%%C ) cm find revision where changeset=%CSID% on repository '%REPO%' --format="{item}" --nototal> files.temp python AutoBuild.py < files.temp The only catch was that I had to copy my personal client.conf to Documents and Settings\Default User\Local Settings\Application Data\plastic\client.conf so the trigger would be able to use cm commands. ~Cheers Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.