Comments (2)
It looks like the root cause was an uncaught OperationalError
:
2015-04-07 19:59:32,551 ERROR Uncaught exception GET /api/sites/1 (10.16.16.85)
Traceback (most recent call last):
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/tornado/web.py", line 1309, in _ex
ecute
result = self.prepare()
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/nsot/handlers/util.py", line 192,
in prepare
BaseHandler.prepare(self)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/nsot/handlers/util.py", line 70, i
n prepare
if not self.current_user:
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/tornado/web.py", line 1022, in cur
rent_user
self._current_user = self.get_current_user()
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/nsot/handlers/util.py", line 156,
in get_current_user
user = models.User.verify_auth_token(email, auth_token)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/nsot/models.py", line 306, in veri
fy_auth_token
user = User.query().filter_by(email=email).scalar()
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 242
6, in scalar
ret = self.one()
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 239
5, in one
ret = list(self)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 243
8, in __iter__
return self._execute_and_instances(context)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/orm/query.py", line 245
3, in _execute_and_instances
result = conn.execute(querycontext.statement, self._params)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 7
29, in execute
return meth(self, multiparams, params)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/sql/elements.py", line
322, in _execute_on_connection
return connection._execute_clauseelement(self, multiparams, params)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 8
26, in _execute_clauseelement
compiled_sql, distilled_params
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 9
58, in _execute_context
context)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 1
159, in _handle_dbapi_exception
exc_info
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/util/compat.py", line 1
99, in raise_from_cause
reraise(type(exception), exception, tb=exc_tb)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/base.py", line 9
51, in _execute_context
context)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/sqlalchemy/engine/default.py", lin
e 436, in do_execute
cursor.execute(statement, parameters)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/MySQLdb/cursors.py", line 205, in
execute
self.errorhandler(self, exc, value)
File "/srv/nsot/envs/nsot/lib/python2.7/site-packages/MySQLdb/connections.py", line 36,
in defaulterrorhandler
raise errorclass, errorvalue
OperationalError: (OperationalError) (2006, 'MySQL server has gone away') 'SELECT users.id
AS users_id, users.email AS users_email, users.secret_key AS users_secret_key \nFROM user
s \nWHERE users.email = %s' ('jathan@locallhost',)
from nsot.
It looks like on a long-running server instance where nobody has queried the API for a while, the DB session goes idle and loses the connection to the MySQL server. This is a flaw in the scoped_session
implementation and needs to be reconsidered.
from nsot.
Related Issues (20)
- Interface.type should accept and display a string representation
- Refactor common model helpers/validators into a single place
- NSoT Changes endpoint should be able to filter the change log with more granularity
- Upgrade to support Python 3.6+ HOT 2
- Quickstart says to create superuser when prompted, but there is no prompt HOT 3
- Timezone calculation error: NSoT should set UTC by default. HOT 1
- Make Circuits 'Interface Optional' HOT 1
- Install error: conflicting types for ‘ASN1_TIME_to_generalizedtime’ HOT 1
- Object list views sometimes return stale results
- Host names restrictions HOT 1
- Demo Login Fails HOT 2
- Attributeerror: module object has no attribute getuid HOT 1
- name_slug's dont update upon updating a device hostname. HOT 2
- NSOT_NEW_USERS_AS_SUPERUSER isn't documented.
- next_network for state=assigned
- psycopg2 version behind when using Docker and Postgres
- Nsot completely breaks if the initial site is created with an emoji in the description
- NSoT Installation failure HOT 8
- interface old addresses state is not updated when you assign a new addresses
- Any attempt to migration to Python3? Is this project dead? HOT 1
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 nsot.