Failed to add/update records when using MongoDB backend
還沒有人認領這個 Issue。
評估
- 難度
- 3/5
- 預估耗時
- 1-2 天
- 新手友好度
- 38/100
研究方向
從 ipyparallel/controller/mongodb.py 開始,特別查看 _binary_buffers 和 update_record,然後追蹤 ipyparallel/controller/hub.py 中的 save_queue_result 如何提供 rec['buffers']。使用 MongoDB 後端重現一個 map 或 apply_sync 工作,並確認新增或更新記錄能在不出現 BSON bytes TypeError 的情況下完成。
由索引模型根據 Issue 內容生成。
描述
When I submit tasks to either direct or load balanced view using either map or apply_sync I see debug logs below:
2018-09-18 23:27:05.936 [IPClusterStart] 2018-09-18 23:27:05.935 [IPControllerApp] ERROR | DB Error updating record u'e5925b97-b0906f91a3415ce89c3c2299'
2018-09-18 23:27:05.936 [IPClusterStart] Traceback (most recent call last):
2018-09-18 23:27:05.937 [IPClusterStart] File "/home/ifu/anaconda2/lib/python2.7/site-packages/ipyparallel/controller/hub.py", line 693, in save_queue_result
2018-09-18 23:27:05.937 [IPClusterStart] self.db.update_record(msg_id, result)
2018-09-18 23:27:05.937 [IPClusterStart] File "/home/ifu/anaconda2/lib/python2.7/site-packages/ipyparallel/controller/mongodb.py", line 87, in update_record
2018-09-18 23:27:05.937 [IPClusterStart] rec = self._binary_buffers(rec)
2018-09-18 23:27:05.937 [IPClusterStart] File "/home/ifu/anaconda2/lib/python2.7/site-packages/ipyparallel/controller/mongodb.py", line 68, in _binary_buffers
2018-09-18 23:27:05.937 [IPClusterStart] rec[key] = list(map(Binary, rec[key]))
2018-09-18 23:27:05.937 [IPClusterStart] File "/home/ifu/anaconda2/lib/python2.7/site-packages/bson/binary.py", line 147, in __new__
2018-09-18 23:27:05.937 [IPClusterStart] raise TypeError("data must be an instance of bytes")
2018-09-18 23:27:05.937 [IPClusterStart] TypeError: data must be an instance of bytes
Looks like rec['buffers'] cannot be binarized?
I am running on ubuntu 17.04 with anaconda python 2.7.15, ipyparallel 6.2.2 and pymongo 3.7.0.
- 主要語言
- Jupyter Notebook
- 星號
- 2.6k
- 分支
- 1k
- PR 合併指標
- 30 天內沒有已合併 PR
貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
ipython/ipyparallel 的其他 Issue
-
難度 4/5 3-5 天 新手友好度 48/100
ipython/ipyparallel#1029 · 9 則留言 ·
-
難度 2/5 1-3 小時 新手友好度 35/100
ipython/ipyparallel#984 ·
-
難度 4/5 3-5 天 新手友好度 35/100
ipython/ipyparallel#937 · 4 則留言 ·
-
question
難度 5/5 一週以上 新手友好度 25/100
ipython/ipyparallel#897 · 12 則留言 ·
-
bug
難度 4/5 3-5 天 新手友好度 35/100
ipython/ipyparallel#882 ·
查看 ipython/ipyparallel 的全部 Issue
相似的 Issue
-
bug CLI custom-model
難度 2/5 1-3 小時 新手友好度 75/100
-
bug confirmed issue
難度 2/5 1-3 小時 新手友好度 75/100
open-webui/open-webui#30750 · 1 則留言 ·
-
VerificationGate: ATTRIBUTION quote guard never matches a normal quotation (\b around the quote) 未關閉
難度 2/5 1-3 小時 新手友好度 75/100
danielmiessler/LifeOS#2234 ·
-
難度 2/5 1-3 小時 新手友好度 65/100
-
bug
難度 2/5 1-3 小時 新手友好度 75/100