The requested URL was not found on the server (local server)
还没有人认领这个 Issue。
评估
调研方向
从 mergin/server/src/storages/disk.py 中的 move_to_tmp 开始,然后检查 mergin/server/src/controllers/project_controller.py 中 push_finish 附近的代码。复现本地项目的 push,并沿着 traceback 跟踪 os.renames。完成标准是 push-finish 请求不再引发报告中的跨设备链接错误,并返回预期的响应。
由索引模型根据 Issue 内容生成。
描述
During pushing new changes on the project, there is an error, when using server on localhost. So it have probably something with virtual environment.
Error: The requested URL was not found on the server. If you entered the URL manually please check your spelling and try again.
On the server itself i get this error:
INFO:werkzeug:127.0.0.1 - - [30/Aug/2021 11:48:31] "POST /v1/project/push/User4/ABC HTTP/1.1" 200 -
ERROR:src:Exception on /v1/project/push/finish/24d4c7f1-f330-4a7d-857f-2cb7e2fdb144 [POST]
Traceback (most recent call last):
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/app.py", line 2447, in wsgi_app
response = self.full_dispatch_request()
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/app.py", line 1952, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/app.py", line 1821, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/app.py", line 1950, in full_dispatch_request
rv = self.dispatch_request()
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/flask/app.py", line 1936, in dispatch_request
return self.view_functionsrule.endpoint
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/connexion/decorators/decorator.py", line 48, in wrapper
response = function(request)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/connexion/decorators/uri_parsing.py", line 144, in wrapper
response = function(request)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/connexion/decorators/validation.py", line 384, in wrapper
return function(request)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/connexion/decorators/response.py", line 103, in wrapper
response = function(request)
File "/home/shockwave/.local/share/virtualenvs/server-dyUHr1GY/lib/python3.8/site-packages/connexion/decorators/parameter.py", line 121, in wrapper
return function(**kwargs)
File "/home/shockwave/Lutra/mergin_server/mergin/server/src/auth/init.py", line 46, in wrapped_func
return f(*args, **kwargs)
File "/home/shockwave/Lutra/mergin_server/mergin/server/src/controllers/project_controller.py", line 856, in push_finish
move_to_tmp(upload_dir, transaction_id)
File "/home/shockwave/Lutra/mergin_server/mergin/server/src/storages/disk.py", line 95, in move_to_tmp
os.renames(src, temp_path)
File "/usr/lib/python3.8/os.py", line 270, in renames
rename(old, new)
OSError: [Errno 18] Invalid cross-device link: '/home/shockwave/Lutra/mergin_server/mergin/projects/c0/c666c2cb2ddeb22e3d2d67a9a2856c11/tmp/24d4c7f1-f330-4a7d-857f-2cb7e2fdb144' -> '/tmp/24d4c7f1-f330-4a7d-857f-2cb7e2fdb144/c0/c666c2cb2ddeb22e3d2d67a9a2856c11/tmp/24d4c7f1-f330-4a7d-857f-2cb7e2fdb144'
- 主要语言
- Python
- 星标
- 23
- 派生
- 12
- 平均合并
- 2 天 13 小时
- 30 天内合并 PR
- 7
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
MerginMaps/python-api-client 的其他 Issue
-
Vacuuming 未关闭
难度 2/5 1-3 小时 新手友好度 68/100
MerginMaps/python-api-client#320 ·
-
难度 5/5 一周以上 新手友好度 30/100
MerginMaps/python-api-client#270 ·
-
enhancement
难度 5/5 一周以上 新手友好度 25/100
MerginMaps/python-api-client#257 · 3 条评论 ·
-
enhancement
难度 4/5 3-5 天 新手友好度 25/100
MerginMaps/python-api-client#254 · 1 条评论 ·
-
enhancement
难度 5/5 一周以上 新手友好度 25/100
MerginMaps/python-api-client#245 ·
查看 MerginMaps/python-api-client 的全部 Issue
相似的 Issue
-
Add: hunch 未关闭
难度 2/5 1-3 小时 新手友好度 74/100
AbdelStark/awesome-typesafe#104 ·
-
enhancement
难度 2/5 1-3 小时 新手友好度 72/100
-
难度 2/5 1-3 小时 新手友好度 68/100
DiamondLightSource/dodal#2211 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
openml/openml-python#1749 ·
-
难度 2/5 1-3 小时 新手友好度 88/100
sipyourdrink-ltd/bernstein#6191 ·