Shopify / Shopify/shopify_python_api
Get rid of Class variable storage and move to instance storage
還沒有人認領這個 Issue。
- 主要語言
- Python
- 星號
- 1.4k
- 分支
- 388
- 平均合併
- 5 小時 39 分鐘
- 30 天內合併 PR
- 1
描述
I'm building an admin/monitoring server that handles requests from both out production and qa Shopify store.
In the current setup, the user/password/site_uri are stored at the class level, so I can't create a prod session and a qa session and store them in memory.
For every request to the REST server I have to clear the current class variables and set for requested environment.
Additionally, this is not thread safe. If two REST requests arrive at the same time for different endpoints, they will clobber each other.
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
研究方向
先追蹤 user、password 和 site_uri 儲存在哪裡,以及 REST 請求如何存取它們,接著檢視如何為不同的 Shopify 環境建立和選取 session。完成的標準是 production 和 QA session 可以在記憶體中共存,且並行請求不再互相覆寫設定;為這兩種情況新增或執行 coverage。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- python
- 領域
- api, backend
- Issue 類型
- 重構
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 停滯
- 描述清晰度
- 需要釐清
- 新手友好度
- 25/100