Comments (14)
@FirmlyReality is modifying some code in my docklet respository, PedronLiu/docklet.
After his work, I will test it and send pull request to unias/docklet
from docklet.
Done. @PedroLiu you can continue to finish your work.
from docklet.
Good job!
from docklet.
but it did not work in my machine.
after I input username and passwd, the browser is just waiting for responses, without showing the docklet dashboard and menu.
from docklet.
The failed test is using recovery mode. When I started using reinit mode, it worked. But then I found another problem: it took several seconds to stop docklet master. What happened then ?
from docklet.
I work out the cause. It is the debug mode of flask
debug mode of flask will restart the process to import some modules needed by debug mode.(for example, watchdog module, it is to watch files' status so that flask can restart itself when some file changes to load the latest code)
But this will cause some work before flask lost and some threads becoming zombies. So, the running and stopping works abnormally.
I disabled the debug mode of flask in httprest.py now and it works fine.
from docklet.
There is still problems in my test.
When I login, I get the following error:
simplejson.scanner.JSONDecodeError
simplejson.scanner.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
Traceback (most recent call last)
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1836, in __call__
return self.wsgi_app(environ, start_response)
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1820, in wsgi_app
response = self.make_response(self.handle_exception(e))
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1403, in handle_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.5/dist-packages/flask/_compat.py", line 33, in reraise
raise value
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1817, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1477, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1381, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.5/dist-packages/flask/_compat.py", line 33, in reraise
raise value
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1475, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python3.5/dist-packages/flask/app.py", line 1461, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/root/docklet/web/web.py", line 64, in login
return loginView.as_view()
File "/root/docklet/web/webViews/view.py", line 28, in as_view
return self.get()
File "/root/docklet/web/webViews/authenticate/login.py", line 42, in get
refreshInfo()
File "/root/docklet/web/webViews/authenticate/login.py", line 24, in refreshInfo
result = dockletRequest.post('/user/selfQuery/', data)
File "/root/docklet/web/webViews/dockletrequest.py", line 17, in post
result = requests.post(endpoint + url, data = data).json()
File "/usr/lib/python3/dist-packages/requests/models.py", line 808, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/lib/python3/dist-packages/simplejson/__init__.py", line 516, in loads
return _default_decoder.decode(s)
File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 370, in decode
obj, end = self.raw_decode(s)
File "/usr/lib/python3/dist-packages/simplejson/decoder.py", line 400, in raw_decode
return self.scan_once(s, idx=_w(s, idx).end())
simplejson.scanner.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
from docklet.
@PedroLiu
So Peidong, would you please test the code completely, especially for an already running instance?
from docklet.
@caodg I met a bug every time when I restart docklet-master, you can stop it and init it, then this problem will not happen, I thought it was my machine's problem.
And @zhongyehong 's last pull request will cause a bug, please run tools/upgrade.py first
from docklet.
- Obviously we can not init a running system, if the system already having many users and workspaces. We can only restart the system in recovery mode, to ensure that the users' data and settings will not get lost.
- I have run the upgrade.py, the problem still exists.
from docklet.
I tested all functions on my computer... I will solve these problems in several days
from docklet.
Maybe everyone has their own understanding of "having tested all functions". But for a practical system, the only judgement is if it works as expected. You said "I met a bug every time when I restart docklet-master, ... stop it and init it, then this problem will not happen". So, do you think "init" is an expected solution, or "it was my machine's problem" is really the true cause? Is there indeed any difference between your machine and my machine?
@leebaok
Libao, if we can not solve this problem quickly, I think we had better resolve back to the previous version. Although it looks a bit ugly, at least it works.
from docklet.
I met this bug before, try logout first, then it will not happen...
I'm working on it to find how it occurs
from docklet.
Solved.
This bug occurs when user token expires because of returning a dict in wrapper function.
I also modified 500 page, Now a 500 page will be shown when 500 error occurs in web.py.
See pull request #79
from docklet.
Related Issues (20)
- replace GRE with VXLAN to avoid critical-node crash
- not using default setting while scaling out a new node HOT 1
- setting default container setting in user config panel or admin panel HOT 1
- Add multiple nodes in one click
- record and display history of all containers HOT 1
- generated_password file not exist after master init HOT 1
- Separate user module from monitor HOT 1
- Image save failed HOT 2
- rename Dashboard to Workspace HOT 1
- add docklet hyperlink in web portal HOT 1
- Cannot modify users' info in /user/list HOT 1
- Add qos rate limiting and port mappings billings
- Threading Synchronization
- Job Management module in batch computing
- Task management module for batch computing
- agent enhancement to support batch computing
- Users' requests are blocked sometimes because of unreleased users' locks HOT 1
- acquire lock without release when exception occur HOT 1
- Refine container job creation HOT 1
- Any chance updating this to use LXD HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docklet.