Repository navigation
Expand file tree
/
Copy patherror_codes.yaml
More file actions
5997 lines (5384 loc) · 262 KB
/
Copy patherror_codes.yaml
File metadata and controls
5997 lines (5384 loc) · 262 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# OKG substrate error-code registry.
#
# Every failure the substrate emits on stderr (with --json) or as a
# Python exception must have an entry here. This file is the
# authoritative list; if a code appears in a runbook, contract, or
# agent spec and is not here, that reference is a bug.
#
# Fields:
# code: stable string emitted in JSON error payloads
# python_exception: class name if the code maps to a Python exception
# severity: fatal | recoverable | user
# raised_by: command(s) and/or substrate phases that raise this
# referenced_in: docs that normatively mention this code
# fix_hint_template: string template (positional {0}, {1}, ...)
# that okg CLI may substitute into the fix_hint
# field of the JSON error. `null` = no hint.
# data_shape: required keys in the error's `data` field
#
# Documentation and Python contract checks keep emitted codes and their
# consumer references aligned with this registry.
version: 1
codes:
- code: agent_connect_ephemeral_okg
python_exception: null
severity: user
raised_by:
- okg agent connect
referenced_in:
- docs/reference/cli.md
fix_hint_template: "install okg as a lasting tool first (`uv tool install <okg wheel or source>` or `pipx install <okg wheel or source>`), then re-run this command with that install's `okg`"
data_shape: [interpreter, cache_root]
- code: agent_connect_writes_need_role_passwords
python_exception: null
severity: user
raised_by:
- okg agent connect --writes
referenced_in:
- docs/reference/cli.md
fix_hint_template: "run `okg db role-passwords --apply --deployment {0}`, then re-run this command with --writes"
data_shape: [deployment, roles]
- code: agent_connect_server_failed
python_exception: null
severity: user
raised_by:
- okg agent connect
referenced_in:
- docs/reference/cli.md
fix_hint_template: "run `okg mcp-serve --deployment <name>` by hand and fix the error it prints"
data_shape: [deployment, agent, stderr_tail, tools]
- code: agent_connect_server_timeout
python_exception: null
severity: recoverable
raised_by:
- okg agent connect
referenced_in:
- docs/reference/cli.md
fix_hint_template: "re-run with a larger --probe-timeout, or run `okg mcp-serve --deployment <name>` by hand to see why it is slow"
data_shape: [deployment, agent, stderr_tail, tools]
- code: agent_connect_tools_missing
python_exception: null
severity: user
raised_by:
- okg agent connect
referenced_in:
- docs/reference/cli.md
fix_hint_template: "run `okg doctor --deployment <name>` and fix what it names"
data_shape: [deployment, agent, stderr_tail, tools]
- code: agent_connect_unknown_agent
python_exception: null
severity: user
raised_by:
- okg agent connect
- okg agent disconnect
referenced_in:
- docs/reference/cli.md
fix_hint_template: "choose from claude-code, claude-desktop, cursor, codex"
data_shape: []
- code: agent_runtime_path_binding_invalid
python_exception: null
severity: user
raised_by:
- okg agent-runtime-launch
referenced_in:
- docs/reference/cli.md
fix_hint_template: "re-run `okg agent connect --deployment {0}` to rewrite this registration with the deployment's current paths"
data_shape: [reason_code, trace]
- code: add_source_refused
python_exception: AddSourceError
severity: user
raised_by:
- okg deployment add-source
referenced_in:
- docs/use/sources/index.md
fix_hint_template: "correct the named step (type, settings, access, or deployment) and re-run the same command"
data_shape: [step, cause, deployment]
- code: remove_source_refused
python_exception: RemoveSourceError
severity: user
raised_by:
- okg deployment remove-source
referenced_in:
- docs/use/sources/index.md
fix_hint_template: "run the command the refusal names, then re-run the same remove-source command"
data_shape: [deployment, source, cause]
- code: deployment_archived
python_exception: DeploymentArchived
severity: user
raised_by: [deployment admission]
referenced_in: []
fix_hint_template: "inspect or stop the preserved deployment; obtain an authorized operator lifecycle decision before activation"
data_shape: [deployment, manifest_path, lifecycle, archive_reason]
- code: deployment_not_specified
python_exception: DeploymentNotSpecified
severity: user
raised_by:
- okg dogfood status|doctor|up|down|restart|service
- okg deployment fork-worktree|gc-forks
- okg doctor --check dsn-agreement
- okg doctor --check vector-sets
- okg jobs enqueue-source|find-source-run
- okg pact coord setup plan
- okg search|inspect|expand|filter|aggregate|map|query
referenced_in: []
fix_hint_template: "pass --deployment <name>, set OKG_DEPLOYMENT=<name>, or set graph_projection.deployment in .okg/coordination.yaml"
data_shape: [command]
- code: generation_compacted
python_exception: GenerationCompacted
severity: user
raised_by:
- okg generation describe
- generation-pinned read surfaces
referenced_in:
- docs/runbooks/troubleshooting/storage.md
fix_hint_template: "choose a retained generation from okg generation list"
data_shape: [checkpoint_id, deployment_name, branch, plan_id, compacted_at, reason]
- code: generation_not_found
python_exception: GenerationNotFound
severity: user
raised_by:
- MCP inspect(kind='generation')
referenced_in:
- docs/runbooks/troubleshooting/storage.md
fix_hint_template: "list generations for this deployment and branch, then inspect one of those ids"
data_shape: [requested_generation, deployment_name, branch_name]
- code: generation_out_of_scope
python_exception: GenerationOutOfScope
severity: user
raised_by:
- MCP inspect(kind='generation')
- MCP inspect(kind='node_history') and inspect(kind='subtype_diff'), for a generation off the session branch's history
referenced_in:
- docs/runbooks/troubleshooting/storage.md
fix_hint_template: "read this generation from the deployment and branch that own it"
data_shape: [requested_generation, deployment_name, branch_name, generation_deployment_name, generation_branch]
- code: generation_pin_invalid
python_exception: GenerationPinInvalid
severity: user
raised_by:
- generation-pinned read surfaces (pinned_generation)
referenced_in:
- pact/changes/int-on-chronos-generation-ref/audit.md
fix_hint_template: "set okg.pin_generation to a published Chronos checkpoint id, or RESET it to read the latest published generation"
data_shape: [guc, value]
# ---------- history reads (PACT okg-attribute-history-read) ----------
- code: history_row_budget_exceeded
python_exception: HistoryRowBudgetExceeded
severity: user
raised_by:
- MCP inspect(kind='node_history')
- MCP inspect(kind='subtype_diff')
referenced_in:
- docs/reference/mcp-results.md
fix_hint_template: "diff two closer generations, or read the record at single generations"
data_shape: [budget, budget_name, target_kind]
- code: history_generation_unordered
python_exception: HistoryGenerationUnordered
severity: user
raised_by:
- MCP inspect(kind='node_history')
- MCP inspect(kind='subtype_diff')
referenced_in:
- docs/reference/mcp-results.md
fix_hint_template: "backfill the generation-ordinal registry for this branch, or pass a `from` after the named generations"
data_shape: [generation_ids, unordered_count, branch, deployment_name]
- code: history_range_invalid
python_exception: HistoryRangeInvalid
severity: user
raised_by:
- MCP inspect(kind='node_history')
- MCP inspect(kind='subtype_diff')
referenced_in:
- docs/reference/mcp-results.md
fix_hint_template: "swap the two generations, or omit `from` to start at the oldest"
data_shape: [from_generation, to_generation]
# ---------- extension / host problems ----------
- code: extension_missing
python_exception: ExtensionMissing
severity: fatal
raised_by:
- okg migrate
- okg doctor
referenced_in:
- src/okg/AGENTS.md
fix_hint_template: "pick a managed host that supports {0}, or CREATE EXTENSION if you have privileges"
data_shape: [missing, required]
- code: extension_version_mismatch
python_exception: ExtensionVersionMismatch
severity: fatal
raised_by:
- okg migrate
referenced_in:
- docs/reference/alerts.yaml
fix_hint_template: "upgrade {0} to {1} or pin substrate to the installed version"
data_shape: [extension, installed, required]
- code: postgres_version_too_old
python_exception: PostgresVersionTooOld
severity: fatal
raised_by:
- okg migrate
fix_hint_template: "upgrade Postgres to {0} or later"
data_shape: [observed_major, observed_version_num, required_major]
- code: database_clone_error
python_exception: DatabaseCloneError
severity: fatal
raised_by:
- okg db clone
- safe_recreate_database
referenced_in:
- pact/changes/harden-database-clone-path/design.md
fix_hint_template: null
data_shape: [stage, target_state, target_fenced]
- code: spacy_model_not_installed
python_exception: ModelNotInstalled
severity: error
raised_by:
- SpacyNER.extract
fix_hint_template: "python -m spacy download {0}"
data_shape: [model]
- code: gliner_model_not_installed
python_exception: GLiNERModelNotInstalled
severity: error
raised_by:
- GLiNERBackend.extract
fix_hint_template: "pip install 'akmon[nlp]' / fetch model {0}"
data_shape: [model]
- code: extractor_chain_missing
python_exception: ExtractorChainMissing
severity: fatal
raised_by:
- okg.substrate.library.extraction.registry.load_extractors
fix_hint_template: "fix the offending {0} entry in extractors.yaml"
data_shape: [class, config_keys]
- code: extractor_axis_missing
python_exception: ExtractorAxisMissing
severity: error
raised_by:
- okg.substrate.library.extraction.registry.load_extractors
fix_hint_template: "add {0} block to extractors.yaml"
data_shape: [axis]
- code: overlay_generation_unmaterialized
python_exception: null
severity: user
raised_by:
- okg.substrate.attributes.require_overlay_generation_marker
- okg.substrate.mcp.graph_read.require_graph_pin
# The MCP readers send require_graph_pin's hint; with no marker table it is
# "an operator runs `okg migrate --apply`, which also writes the markers".
fix_hint_template: "pin an earlier generation that has its marker (see `okg generation list --deployment <name>`), or publish this branch again: a publish that succeeds writes the marker, and a read with no generation_id then pins it. That publish can itself be refused; its refusal names its own fix"
# require_graph_pin adds `cause` (overlay_step_not_run or
# marker_table_missing).
data_shape: [generation_id, namespace, marker_table_present]
- code: overlay_ranges_out_of_order
python_exception: null
severity: fatal
raised_by:
- okg.substrate.attributes.sync_overlay_ranges_for_generation
fix_hint_template: "re-materialize only the branch's latest generation"
data_shape: [generation_id, branch_id, ordinal, last_synced_ordinal]
- code: enricher_load_error
python_exception: EnricherLoadError
severity: fatal
raised_by:
- okg.substrate.publisher.enricher_loader.load_enrichers
fix_hint_template: "fix the offending enrichers entry in deployment.yaml"
data_shape: [class, config_keys]
- code: enricher_narrowings_missing
python_exception: EnricherNarrowingsMissing
severity: fatal
raised_by:
- okg.substrate.publisher.enricher_loader.validate_enricher_narrowings
fix_hint_template: "declare the missing narrowings in the relevant ontology's EdgeNarrowings"
data_shape: [catalog_version_id, missing]
- code: enricher_envelope_missing
python_exception: EnricherEnvelopeMissing
severity: fatal
raised_by:
- okg.substrate.publisher.enricher_loader.derive_write_envelope
- okg.substrate.publisher.enricher_loader.validate_enricher_envelopes
fix_hint_template: "declare requires_narrowings / emits_typed_subtype (the envelope derives from them) or an explicit write_envelope mapping; a model-calling operator must declare nondeterministic = True"
data_shape: [enricher, producer_id]
- code: enricher_support_policy_invalid
python_exception: EnricherSupportPolicyInvalid
severity: fatal
raised_by:
- okg.substrate.publisher.enricher_loader.validate_enricher_support_policies
fix_hint_template: "declare `support_policy: DerivedSupportPolicy = \"all_members\"` (or \"any_member\") on the node-writing enricher class; the derived-node liveness policy has no safe default"
data_shape: [enricher, producer_id, support_policy, allowed]
- code: enricher_backfill_selection_error
python_exception: EnricherBackfillSelectionError
severity: user
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.select_enricher
fix_hint_template: "check the deployment's enrichers block and pass exactly one registered enricher name"
data_shape: [deployment, enricher_name, matches]
- code: enricher_backfill_branch_unsupported
python_exception: EnricherBackfillBranchUnsupported
severity: user
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.run_enricher_backfill
fix_hint_template: "run targeted enricher backfill on the default branch; branch-scoped normal enricher progress is required before non-default branches are supported"
data_shape: [deployment, enricher_name, branch_name]
- code: enricher_backfill_unsafe_enricher
python_exception: EnricherBackfillUnsafeEnricher
severity: user
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.run_enricher_backfill
fix_hint_template: "set targeted_backfill_chunk_safe only after the enricher strictly scopes work and emitted edge facts to incremental.dirty_node_ids"
data_shape: [deployment, enricher_name, required_capability]
- code: enricher_backfill_unsupported_output
python_exception: EnricherBackfillUnsupportedOutput
severity: user
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.run_enricher_backfill
fix_hint_template: "use normal publish for node-emitting enrichers until targeted node-fact admission is implemented"
data_shape: [deployment, enricher_name, unsupported_fields]
- code: enricher_backfill_admission_rejected
python_exception: EnricherBackfillAdmissionRejected
severity: error
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.run_enricher_backfill
fix_hint_template: "fix the enricher producer policy or emitted edge triples, then retry the chunk"
data_shape: [deployment, enricher_name, chunk_index, input_node_ids, verdicts]
- code: enricher_backfill_chunk_failed
python_exception: EnricherBackfillChunkFailed
severity: error
raised_by:
- okg enricher backfill
- okg.substrate.enrichers.backfill.run_enricher_backfill
fix_hint_template: "fix the enricher exception and retry; the failed chunk was not marked complete"
data_shape: [deployment, enricher_name, chunk_index, input_node_ids, error]
- code: consistency_gate_load_error
python_exception: ConsistencyGateLoadError
severity: fatal
raised_by:
- okg.substrate.consistency.sql_gate.load_consistency_gates
fix_hint_template: "fix the offending consistency_gates entry in deployment.yaml"
data_shape: [where, field, token]
- code: ir_consistency_check_load_error
python_exception: IrCheckLoadError
severity: fatal
raised_by:
- okg.substrate.consistency.ir_check.load_ir_consistency_checks
fix_hint_template: "fix the offending ir_consistency_checks entry (or its program_ref / surfaces) in deployment.yaml"
data_shape: [where, field, check_id, program_ref, surface, missing, extras, errors]
- code: undeclared_finding_identity
python_exception: UndeclaredFindingIdentity
severity: fatal
raised_by:
- okg.substrate.consistency.ir_executor._normalized_values
fix_hint_template: "declare normalized_value_columns on the ir_consistency_checks entry (the closure that keys finding identity); the executor no longer falls back to the whole offender row"
data_shape: [check_id]
- code: post_publish_generation_unresolved
python_exception: PostPublishGenerationUnresolved
severity: fatal
raised_by:
- okg.substrate.consistency.chronos_sql_mirror.checkout_published_generation
fix_hint_template: "pass the checkpoint id of a retained published generation (okg generation list); post-publish checks never read the live branch head"
data_shape: [generation_id, purpose, error_type]
- code: chronos_sql_mirror_mismatch
python_exception: ChronosSqlMirrorMismatch
severity: fatal
raised_by:
- okg.substrate.consistency.chronos_sql_mirror.ChronosSqlMirrorReads.reading
fix_hint_template: "rerun the check with okg consistency-rerun --generation <id>"
data_shape: [expected_checkpoint_id, held_checkpoint_id, reason]
- code: doctor_check_load_error
python_exception: DoctorCheckLoadError
severity: user
raised_by:
- okg.substrate.doctor.load_deployment_doctor_checks
referenced_in:
- src/okg/substrate/doctor.py
fix_hint_template: "fix the offending doctor_checks entry in deployment.yaml"
data_shape: []
- code: edge_ranking_changed_during_write
python_exception: EdgeRankingChangedDuringWrite
severity: recoverable
raised_by:
- okg.substrate.graph_store_internal.writes.ChronosGraphWriteMixin.apply_facts
referenced_in:
- docs/develop/architecture/pipeline.md
fix_hint_template: "the edge ranking changed during this write; rerun it"
data_shape: [branch, planned_edge_types, current_edge_types]
- code: edge_ranking_change_busy
python_exception: EdgeRankingChangeBusy
severity: recoverable
raised_by:
- okg migrate --deployment
- okg worker (start)
referenced_in:
- docs/develop/architecture/pipeline.md
fix_hint_template: "graph writers are busy on branch {0}; retry the ranking change"
data_shape: [branch, deployment]
- code: graph_written_during_publish
python_exception: null
severity: recoverable
raised_by:
- okg.substrate.publisher.publisher.Publisher._chronos_refuse_writes_since_counted
referenced_in: []
fix_hint_template: "re-run the publish: the rows written during this one are still unpublished and the next cycle counts them"
data_shape: [branch, stage, segment_signature_counted, segment_signature_now]
- code: no_applied_catalog
python_exception: null
severity: error
raised_by:
- okg.substrate.cli.main._cmd_catalog_reconcile
fix_hint_template: "run `okg catalog load --apply` first"
data_shape: []
- code: deployment_not_found
python_exception: null
severity: user
raised_by:
- okg.substrate.runtime.source_sync_workflow.okg_source_sync
- okg.substrate.cli.main._cmd_mcp_serve
- okg.substrate.cli.init.deployments_env_root_error
- okg agent connect
referenced_in:
- pact/changes/mcp-serve-typed-deployment-error
- pact/changes/s14-2127-install-release-shape
fix_hint_template: "check deployments/<name>/ exists or OKG_DEPLOYMENTS_DIR"
# `data_shape` lists the keys EVERY raiser sets, so it stays at two.
# The scaffold raiser (`deployments_env_root_error`, used by okg install
# and okg init) adds `env_var: OKG_DEPLOYMENTS_DIR`, and reports
# `deployment: null` because it refuses before any deployment is
# resolved -- the root itself is what could not be found.
data_shape: [deployment, resolution_error]
- code: source_sync_payload_invalid
python_exception: null
severity: user
raised_by:
- okg.substrate.runtime.source_sync_workflow.okg_source_sync
fix_hint_template: "enqueue source-sync work through DBOS runtime APIs"
data_shape: [job_id, payload]
- code: source_sync_ingest_failed
python_exception: null
severity: recoverable
raised_by:
- okg.substrate.runtime.source_sync_workflow.okg_source_sync
fix_hint_template: "inspect the failed source result and retry after repair"
data_shape: [deployment, ordered, results, publishes, skipped]
- code: latex_project_legacy_mismatch
python_exception: LatexProjectLegacyMismatch
severity: fatal
raised_by:
- okg.substrate.library.sources.scholarly.bib_references.assert_legacy_record_set_matches_graph
referenced_in:
- src/okg/substrate/library/sources/scholarly/bib_references.py
fix_hint_template: "restore the exact legacy ownership id and files, or repair the live owned graph before migration"
data_shape: [source_name]
- code: latex_project_manifest_mismatch
python_exception: LatexProjectManifestMismatch
severity: fatal
raised_by:
- okg.substrate.library.sources.scholarly.latex_project.LatexProjectSource
referenced_in:
- src/okg/substrate/library/sources/scholarly/latex_project.py
fix_hint_template: "run the manifest-aware SourceFile, document-corpus, and bibliography predecessors with the same project manifest before retrying"
data_shape: [expected_manifest_digest, predecessor_digests, mismatches]
- code: runtime_source_sync_active
python_exception: null
severity: recoverable
raised_by:
- okg.substrate.cli.main._cmd_ingest
fix_hint_template: "wait for active source-sync DBOS work to drain or rerun without --inline; if the worker is stopped, start it or cancel the stranded workflow with `okg runtime cancel-workflow`"
data_shape: [deployment, queue_name, active_count, active_rows]
- code: runtime_source_sync_probe_failed
python_exception: null
severity: recoverable
raised_by:
- okg.substrate.cli.main._cmd_ingest
fix_hint_template: "rerun without --inline so DBOS admits the work, or inspect `okg sync health --deployment <name> --json`"
data_shape: [deployment, error]
- code: deployment_runtime_config_unresolved
python_exception: null
severity: user
raised_by:
- okg.substrate.cli.main._deployment_runtime_enabled
fix_hint_template: "fix deployment.yaml or run `uv run okg deployment ready <deployment> --json`"
data_shape: [deployment, error]
- code: deployment_environment_invalid
python_exception: DeploymentEnvironmentInvalid
severity: user
raised_by:
- okg.substrate.cli.environment._cmd_environment
fix_hint_template: "fix the named environment descriptor, secret reference, database target, or colliding resource identity"
data_shape: [environment, environments_root]
- code: source_activation_probe_invalid
python_exception: SourceActivationProbeInvalid
severity: user
raised_by:
- okg.substrate.ingest.service._validate_deferred_source_activation
fix_hint_template: "add a sound source-owned runtime change probe and supported poll selector before enabling or explicitly ingesting the source"
data_shape: [sources]
- code: source_configuration_authority_invalid
python_exception: SourceConfigurationAuthorityInvalid
severity: user
raised_by:
- okg.substrate.deployments.sync_root.require_usable_source_configuration_authority
fix_hint_template: "repair the declared source-root authority so it names an existing authoritative directory; sealed processes repair launcher authority and long-lived workers restart after local-profile changes"
data_shape: [configured_path, canonical_path, reason]
- code: sealed_release_invalid
python_exception: SealedReleaseInvalid
severity: error
raised_by:
- okg.substrate.sealed_release.prepare_sealed_release
- okg.substrate.sealed_release.verify_sealed_release
- okg.substrate.release_activation.activate_environment_release
- okg.substrate.runtime.release_authority.verify_worker_release_authority
- okg.substrate.runtime.release_launcher.verify_launch
fix_hint_template: "repair the declared revision/config inputs, active pointer, or trusted runtime root; remove incomplete artifacts and prepare again"
data_shape: [artifact_id, artifact_root, expected, observed, command]
- code: release_kind_invalid
python_exception: ReleaseKindInvalid
severity: user
raised_by:
- okg.substrate.deployment_release.declared_release_kind
- okg.substrate.deployment_release.ReleaseArtifact.from_mapping
referenced_in:
- docs/operate/deployments/external.md
fix_hint_template: "set `release.kind` to packaged or standalone, or remove the key for a deployment tracked in a Git checkout"
data_shape: [deployment, observed, allowed]
- code: installed_framework_modified
python_exception: InstalledFrameworkModified
severity: user
raised_by:
- okg.substrate.distributions.installed_framework.installed_framework_distribution
referenced_in:
- docs/operate/deployments/external.md
fix_hint_template: "reinstall okg from its wheel so the installed files match the wheel's RECORD, then re-run the failed command"
data_shape: [distribution, version, modified, modified_count]
- code: framework_tree_unavailable
python_exception: FrameworkTreeUnavailable
severity: user
raised_by:
- okg.substrate.framework_tree.framework_tree_root
referenced_in:
- docs/operate/deployments/external.md
fix_hint_template: "point OKG_FRAMEWORK_TREE at the directory that holds okg's src/okg, deployments/ and ops/ (/opt/okg in the runtime image), or unset it"
data_shape: [env, value]
- code: standalone_release_conflict
python_exception: StandaloneReleaseConflict
severity: user
raised_by:
- okg.substrate.publisher.factory.build_deployment_publisher
- okg.substrate.deployment_release.current_release_artifact
- okg.substrate.deployment_release.ReleaseArtifact.from_mapping
referenced_in:
- docs/operate/deployments/external.md
fix_hint_template: "remove `release.kind: standalone` from the deployment.yaml, or stop publishing this deployment under the conflicting packaged or sealed release authority"
data_shape: [deployment, deployment_dir, declared_kind, conflicting_authority]
- code: standalone_upgrade_unsupported
python_exception: StandaloneUpgradeUnsupported
severity: user
raised_by:
- okg.substrate.deployment_upgrade.run_deployment_upgrade
- okg.substrate.deployment_upgrade.run_deployment_backup_verify
referenced_in:
- docs/operate/lifecycle.md
- docs/operate/deployments/external.md
fix_hint_template: "take your own database backup with pg_dump before changing this deployment; if it really lives in a committed Git checkout, remove `release.kind: standalone` from its deployment.yaml. `okg up` no longer raises this: it upgrades a standalone deployment as an installed package"
data_shape: [deployment, release_kind, operation, reason]
- code: installed_upgrade_incompatible
python_exception: InstalledUpgradeIncompatible
severity: user
raised_by:
- okg.substrate.deployment_installed_upgrade.run_installed_upgrade
referenced_in:
- docs/operate/lifecycle.md
fix_hint_template: "fix the deployment for the listed blockers and breaking changes (release notes link included when known), or go back by reinstalling the okg version you upgraded from; nothing was changed"
data_shape: [step, contract_source, verdict, exit_code, from_version, to_version, breaking_affecting_this_deployment, blockers, unknowns, release_notes, go_back]
- code: installed_upgrade_compat_unknown
python_exception: InstalledUpgradeCompatUnknown
severity: user
raised_by:
- okg.substrate.deployment_installed_upgrade.run_installed_upgrade
referenced_in:
- docs/operate/lifecycle.md
fix_hint_template: "pass the previous release's contract with --from-contract FILE, or rerun with --accept-unknown-compat to upgrade without knowing; nothing was changed"
data_shape: [step, contract_source, verdict, exit_code, from_version, to_version, reasons, go_back]
- code: installed_upgrade_refused
python_exception: InstalledUpgradeRefused
severity: user
raised_by:
- okg.substrate.deployment_installed_upgrade.run_installed_upgrade
referenced_in:
- docs/operate/lifecycle.md
fix_hint_template: "drop the okg up options that only apply to a Git-checkout deployment (including --dsn: the database is the one deployment.yaml names), or fix the named input (--from-contract file, --backup-dir inside a Git work tree, wheel install, unfinished-upgrade marker, deployment database); an okg older than the receipt's is refused: go back with okg deployment backup restore"
data_shape: [deployment]
- code: installed_upgrade_worker_unsupervised
python_exception: InstalledUpgradeWorkerUnsupervised
severity: user
raised_by:
- okg.substrate.deployment_installed_upgrade.run_installed_upgrade
referenced_in:
- docs/operate/lifecycle.md
- docs/reference/cli.md
fix_hint_template: "okg up cannot manage this deployment's runtime worker and changed nothing. With a systemd system worker service (an enabled okg-runtime-worker@<deployment>.service whose template okg renders for this deployment), run okg up as root. Without one, on Linux, install it as root first (okg dogfood service install --deployment <deployment> --adapter systemd --apply); on macOS install the launchd plist (--adapter launchd, no root). If the reload check is unavailable, fix what okg deployment ready reports for the apply check. Per-user systemd worker services are planned as the first follow-up after 2026-10-17"
data_shape: [deployment, reason, runtime_enabled, pids, commands, service, worker_reload, upgrade_command, install_service_command, follow_up, resumed_upgrade]
- code: installed_release_receipt_unreadable
python_exception: InstalledReceiptUnreadable
severity: user
raised_by:
- okg.substrate.deployment_installed_upgrade.read_installed_release_receipt
referenced_in:
- docs/operate/lifecycle.md
fix_hint_template: "inspect ${OKG_USER_HOME:-$XDG_DATA_HOME/okg}/state/deployments/<deployment>/installed-release.json; if it is damaged or was written for another deployment directory, move it aside and pass the previous release's contract with --from-contract, or --accept-unknown-compat"
data_shape: [path, reason]
- code: installed_restore_refused
python_exception: InstalledRestoreRefused
severity: user
raised_by:
- okg.substrate.deployment_installed_restore.run_installed_restore
referenced_in:
- docs/operate/lifecycle.md
- docs/reference/cli.md
fix_hint_template: "restore only the pre_upgrade_archive `okg up` recorded for this installed deployment, with its owner-only <archive>.json sidecar, unchanged, from the same database, as a superuser (required with TimescaleDB) or, without TimescaleDB, a role with CREATEDB and membership in the database owner's role; restore any other archive into a separate database with okg db clone --restore-dump"
data_shape: []
- code: sealed_release_revision_missing
python_exception: SealedReleaseRevisionMissing
severity: error
raised_by:
- okg.substrate.sealed_release.prepare_environment_release
fix_hint_template: "seal a release only from a committed Git checkout; a standalone or packaged deployment records no code revision and cannot be sealed"
data_shape: [field, observed]
- code: gh_cli_missing
python_exception: GhCliMissing
severity: error
raised_by:
- okg.substrate.library.sources.github.GitHubSource._fetch_via_gh
fix_hint_template: "install gh (https://cli.github.com/) and run `gh auth login`"
data_shape: [adapter, repo]
- code: forge_references_unresolved
python_exception: ForgeReferencesUnresolved
severity: error
raised_by:
- okg.substrate.library.linkers.forge_references
fix_hint_template: "reference tokens were found but none resolved; check the corpus bounds and the number vocabulary rather than reading zero resolutions as a repository nobody cross-referenced"
data_shape: [adapter, repo, counts]
- code: forge_discussion_empty
python_exception: ForgeDiscussionError
severity: error
raised_by:
- okg.substrate.library.sources.github.GitHubSource
fix_hint_template: "the payload carried discussion or merge rows but the parse emitted none; check the fixture's comment/pull shape rather than reading zero as a quiet repository"
data_shape: [adapter, repo, counts]
- code: concept_aliases_path_missing
python_exception: ConceptAliasesPathMissing
severity: user
raised_by:
- okg.substrate.library.sources.concept_aliases
fix_hint_template: "set params.aliases_path to an existing aliases YAML/JSON file"
data_shape: []
- code: concept_aliases_parse_error
python_exception: ConceptAliasesParseError
severity: user
raised_by:
- okg.substrate.library.sources.concept_aliases
fix_hint_template: "fix the concept aliases file syntax"
data_shape: [path]
- code: concept_aliases_no_dsn
python_exception: ConceptAliasesNoDsn
severity: user
raised_by:
- okg.substrate.library.sources.concept_aliases
fix_hint_template: "supply params.dsn with the deployment-resolved Postgres DSN"
data_shape: []
- code: engram_source_config_error
python_exception: EngramSourceConfigError
severity: user
raised_by:
- okg.substrate.library.sources.engram_runs._common
fix_hint_template: "load the reasoning ontology module before enabling engram_runs sources"
data_shape: [source_name, loaded_modules]
- code: experiment_record_parse_error
python_exception: ExperimentRecordParseError
severity: user
raised_by:
- okg.substrate.library.sources.experimental.experiment_records
fix_hint_template: "fix the experiment record YAML/JSON input"
data_shape: [path]
- code: result_schema_error
python_exception: ResultSchemaError
severity: user
raised_by:
- okg.substrate.library.sources.experimental.bench_outputs
fix_hint_template: "fix the benchmark result record schema"
data_shape: []
- code: success_condition_predicate_parse_error
python_exception: PredicateParseError
severity: user
raised_by:
- okg.substrate.library.sources.experimental.experiment_records
- okg.substrate.library.sources.experimental.predicates
fix_hint_template: "fix the success-condition predicate expression"
data_shape: []
- code: cluster_pull_mode_not_implemented
python_exception: ClusterPullModeError
severity: user
raised_by:
- okg.substrate.library.sources.experimental.cluster_jobs
fix_hint_template: "use operator-pulled cluster inputs until substrate-pulled mode is implemented"
data_shape: []
- code: transcript_fetch_error
python_exception: TranscriptFetchError
severity: recoverable
raised_by:
- okg.substrate.library.sources.scholarly.talks
fix_hint_template: "verify the video URL, captions, and network access"
data_shape: [youtube_id, underlying_error]
- code: persona_load_error
python_exception: PersonaLoadError
severity: user
raised_by:
- okg.substrate.library.personas
fix_hint_template: "fix the persona YAML file"
data_shape: [path]
- code: persona_slug_collision
python_exception: PersonaSlugCollision
severity: user
raised_by:
- okg.substrate.library.personas
fix_hint_template: "rename the deployment persona slug"
data_shape: [slug, path]
- code: persona_unknown
python_exception: PersonaUnknown
severity: user
raised_by:
- okg.substrate.mcp.review_as
fix_hint_template: "choose a registered persona slug"
data_shape: [persona, slug]
- code: persona_prompt_missing
python_exception: PersonaPromptMissing
severity: user
raised_by:
- okg.substrate.mcp.review_as
fix_hint_template: "add the persona prompt file or update the prompt reference"
data_shape: [path]
- code: context_packet_definition_invalid
python_exception: ContextPacketDefinitionError
severity: fatal
raised_by:
- okg.substrate.library.ontologies.reasoning.derived_artifacts.context_packet
fix_hint_template: "fix the substrate-shipped context_packet.yaml definition"
data_shape: [path]
- code: pre_join_tool_schema_error
python_exception: PreJoinSchemaError
severity: user
raised_by:
- okg.substrate.mcp.framework.resolvers
- okg.substrate.mcp.framework.schema
fix_hint_template: "fix the pre-join tool YAML schema"
data_shape: []
- code: pre_join_tool_step_kind_unknown
python_exception: PreJoinStepKindUnknown
severity: user
raised_by:
- okg.substrate.mcp.framework.schema
fix_hint_template: "use a supported pre-join tool step kind"
data_shape: [name, index, call]
- code: pre_join_tool_traverse_hops_exceeded
python_exception: PreJoinTraverseHopsExceeded
severity: user
raised_by:
- okg.substrate.mcp.framework.schema
fix_hint_template: "reduce traverse_path max_hops to the substrate limit"
data_shape: [name, index]
- code: pre_join_tool_resolver_unknown
python_exception: PreJoinResolverUnknown
severity: user
raised_by:
- okg.substrate.mcp.framework.resolvers
fix_hint_template: "register the named resolver or update the pre-join tool YAML"
data_shape: [name, resolver]
- code: pre_join_tool_summary_template_error
python_exception: PreJoinSummaryTemplateError
severity: recoverable
raised_by:
- okg.substrate.mcp.framework.executor
fix_hint_template: "fix the pre-join summary_template"
# Executor logs a warning and returns the literal template; no structured error is raised.
data_shape: []
- code: pre_join_tool_error
python_exception: PreJoinToolError
severity: recoverable
raised_by:
- okg.substrate.mcp.fan_out
- okg.substrate.mcp.framework.executor
- okg.substrate.mcp.review_as
fix_hint_template: "inspect the pre-join tool step failure"
data_shape: []
- code: alias_backend_load_error
python_exception: AliasBackendLoadError
severity: fatal
raised_by:
- okg.substrate.alias.loader.load_alias_resolver
fix_hint_template: "fix the offending alias_resolver entry in deployment.yaml"
data_shape: [class, config_keys]
- code: alias_resolution_failed
python_exception: AliasResolutionFailed
severity: error
raised_by:
- okg.substrate.alias.cascade.CascadeAliasResolver.resolve
fix_hint_template: "lower a backend threshold or set on_empty='drop'"
data_shape: [needle, entity_type, per_backend_top_score]
- code: entity_resolution_failed
python_exception: EntityResolutionError
severity: fatal
raised_by:
- okg.substrate.entity_resolution.EntityResolutionStage
referenced_in:
- docs/reference/database-schema.md
- docs/develop/extensions/ontologies.md
fix_hint_template: "inspect the chained resolution failure and retry; do not mint around the failed stage"
data_shape: []
- code: entity_resolution_rejected
python_exception: EntityResolutionRejected
severity: user
raised_by:
- okg.substrate.entity_resolution.EntityResolutionStage
- okg.substrate.entity_resolution.mint_entity_id
referenced_in:
- docs/reference/database-schema.md
- docs/develop/extensions/ontologies.md
fix_hint_template: "correct the extracted identity or the deployment post-filter policy, then retry"
data_shape: []
- code: entity_resolution_ambiguous
python_exception: EntityResolutionAmbiguous
severity: recoverable
raised_by:
- okg.substrate.entity_resolution.EntityResolutionStage
referenced_in:
- docs/reference/database-schema.md
- docs/develop/extensions/ontologies.md
fix_hint_template: "resolve conflicting aliases or duplicate live identities before retrying"
data_shape: []
- code: entity_resolution_unavailable
python_exception: EntityResolutionUnavailable
severity: recoverable
raised_by:
- okg.substrate.entity_resolution.EntityResolutionStage
referenced_in:
- docs/reference/database-schema.md
- docs/develop/extensions/ontologies.md
fix_hint_template: "restore the required catalog, graph, policy, or escalation dependency before retrying"
data_shape: []
- code: embedding_backend_not_installed
python_exception: EmbeddingBackendNotInstalled
severity: error
raised_by:
- okg.substrate.alias.backends.embedding.EmbeddingAliasBackend
fix_hint_template: "pass embedder= when constructing EmbeddingAliasBackend"
data_shape: []
- code: embedder_spec_invalid
python_exception: null
severity: error
raised_by:
# ONE parser as of PACT reachable-semantic-search; the CLI and the embed
# workflow both delegate here. Two copies meant the WRITER of embeddings
# and the READER could disagree about what a spec means.
- okg.substrate.embeddings.identity.build_embedder
- okg.substrate.embeddings.identity.model_id_for_spec
fix_hint_template: "use 'hash' or 'sentence-transformers:<model>'"
data_shape: []
- code: embedder_identity_undeclared
python_exception: null
severity: error
raised_by:
- okg.substrate.embeddings.identity.embedder_model_id