Skip to content

Ability to stop builds without corrupting db #2144

Open

Description

@bdbaddog

This issue was originally created at: 2008-07-18 18:02:05.
This issue was reported by: aligorith.

aligorith said at 2008-07-18 18:02:05

Currently, if trying to cancel a build using the Ctrl-C command in the console on Windows, the scons db (or whatever the mechanism is) could get corrupted and force a full recompile the next time a compilation is done. This is a huge problem if trying to compile a large project on a slow computer.

It would be nice if there was some in-built mechanism to stop a build, without having to resort to using Ctrl-C to kill the process and potentially having to rebuild everthing from scratch. Dunno whether this is possible at all through python

azverkan said at 2008-07-21 19:41:20

This issue is rooted in the differences between Unix and Windows signal handling. There are two types of events on Windows Ctrl-C and Ctrl-Break events which are handled differently for children of processes attached to the console. Some research is needed on how best to address this issue. It might be interesting to see how Cygwin handles this case.

gregnoel said at 2008-07-22 00:17:32

Bug party triage. Brandon to add a comment describing the underlying problem in more detail, and what it might take to solve it.

belley said at 2008-07-22 05:56:05

I noticed that the bug was posted against 0.96.1. There was a significant rework of the handling of the keyboard interrupt signal in 0.98.X. It might be worthwhile to check if the issue is solved in 0.98.5. Note that we do use 0.98.5 on Windows and we are able to interrupt our builds without corrupting the scons db.

Benoit

azverkan said at 2009-03-02 09:26:31

The bug as stated does not seem to be reproducible anymore, but I am able to reproduce a similar bug with roughly the same side effects on both Windows and Linux.

Instead of the .sconsign.dblite being corrupted, if you get lucky, you can get SCons to interrupt where there is only a .sconsign.tmp file and no .sconsign.dblite file on the disk. The next run of SCons will then blast the .sconsign.tmp file and you are then left with an empty .sconsign.dblite file.

Activity

  1. added this to the milestone on Jan 2, 2018
  2. modified the milestones: , Anytime on May 5, 2021
  3. mwichmann commented on Oct 24, 2025

    @mwichmann
    Collaborator

    Is this covered by #2718? Or is it different enough that it's worth keeping both open?

  4. bdbaddog commented on Oct 24, 2025

    @bdbaddog
    ContributorAuthor

    Is this covered by #2718? Or is it different enough that it's worth keeping both open?

    Are either of these still true? I thought we addressed some of this in the past?

  5. mwichmann commented on Oct 25, 2025

    @mwichmann
    Collaborator

    Are either of these still true? I thought we addressed some of this in the past?

    Unsure. I'll try to test the other issue, which has repro code in it. The last comment in the imported flow seems to suggest the original is no longer true, but there are related shutdown issues?

  6. mwichmann commented on Oct 25, 2025

    @mwichmann
    Collaborator

    Okay, sorry for the noise, this is unrelated to the problem in #2718

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions