Sync only the declaring module before a run; skip git-ignored paths

`fluksio run` walked the working directory and imported every module in
it, which ran a research repository's analysis scripts before the run was
submitted. A flow's origin now records the file and module name that
declared it, and run/sweep import just that, under the same name so the
generated node bodies do not change. A flow with no record still walks,
now skipping what .gitignore covers.

Every code-defined flow reports `flow` changed once on its next sync,
since the origin gained two fields.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QgG6TJw5qBZzaLghQSRVrq
This commit is contained in:
2026-09-16 16:55:02 +02:00
co-authored by Claude Opus 5
parent 7dfe646e2b
commit fccf89f849
9 changed files with 246 additions and 22 deletions
+10
View File
@@ -1159,6 +1159,16 @@ export const FlowOriginSchema = {
type: 'boolean',
title: 'Dirty',
default: false
},
declared_in: {
type: 'string',
title: 'Declared In',
default: ''
},
module: {
type: 'string',
title: 'Module',
default: ''
}
},
type: 'object',
+2
View File
@@ -364,6 +364,8 @@ export type FlowOrigin = {
repo?: string;
commit?: string;
dirty?: boolean;
declared_in?: string;
module?: string;
};
export type FlowRollup = {