HelloZeroNet / HelloZeroNet/ZeroNet

ZeroNet fails to start after the ungraceful shutdown

Đang mở
#471 4 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
JavaScript
Star
18.8k
Fork
2.3k
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

After the system crash ZeroNet doesn't start any more:

```
[12:30:53] - OpenSSL loaded, version: 01000114F
[12:30:53] - Version: 0.3.6 r1098, Python 2.7.11 (default, May 6 2016, 08:39:38)
[GCC 4.2.1 Compatible FreeBSD Clang 3.4.1 (tags/RELEASE_34/dot1-final 208032)], Gevent: 1.1.1
[12:30:53] - Creating FileServer....
[12:30:53] TorManager Tor controller connect error: AssertionError: Authenticate error 515 Authentication failed: Password did not match HashedControlPassword value from configuration. Maybe you tried a plain text password? If so, the standard requires that you put it in double quotes.^M
in TorManager.py line 170
[12:30:53] - Creating UiServer....
Traceback (most recent call last):
File "/usr/local/share/zeronet/zeronet.py", line 16, in main
main.start()
File "/usr/local/share/zeronet/src/main.py", line 412, in start
actions.call(config.action, action_kwargs)
File "/usr/local/share/zeronet/src/main.py", line 115, in call
func(**kwargs)
File "/usr/local/share/zeronet/src/main.py", line 126, in main
ui_server = UiServer()
File "/usr/local/share/zeronet/src/Ui/UiServer.py", line 61, in __init__
self.sites = SiteManager.site_manager.list()
File "/usr/local/share/zeronet/src/Site/SiteManager.py", line 90, in list
self.load()
File "plugins/Zeroname/SiteManagerPlugin.py", line 17, in load
super(SiteManagerPlugin, self).load()
File "/usr/local/share/zeronet/src/Site/SiteManager.py", line 25, in load
for address in json.load(open("%s/sites.json" % config.data_dir)):
File "/usr/local/lib/python2.7/json/__init__.py", line 291, in load
**kw)
File "/usr/local/lib/python2.7/json/__init__.py", line 339, in loads
return _default_decoder.decode(s)
File "/usr/local/lib/python2.7/json/decoder.py", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/local/lib/python2.7/json/decoder.py", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded
- Starting ZeroNet...
```

/var/db/zeronet/data/sites.json is blank. File sites.json-new is valid, when I copied it to sites.json it works. This should happen automatically. Or, better you should use SQLite.

zeronet-0.3.6

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Hướng nghiên cứu

Start with src/Site/SiteManager.py and plugins/Zeroname/SiteManagerPlugin.py, focusing on how sites.json is loaded during startup. Reproduce the blank sites.json failure and compare it with the valid sites.json-new file. Done means ZeroNet starts after this recovery scenario without requiring manual file replacement; the SQLite alternative would require separate design work.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
python
Lĩnh vực
backend, databases
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
30/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.