@gitgov/core 2.7.0 → 2.7.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { R as RecordStore, b as IRecordProjection, c as IndexData, P as ProjectionContext } from './record_projection.types-Dz9YU3r9.js';
1
+ import { R as RecordStore, b as IRecordProjection, c as IndexData, P as ProjectionContext } from './record_projection.types-D9NkQbL_.js';
2
2
  import { C as ConfigStore, G as GitGovConfig, a as GitGovSession, I as IGitModule, f as CommitInfo, E as ExecOptions, c as ExecResult, d as ChangedFile, e as GetCommitHistoryOptions, g as CommitAuthor } from './index-LULVRsCZ.js';
3
3
  export { M as MemoryFileListerOptions } from './index-LULVRsCZ.js';
4
4
  import { S as SessionStore } from './session_store-I4Z6PW2c.js';
@@ -1,4 +1,4 @@
1
- import { b as IRecordProjection, c as IndexData, P as ProjectionContext } from './record_projection.types-Dz9YU3r9.js';
1
+ import { b as IRecordProjection, c as IndexData, P as ProjectionContext } from './record_projection.types-D9NkQbL_.js';
2
2
 
3
3
  type JsonValue = string | number | boolean | null | JsonValue[] | {
4
4
  [key: string]: JsonValue;
@@ -514,15 +514,7 @@ type EmbeddedMetadataRecord$1 = {
514
514
  /**
515
515
  * The type of the record contained in the payload.
516
516
  */
517
- type: 'actor' | 'agent' | 'task' | 'execution' | 'changelog' | 'feedback' | 'cycle' | 'custom';
518
- /**
519
- * Optional URL to a custom schema for the payload.
520
- */
521
- schemaUrl?: string;
522
- /**
523
- * Optional SHA-256 checksum of the custom schema.
524
- */
525
- schemaChecksum?: string;
517
+ type: 'actor' | 'agent' | 'task' | 'execution' | 'changelog' | 'feedback' | 'cycle';
526
518
  /**
527
519
  * SHA-256 checksum of the canonically serialized payload.
528
520
  */
@@ -607,21 +599,14 @@ type EmbeddedMetadataRecord<T extends GitGovRecordPayload> = {
607
599
  payload: T;
608
600
  };
609
601
 
610
- /**
611
- * A custom record type for testing purposes.
612
- */
613
- type CustomRecord = {
614
- type: 'custom';
615
- data: unknown;
616
- };
617
602
  /**
618
603
  * Defines the possible 'type' values for any record in the system.
619
604
  */
620
- type GitGovRecordType = "actor" | "agent" | "cycle" | "task" | "execution" | "changelog" | "feedback" | "custom";
605
+ type GitGovRecordType = "actor" | "agent" | "cycle" | "task" | "execution" | "changelog" | "feedback";
621
606
  /**
622
607
  * The canonical payload for any GitGovernance record.
623
608
  */
624
- type GitGovRecordPayload = ActorRecord | AgentRecord | CycleRecord | TaskRecord | ExecutionRecord | ChangelogRecord | FeedbackRecord | CustomRecord;
609
+ type GitGovRecordPayload = ActorRecord | AgentRecord | CycleRecord | TaskRecord | ExecutionRecord | ChangelogRecord | FeedbackRecord;
625
610
  /**
626
611
  * The canonical type for any record in GitGovernance, wrapping a payload with metadata.
627
612
  */
@@ -1264,4 +1249,4 @@ interface IRecordProjector {
1264
1249
  invalidateCache(): Promise<void>;
1265
1250
  }
1266
1251
 
1267
- export { type EventMetadata as $, type ActorPayload as A, type CollaborationMetrics as B, type ChangelogPayload as C, DEFAULT_ID_ENCODER as D, type EmbeddedMetadataHeader as E, type FeedbackPayload as F, type GitGovRecord as G, type IRecordMetrics as H, type IdEncoder as I, type ProductivityMetrics as J, RecordMetrics as K, type RecordMetricsDependencies as L, type SystemStatus as M, type TaskHealthReport as N, type ActivityEvent as O, type ProjectionContext as P, type ActorCreatedEvent as Q, type RecordStore as R, type Signature as S, type TaskPayload as T, type ActorRevokedEvent as U, type AgentRegisteredEvent as V, type BaseEvent as W, type ChangelogCreatedEvent as X, type CycleCreatedEvent as Y, type CycleStatusChangedEvent as Z, type EventHandler as _, type IRecordProjector as a, type EventSubscription as a0, type ExecutionCreatedEvent as a1, type FeedbackCreatedEvent as a2, type GitGovEvent as a3, type SystemDailyTickEvent as a4, type TaskCreatedEvent as a5, type TaskStatusChangedEvent as a6, type RecordProjectorDependencies as a7, type IndexGenerationReport as a8, type IntegrityReport as a9, type AllRecords as aa, type DerivedStates as ab, type EnrichedTaskRecord as ac, type DerivedStateSets as ad, type IntegrityError as ae, type IntegrityWarning as af, type IRecordProjection as b, type IndexData as c, type ActorRecord as d, type AgentPayload as e, type AgentRecord as f, type ChangelogRecord as g, type CustomRecord as h, type CyclePayload as i, type CycleRecord as j, type EmbeddedMetadataRecord as k, type ExecutionPayload as l, type ExecutionRecord as m, type FeedbackRecord as n, type GitGovActorRecord as o, type GitGovAgentRecord as p, type GitGovChangelogRecord as q, type GitGovCycleRecord as r, GitGovError as s, type GitGovExecutionRecord as t, type GitGovFeedbackRecord as u, type GitGovRecordPayload as v, type GitGovRecordType as w, type GitGovTaskRecord as x, type TaskRecord as y, type RecordStores as z };
1252
+ export { type EventSubscription as $, type ActorPayload as A, type IRecordMetrics as B, type ChangelogPayload as C, DEFAULT_ID_ENCODER as D, type EmbeddedMetadataHeader as E, type FeedbackPayload as F, type GitGovRecord as G, type ProductivityMetrics as H, type IdEncoder as I, RecordMetrics as J, type RecordMetricsDependencies as K, type SystemStatus as L, type TaskHealthReport as M, type ActivityEvent as N, type ActorCreatedEvent as O, type ProjectionContext as P, type ActorRevokedEvent as Q, type RecordStore as R, type Signature as S, type TaskPayload as T, type AgentRegisteredEvent as U, type BaseEvent as V, type ChangelogCreatedEvent as W, type CycleCreatedEvent as X, type CycleStatusChangedEvent as Y, type EventHandler as Z, type EventMetadata as _, type IRecordProjector as a, type ExecutionCreatedEvent as a0, type FeedbackCreatedEvent as a1, type GitGovEvent as a2, type SystemDailyTickEvent as a3, type TaskCreatedEvent as a4, type TaskStatusChangedEvent as a5, type RecordProjectorDependencies as a6, type IndexGenerationReport as a7, type IntegrityReport as a8, type AllRecords as a9, type DerivedStates as aa, type EnrichedTaskRecord as ab, type DerivedStateSets as ac, type IntegrityError as ad, type IntegrityWarning as ae, type IRecordProjection as b, type IndexData as c, type ActorRecord as d, type AgentPayload as e, type AgentRecord as f, type ChangelogRecord as g, type CyclePayload as h, type CycleRecord as i, type EmbeddedMetadataRecord as j, type ExecutionPayload as k, type ExecutionRecord as l, type FeedbackRecord as m, type GitGovActorRecord as n, type GitGovAgentRecord as o, type GitGovChangelogRecord as p, type GitGovCycleRecord as q, GitGovError as r, type GitGovExecutionRecord as s, type GitGovFeedbackRecord as t, type GitGovRecordPayload as u, type GitGovRecordType as v, type GitGovTaskRecord as w, type TaskRecord as x, type RecordStores as y, type CollaborationMetrics as z };
@@ -1,5 +1,5 @@
1
1
  import { o as IConfigManager, C as ConfigStore, G as GitGovConfig, p as SyncConfig, q as SyncDefaults, m as AuditState, n as AuditStateUpdate, K as KeyProvider, k as ISessionManager, I as IGitModule } from './index-LULVRsCZ.js';
2
- import { W as BaseEvent, _ as EventHandler, a0 as EventSubscription, a3 as GitGovEvent, G as GitGovRecord, w as GitGovRecordType, R as RecordStore, a as IRecordProjector, A as ActorPayload, d as ActorRecord, z as RecordStores$1 } from './record_projection.types-Dz9YU3r9.js';
2
+ import { V as BaseEvent, Z as EventHandler, $ as EventSubscription, a2 as GitGovEvent, G as GitGovRecord, v as GitGovRecordType, R as RecordStore, a as IRecordProjector, A as ActorPayload, d as ActorRecord, y as RecordStores$1 } from './record_projection.types-D9NkQbL_.js';
3
3
 
4
4
  /**
5
5
  * ConfigManager - Project Configuration Manager
@@ -255,6 +255,15 @@ interface ILintModule {
255
255
  * @returns Consolidated lint report
256
256
  */
257
257
  lint(options?: Partial<LintOptions>): Promise<LintReport>;
258
+ /**
259
+ * Validates typed references by prefix (pure, no I/O).
260
+ * Returns warnings for unknown prefixes, errors for empty values.
261
+ *
262
+ * @param record - The GitGovRecord object to validate
263
+ * @param context - Context with recordId and entityType
264
+ * @returns Array of lint results for reference issues
265
+ */
266
+ lintRecordReferences(record: GitGovRecord, context: LintRecordContext): LintResult[];
258
267
  /**
259
268
  * Applies fixes to a record and returns the fixed version.
260
269
  * Does NOT write to disk - returns modified object.
@@ -276,7 +285,7 @@ interface RecordEntry {
276
285
  /** Record ID */
277
286
  id: string;
278
287
  /** Entity type */
279
- type: Exclude<GitGovRecordType, 'custom'>;
288
+ type: GitGovRecordType;
280
289
  /** Optional file path for error reporting (FsLintModule provides this) */
281
290
  filePath?: string;
282
291
  }
@@ -287,7 +296,7 @@ interface LintRecordContext {
287
296
  /** Record ID */
288
297
  recordId: string;
289
298
  /** Entity type */
290
- entityType: Exclude<GitGovRecordType, 'custom'>;
299
+ entityType: GitGovRecordType;
291
300
  /** Optional file path for error reporting */
292
301
  filePath?: string;
293
302
  }
@@ -439,7 +448,7 @@ interface LintResult {
439
448
  /**
440
449
  * Tipos de validadores disponibles en el pipeline.
441
450
  */
442
- type ValidatorType = "SCHEMA_VALIDATION" | "REFERENTIAL_INTEGRITY" | "TYPED_REFERENCE" | "BIDIRECTIONAL_CONSISTENCY" | "EMBEDDED_METADATA_STRUCTURE" | "CHECKSUM_VERIFICATION" | "SIGNATURE_STRUCTURE" | "FILE_NAMING_CONVENTION" | "TEMPORAL_CONSISTENCY" | "ACTOR_RESOLUTION" | "SOFT_DELETE_DETECTION" | "SCHEMA_VERSION_MISMATCH";
451
+ type ValidatorType = "SCHEMA_VALIDATION" | "REFERENTIAL_INTEGRITY" | "BIDIRECTIONAL_CONSISTENCY" | "EMBEDDED_METADATA_STRUCTURE" | "CHECKSUM_VERIFICATION" | "SIGNATURE_STRUCTURE" | "FILE_NAMING_CONVENTION" | "TEMPORAL_CONSISTENCY" | "ACTOR_RESOLUTION" | "SOFT_DELETE_DETECTION" | "SCHEMA_VERSION_MISMATCH";
443
452
  /**
444
453
  * Contexto de ejecución para validación de un record individual.
445
454
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gitgov/core",
3
- "version": "2.7.0",
3
+ "version": "2.7.2",
4
4
  "description": "SDK for the GitGovernance ecosystem, providing a type-safe, local-first API to manage identities, agents, and workflows.",
5
5
  "type": "module",
6
6
  "main": "dist/src/index.js",