fix: openapi for eval-task (#1085)

# What does this PR do?
- as title

## Test Plan
- the deprecated endpoint need to obey what it was before

[//]: # (## Documentation)
This commit is contained in:
Xi Yan 2025-02-13 17:10:45 -08:00 committed by GitHub
parent 2a8e199e10
commit da53dc3f5f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 5 additions and 5 deletions

View file

@ -81,7 +81,7 @@
"deprecated": true "deprecated": true
} }
}, },
"/v1/eval-tasks/{task_id}": { "/v1/eval-tasks/{eval_task_id}": {
"get": { "get": {
"responses": { "responses": {
"200": { "200": {
@ -109,7 +109,7 @@
"parameters": [ "parameters": [
{ {
"name": "eval_task_id", "name": "eval_task_id",
"in": "query", "in": "path",
"required": true, "required": true,
"schema": { "schema": {
"type": "string" "type": "string"

View file

@ -35,7 +35,7 @@ paths:
$ref: '#/components/schemas/DeprecatedEvaluateRowsRequest' $ref: '#/components/schemas/DeprecatedEvaluateRowsRequest'
required: true required: true
deprecated: true deprecated: true
/v1/eval-tasks/{task_id}: /v1/eval-tasks/{eval_task_id}:
get: get:
responses: responses:
'200': '200':
@ -51,7 +51,7 @@ paths:
description: '' description: ''
parameters: parameters:
- name: eval_task_id - name: eval_task_id
in: query in: path
required: true required: true
schema: schema:
type: string type: string

View file

@ -68,7 +68,7 @@ class Benchmarks(Protocol):
@webmethod(route="/eval-tasks", method="GET") @webmethod(route="/eval-tasks", method="GET")
async def DEPRECATED_list_eval_tasks(self) -> ListBenchmarksResponse: ... async def DEPRECATED_list_eval_tasks(self) -> ListBenchmarksResponse: ...
@webmethod(route="/eval-tasks/{task_id}", method="GET") @webmethod(route="/eval-tasks/{eval_task_id}", method="GET")
async def DEPRECATED_get_eval_task( async def DEPRECATED_get_eval_task(
self, self,
eval_task_id: str, eval_task_id: str,