[Scons-users] Cleaning up a background process
Bill Deegan
bill at baddogconsulting.com
Tue Mar 21 11:37:13 EDT 2017
Also, do you have a small example?
On Tue, Mar 21, 2017 at 11:11 AM, Bill Deegan <bill at baddogconsulting.com>
wrote:
> It should work. It's been the proscribed method for some time, and other
> users have discussed using it as recently as early march.
>
> Which version of SCons/Python and what platform?
>
> -Bill
>
> On Tue, Mar 21, 2017 at 10:29 AM, Brian Cody <brian.j.cody at gmail.com>
> wrote:
>
>> Hey everyone,
>>
>> I have an issue that I pushed aside several months ago that I now need to
>> revisit.
>>
>> A few build steps require a background process to be running. If anything
>> goes wrong during the build, that background process needs to be killed.
>> Also if nothing goes wrong during the build, the process must be killed on
>> completion. It's launched with an action now. There seems to be no
>> consistent way to be able to tell when all targets that would use the
>> process are completed. Instead, I was thinking to register with atexit on
>> spawning the process to hook in the cleanup function.
>>
>> I get that it isn't directly supported but I'm not sure why it isn't
>> working. The atexit._exithandlers list looks good before sys.exit is called
>> in Script/Main.py, but the handlers just aren't called.
>>
>> Is there a known fix for atexit when combined with SCons? Is there any
>> other sort of hook that I may be missing? Or a completely new suggestion?
>>
>> Thank you
>>
>> -Brian
>>
>>
>>
>> _______________________________________________
>> Scons-users mailing list
>> Scons-users at scons.org
>> https://pairlist4.pair.net/mailman/listinfo/scons-users
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://pairlist4.pair.net/pipermail/scons-users/attachments/20170321/6ad266e5/attachment-0001.html>
More information about the Scons-users
mailing list