Skip to content

Bug: concurrent multi-provider submissions collide on idea ID and workspace #80

@laoliu5280

Description

@laoliu5280

Problem

When submitting the same idea with multiple providers in quick succession (e.g., --provider claude, --provider codex, --provider gemini), two bugs cause providers to run in the wrong workspace:

1. Idea ID collision (same-second submissions)

_generate_idea_id() in src/core/idea_manager.py:346 uses %Y%m%d_%H%M%S (1-second resolution) + md5(title)[:8]. Since the title hash is deterministic, two submissions of the same idea in the same second produce identical idea IDs, and the second YAML file overwrites the first.

Fix: Add randomness to the ID — e.g., append a short uuid4 hex or use microsecond precision (%f).

2. github_repo_name metadata overwrite

submit.py:160 writes metadata.github_repo_name to the idea YAML on each submission. When the same idea is submitted for multiple providers, each submit overwrites the previous provider's repo name. The runner (runner.py:176) then reads this single field and directs all providers to the last-submitted provider's workspace.

Fix: Store per-provider workspace info, e.g.:

metadata:
  workspaces:
    claude:
      github_repo_name: idea-slug-fd2b-claude
    codex:
      github_repo_name: idea-slug-318e-codex

Observed behavior

User submitted the same idea with providers claude, codex, and gemini within seconds. Claude ended up running inside the codex-named workspace (reasoning-trace-robustnes-318e-codex) because the codex submission overwrote the YAML metadata last.

Affected files

  • src/core/idea_manager.py_generate_idea_id()
  • src/cli/submit.py — line 160, github_repo_name write
  • src/core/runner.py — line 176, github_repo_name read

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