Documentation
¶
Index ¶
- Constants
- func ProducerFile(command, analyzerCommand, analyzerMode, pythonPath, workingDirectory string) string
- func Run(ctx context.Context, command, pythonPath string, ...) (facts.SemanticPayload, error)
- func RunWithOptions(ctx context.Context, options Options, repository workspace.Repository, ...) (facts.SemanticPayload, error)
- type Options
Constants ¶
const PayloadVersion = 1
Variables ¶
This section is empty.
Functions ¶
func ProducerFile ¶ added in v0.6.0
func ProducerFile(command, analyzerCommand, analyzerMode, pythonPath, workingDirectory string) string
ProducerFile is the file whose content decides the facts of one pass: the bundled script for the adapters that run one, or the resolved executable for an external producer. The fact cache fingerprints it, so a change to the producer forces a re-observation instead of reusing what the previous producer said.
It resolves with the same rules as resolveCommand, on purpose: two resolution rules is how a cache ends up keyed on a file nobody runs. Editing the exact adapter used to leave the fingerprint untouched, and a rebuild republished facts the current code would not produce.
func Run ¶
func Run(ctx context.Context, command, pythonPath string, repository workspace.Repository, workingDirectory string) (facts.SemanticPayload, error)
Run executes the configured Python indexer and decodes its versioned facts. When scip-python is not installed, the repository's deterministic AST worker is used as a development fallback; it intentionally reports dynamic cases as unresolved rather than guessing.
func RunWithOptions ¶
func RunWithOptions(ctx context.Context, options Options, repository workspace.Repository, workingDirectory string) (facts.SemanticPayload, error)
RunWithOptions runs a type-aware producer when exact mode is requested and otherwise preserves the hermetic bundled fallback. External producers use the same JSON payload contract, so the normalizer remains the single source of durable identities and graph semantics.
Types ¶
type Options ¶
type Options struct {
IndexerCommand string
AnalyzerCommand string
AnalyzerMode string
PythonPath string
IncludeTests bool
IncludeGenerated bool
IncludeExternal bool
}
Options configures one Python facts producer. AnalyzerMode is `fallback` for the bundled AST worker or `exact` for a configured type-aware producer.