Skip to content

Improves first run marker logic to better handle concurrent launches#1713

Open
MysticalMount wants to merge 1 commit intodocker:mainfrom
MysticalMount:first-run-improvements
Open

Improves first run marker logic to better handle concurrent launches#1713
MysticalMount wants to merge 1 commit intodocker:mainfrom
MysticalMount:first-run-improvements

Conversation

@MysticalMount
Copy link

Summary

This PR improves the marker logic to better handle concurrent launches, which might prevent numerous starting messages from being displayed when numerous agents start at scale.

Changes

  • Switches to use os.OpenFile in isFirstRun()
  • Adds a unit test to ensure the isFirstRun() function does better handle the concurrent launch
  • Overrides the GetConfigDir function to allow easy testing, this approach has been done elsewhere in flags_test.go

Closes #1709

@MysticalMount MysticalMount requested a review from a team as a code owner February 12, 2026 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[bug] Race condition in isFirstRun

2 participants