mirror of
https://github.com/openai/codex.git
synced 2026-10-19 17:28:46 +00:00
Expose model upgrade retirement times (#38449)
## What changed - Parse the optional `retirement_at` RFC 3339 value from model upgrade metadata, treating missing, null, or malformed values as unknown. - Expose known retirement times from `model/list` as nullable Unix timestamps in `upgradeInfo.retirementAt` and preserve them when converting app-server models back into model presets. - Update the generated protocol schemas and app-server documentation. ## Testing - Cover absent, null, valid, and malformed catalog values. - Verify `model/list` serialization and app-server model conversion for known, missing, and out-of-range timestamps. GitOrigin-RevId: 969baf9f5b012997f460fb4611ba63c963ee658c
This commit is contained in:
+8
@@ -14041,6 +14041,14 @@
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"retirementAt": {
|
||||
"description": "Informational Unix timestamp for this upgrade's scheduled retirement, if known.",
|
||||
"format": "int64",
|
||||
"type": [
|
||||
"integer",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"upgradeCopy": {
|
||||
"type": [
|
||||
"string",
|
||||
|
||||
+8
@@ -10351,6 +10351,14 @@
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"retirementAt": {
|
||||
"description": "Informational Unix timestamp for this upgrade's scheduled retirement, if known.",
|
||||
"format": "int64",
|
||||
"type": [
|
||||
"integer",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"upgradeCopy": {
|
||||
"type": [
|
||||
"string",
|
||||
|
||||
@@ -197,6 +197,14 @@
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"retirementAt": {
|
||||
"description": "Informational Unix timestamp for this upgrade's scheduled retirement, if known.",
|
||||
"format": "int64",
|
||||
"type": [
|
||||
"integer",
|
||||
"null"
|
||||
]
|
||||
},
|
||||
"upgradeCopy": {
|
||||
"type": [
|
||||
"string",
|
||||
|
||||
BIN
Binary file not shown.
BIN
Binary file not shown.
@@ -2,4 +2,8 @@
|
||||
|
||||
// This file was generated by [ts-rs](https://github.com/Aleph-Alpha/ts-rs). Do not edit this file manually.
|
||||
|
||||
export type ModelUpgradeInfo = { model: string, upgradeCopy: string | null, modelLink: string | null, migrationMarkdown: string | null, };
|
||||
export type ModelUpgradeInfo = { model: string, upgradeCopy: string | null, modelLink: string | null, migrationMarkdown: string | null,
|
||||
/**
|
||||
* Informational Unix timestamp for this upgrade's scheduled retirement, if known.
|
||||
*/
|
||||
retirementAt: number | null, };
|
||||
|
||||
@@ -128,6 +128,9 @@ pub struct ModelUpgradeInfo {
|
||||
pub upgrade_copy: Option<String>,
|
||||
pub model_link: Option<String>,
|
||||
pub migration_markdown: Option<String>,
|
||||
/// Informational Unix timestamp for this upgrade's scheduled retirement, if known.
|
||||
#[ts(type = "number | null")]
|
||||
pub retirement_at: Option<i64>,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, JsonSchema, TS)]
|
||||
|
||||
Reference in New Issue
Block a user