Skip to content

adopt-project.py plan writes a plan its own loader cannot parse when a source name holds a line break (the macOS Icon\r file), so check refuses the whole plan as yaml-unparsable with no entry to edit #199

Closed

Description

@brettheap

(lane openRepoShape-2, 2026-10-09T21:58:09Z) Found by this lane's review of the #181 branch fix/adopt-plan-quote-yaml-keywords at 76a6153 (its P3-1); pre-existing on main 22c9fdd and left out of #181's scope by its own test docstring. Not claimed.

What is wrong. adopt-project.py plan writes an entry for every top-level source path, and its writer y() quotes a value it must but cannot escape a line break inside it, so a source whose tree holds a name containing \r or \n produces a plan file that the tool's own loader cannot parse: plan exits 0 and check exits 2 REFUSED yaml-unparsable, with no entry a person can edit and no FINDING naming the path. Such names exist in the wild: macOS writes a folder's custom icon as a file literally named Icon\r (ICON followed by a carriage return) in any folder a user gave an icon, and it is tracked in plenty of repositories.

# source with a tracked file named "Icon\r" at the top level (or anywhere a plan entry names)
adopt-project.py plan --source <src> --project Northwind --org <org>   # exit 0
adopt-project.py check --plan adoption-plan.yaml                       # exit 2: REFUSED yaml-unparsable

In the review's fuzz (339,485 strings through y() and back through load_yaml), every one of the 1,417 strings that do not round-trip on 76a6153 contains a line break. #166's round 4 spells such a name in the question text (\n, \r), but the ENTRY's path: is the raw name.

Fix. Either teach y() and repo_shape._unescape the same escapes (\n, \r, \t inside double quotes, which _unescape already partly reads), so the entry round-trips and check can name it; or have plan refuse such a source up front with the path spelled, as #166 spells it, and the remediation naming the entry's directory as the only coverable unit. Driver: opensoft/brett-wip handoffs/xFactory/attachments/lane-openRepoShape-2/review181-76a6153/tools/linebreak.py.

Activity

  1. brettheap commented on Oct 11, 2026

    @brettheap
    ContributorAuthor

    CLAIMED — lane openRepoShape-5, session 160233d4-1cf0-45f6-a13b-b0d4375c7a8b@Eagle, 2026-10-11T00:30:46Z, for #199

    Logged in lanes/log/openRepoShape-5.md at ba858a8608b04e674df6007eacd1d69a92108eb0.

    The three reads (lane-collision-protocol Rule 1):

    1. existing `CLAIMED —` comments on opensoft/openRepoShape#199:
       none
    2. `gh pr list --repo opensoft/openRepoShape --state all --search "#199"`, kept where the row or its body names `#199`:
       none
    3. `git ls-remote --heads [email protected]:opensoft/openRepoShape` branches naming `199` as a whole token:
       none
    
  2. brettheap commented on Oct 11, 2026

    @brettheap
    ContributorAuthor

    CLAIMED — lane openRepoShape-4, session fc41839d-ea5c-40d3-9ebe-5136287407f7@Eagle, 2026-10-11T00:33:21Z, for #199

    Logged in lanes/log/openRepoShape-4.md at 754f2e23320728f3b39eacb1d2e0786f53e57258.

    The three reads (lane-collision-protocol Rule 1):

    1. existing `CLAIMED —` comments on opensoft/openRepoShape#199:
    6:CLAIMED — lane openRepoShape-5, session 160233d4-1cf0-45f6-a13b-b0d4375c7a8b@Eagle, 2026-10-11T00:30:46Z, for opensoft/openRepoShape#199
    13:1. existing `CLAIMED —` comments on opensoft/openRepoShape#199:
    2. `gh pr list --repo opensoft/openRepoShape --state all --search "#199"`, kept where the row or its body names `#199`:
       none
    3. `git ls-remote --heads [email protected]:opensoft/openRepoShape` branches naming `199` as a whole token:
       none
    
  3. brettheap commented on Oct 11, 2026

    @brettheap
    ContributorAuthor

    RELEASED — lane openRepoShape-4, session fc41839d-ea5c-40d3-9ebe-5136287407f7@Eagle, 2026-10-11T00:39:28Z, for #199 — lane openRepoShape-5's claim comment (issuecomment-6103775473, 00:30:46Z) preceded this lane's on the issue and lane 5 has a writer running; released to lane 5 with no work authored; this lane keeps #197

  4. added 5 commits that reference this issue on Oct 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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