harald/pythonbuilder
1
0
Fork
You've already forked pythonbuilder
0

Option to save state of non-failed targets even if a dependent target then fails #5

Closed
opened 2025年10月21日 17:58:54 +02:00 by harald · 1 comment

Current Situation

If the build fails, no new state is written for any target. The reason is mainly performance as to not write the state file for each updated target.

For example in a sequence of targets updated A->B->C, if C fails, the next time the build is run, the commands to create A and B be run again, even if they were perfectly constructed in the failed build. This is particularly ugly if build A or B is in some way expensive, either time consuming or due to accessing the Internet.

Workaround

Run the build for the working targets separately, then debug the failing target C.

Requirement

Provide one of:

  • To avoid the need for the workaround, provide a simple way to request writing the state file immediately after building each target.
  • Write the state file even if the build fails, making sure, of course that the failed target does not get a fresh state. Consider providing an option state=onsuccess which provides the current behavior. What could be a reason to do so?
# Current Situation If the build fails, no new state is written for any target. The reason is mainly performance as to not write the state file for each updated target. For example in a sequence of targets updated A->B->C, if C fails, the next time the build is run, the commands to create A and B be run again, even if they were perfectly constructed in the failed build. This is particularly ugly if build A or B is in some way expensive, either time consuming or due to accessing the Internet. # Workaround Run the build for the working targets separately, then debug the failing target C. # Requirement Provide one of: - To avoid the need for the workaround, provide a simple way to request writing the state file immediately after building each target. - Write the state file even if the build fails, making sure, of course that the failed target does not get a fresh state. Consider providing an option `state=onsuccess` which provides the current behavior. What could be a reason to do so?
Author
Owner
Copy link

Fixed with e150d9c0ea .

Fixed with e150d9c0ea3efb497535bb4ea698c162c2ed4149 .
Sign in to join this conversation.
No Branch/Tag specified
main
v-2025年10月23日
list
v-2025年09月26日
v-2025年09月21日
v-2025年09月18日
v-2025年08月21日
v-2025年08月17日
v-2025年08月03日
v-2025年07月27日
v-2025年05月31日
v-2025年05月10日
No labels
feature
refactoring
Milestone
Clear milestone
No items
No milestone
Projects
Clear projects
No items
No project
Assignees
Clear assignees
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
harald/pythonbuilder#5
Reference in a new issue
harald/pythonbuilder
No description provided.
Delete branch "%!s()"

Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?