Bug
When a file is changed inside a project's root directory but outside its sourceRoot, domino does not mark that project as affected.
Example
Given a project with:
{
"root": "apps/my-app",
"sourceRoot": "apps/my-app/src"
}
If you modify apps/my-app/project.json or apps/my-app/jest.config.js, domino does not detect my-app as affected.
Root cause
ProjectIndex::get_package_names_by_path matches files against source_root only. Files that live in the project root but outside source_root (config files like project.json, jest.config.js, tsconfig.json, etc.) don't match any project.
Additionally, non-source files go through the asset path in find_affected_internal, which also relies on get_package_names_by_path for ownership — so the same blind spot applies there.
Expected behavior
Any changed file inside a project's root should mark that project as affected, regardless of whether it falls under sourceRoot.
Suggested fix
ProjectIndex should also index project root paths (not just source_root), and fall back to root matching when source_root doesn't match. This would ensure config file changes are attributed to their owning project.
Bug
When a file is changed inside a project's
rootdirectory but outside itssourceRoot, domino does not mark that project as affected.Example
Given a project with:
{ "root": "apps/my-app", "sourceRoot": "apps/my-app/src" }If you modify
apps/my-app/project.jsonorapps/my-app/jest.config.js, domino does not detectmy-appas affected.Root cause
ProjectIndex::get_package_names_by_pathmatches files againstsource_rootonly. Files that live in the projectrootbut outsidesource_root(config files likeproject.json,jest.config.js,tsconfig.json, etc.) don't match any project.Additionally, non-source files go through the asset path in
find_affected_internal, which also relies onget_package_names_by_pathfor ownership — so the same blind spot applies there.Expected behavior
Any changed file inside a project's
rootshould mark that project as affected, regardless of whether it falls undersourceRoot.Suggested fix
ProjectIndexshould also index projectrootpaths (not justsource_root), and fall back torootmatching whensource_rootdoesn't match. This would ensure config file changes are attributed to their owning project.