Hacktoberfest 2026:維護者為十月標記出來的 issue,仍然開放、適合新手。 瀏覽 Hacktoberfest issue

Filter format inconsistent with UI

未關閉
#831 2 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

評估

難度
2/5
預估耗時
1-3 小時
新手友好度
48/100
Issue 類型
缺陷
描述清晰度
基本清楚
活躍度
停滯
技術堆疊
python
領域
api

研究方向

從重現中提到的進入點 Client.get_runs() 開始,追蹤其篩選器引數如何為 runs 請求進行格式化。重現 issue 中的雙篩選器範例,然後驗證 UI 的 && 字串和現有清單格式都能在不出現 422 錯誤的情況下取得 runs。

由索引模型根據 Issue 內容生成。

描述

backlog bug

Description of Bug

When you copy a filter with multiple different items from the UI, you get:
"folder.path == /GS2/test_data && metrics.mtm.last == 1"

But if you submit that via the Client class, you get an error:

RuntimeError: Retrieval of runs failed for url 'https://uk.simvue.io/api/runs?filters=%5B%22folder.path+%3D%3D+%2FGS2%2Ftest_data+%26%26+metrics.mtm.last+%3D%3D+1%22%5D&return_basic=True&return_metrics=True&return_alerts=False&return_system=False&return_metadata=True&count=100&start=0' with status 422: Invalid filter

We believe this is because the python API instead expects a list of filters, not '&&'. Could we fix it so that the python API accepts either format and converts it appropriately?

Steps To Reproduce

Steps to reproduce the behavior:

  1. Go to web UI
  2. Add two filters
  3. Copy filter string with the button on the UI, and paste into client.get_runs()
  4. See error

Expected behavior

Runs retrieved correctly

Actual Behaviour

422 error

Setup

  • OS: Ubuntu
  • Python version: 3.10

Additional context

Add any other context about the problem here.

主要語言
Python
星號
4
分支
1
平均合併
22 小時 21 分鐘
30 天內合併 PR
6

環境準備

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

simvue-io/python-api 的其他 Issue

查看 simvue-io/python-api 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。