mirror of
https://github.com/openai/codex.git
synced 2026-11-23 15:18:14 +00:00
Track artifact operations from trusted plugin markers (#38057)
## What changed - Recognize validated create and edit marker commands from the trusted presentations, documents, spreadsheets, and PDF plugins. - Emit a `codex_artifact_operation` analytics event plus started-count and expected-output-count metrics when a recognized marker starts through unified exec. - Attribute remote executor commands only when their plugin cache path and script contents match a trusted local plugin, including primary-runtime plugins. ## Testing - Cover supported marker combinations and reject mismatched plugins, paths, arguments, counts, and output formats. - Cover local, relocated remote, and Windows-style plugin attribution, including rejection of modified remote scripts. GitOrigin-RevId: 475cc1689aa7f371a24dec0a8bdb6f7fd5a2e922
This commit is contained in:
1 parent
285abc0368
commit
44d992c14e
18 files changed
+971
-60
No files matched your search
@@ -9,6 +9,8 @@ use crate::facts::AnalyticsJsonRpcError;
|
||||
use crate::facts::AppInvocation;
|
||||
use crate::facts::AppMentionedInput;
|
||||
use crate::facts::AppUsedInput;
|
||||
use crate::facts::ArtifactOperation;
|
||||
use crate::facts::ArtifactOperationInput;
|
||||
use crate::facts::CodexGoalEvent;
|
||||
use crate::facts::CustomAnalyticsFact;
|
||||
use crate::facts::ExternalAgentConfigImportCompletedInput;
|
||||
@@ -269,6 +271,19 @@ impl AnalyticsEventsClient {
|
||||
)));
|
||||
}
|
||||
|
||||
pub fn track_artifact_operation(
|
||||
&self,
|
||||
tracking: TrackEventsContext,
|
||||
operation: ArtifactOperation,
|
||||
) {
|
||||
self.record_fact(AnalyticsFact::Custom(
|
||||
CustomAnalyticsFact::ArtifactOperation(ArtifactOperationInput {
|
||||
tracking,
|
||||
operation,
|
||||
}),
|
||||
));
|
||||
}
|
||||
|
||||
pub fn track_initialize(
|
||||
&self,
|
||||
connection_id: u64,
|
||||
|
||||
Reference in new issue
Block a user