Skip to content

%temp%\GovCompDisc_Log_(stamp).log naming conflicts fail concurrent builds #1466

@AArnott

Description

@AArnott

This is still a problem.

In #279 (comment), @JamieMagee speculated that adding milliseconds to the filename would be enough to solve the problem. It isn't.

[ERROR] SafelyExecuteAsync logged IOException: The process cannot access the file 'C:\Users\cloudtest\AppData\Local\Temp\GovCompDisc_Log_20250918215134790.log' because it is being used by another process.

We can see that milliseconds were added:

20250918215134790
yyyymmddhhmmssMMM

Yet we are frequently hitting this timing break.
Please add a random element to this. Now, a Random object initialized to the clock (as most are) would produce the same random numbers and still collide. But if you use the PID and/or native thread ID as a distinguisher, you'd be sure to avoid a collision.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions