Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ValueError
- ValueError: insecure string pickle
- Traceback (most recent call last)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1997, in __call__
- error = None
- ctx.auto_pop(error)
- def __call__(self, environ, start_response):
- """Shortcut for :attr:`wsgi_app`."""
- return self.wsgi_app(environ, start_response)
- def __repr__(self):
- return '<%s %r>' % (
- self.__class__.__name__,
- self.name,
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1985, in wsgi_app
- try:
- try:
- response = self.full_dispatch_request()
- except Exception as e:
- error = e
- response = self.handle_exception(e)
- except:
- error = sys.exc_info()[1]
- raise
- return response(environ, start_response)
- finally:
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1540, in handle_exception
- # if we want to repropagate the exception, we can attempt to
- # raise it with the whole traceback in case we can do that
- # (the function was actually called from the except part)
- # otherwise, we just raise the error again
- if exc_value is e:
- reraise(exc_type, exc_value, tb)
- else:
- raise e
- self.log_exception((exc_type, exc_value, tb))
- if handler is None:
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
- ctx = self.request_context(environ)
- ctx.push()
- error = None
- try:
- try:
- response = self.full_dispatch_request()
- except Exception as e:
- error = e
- response = self.handle_exception(e)
- except:
- error = sys.exc_info()[1]
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
- request_started.send(self)
- rv = self.preprocess_request()
- if rv is None:
- rv = self.dispatch_request()
- except Exception as e:
- rv = self.handle_user_exception(e)
- return self.finalize_request(rv)
- def finalize_request(self, rv, from_error_handler=False):
- """Given the return value from a view function this finalizes
- the request by converting it into a response and invoking the
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
- return self.handle_http_exception(e)
- handler = self._find_error_handler(e)
- if handler is None:
- reraise(exc_type, exc_value, tb)
- return handler(e)
- def handle_exception(self, e):
- """Default exception handling that kicks in when an exception
- occurs that is not caught. In debug mode the exception will
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
- self.try_trigger_before_first_request_functions()
- try:
- request_started.send(self)
- rv = self.preprocess_request()
- if rv is None:
- rv = self.dispatch_request()
- except Exception as e:
- rv = self.handle_user_exception(e)
- return self.finalize_request(rv)
- def finalize_request(self, rv, from_error_handler=False):
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
- # request came with the OPTIONS method, reply automatically
- if getattr(rule, 'provide_automatic_options', False) \
- and req.method == 'OPTIONS':
- return self.make_default_options_response()
- # otherwise dispatch to the handler for that endpoint
- return self.view_functions[rule.endpoint](**req.view_args)
- def full_dispatch_request(self):
- """Dispatches the request and on top of that performs request
- pre and postprocessing as well as HTTP exception catching and
- error handling.
- File "/home/roosa/work/blogfeed/src/feed.py", line 107, in newpost
- @app.route("/newpost", methods=["POST"])
- def newpost():
- # TODO: proper save to database, this is for testing purposes right now
- picklestr = base64.urlsafe_b64decode(request.data)
- # return picklestr
- postObj = pickle.loads(picklestr)
- return "POST RECEIVED: " + postObj['Subject']
- ## TODO: VERY important! DISABLED THIS IN PRODUCTION
- app = DebuggedApplication(app, evalex=True, console_path='/debugconsole')
- ValueError: insecure string pickle
- This is the Copy/Paste friendly version of the traceback. You can also paste this traceback into a gist:
- Traceback (most recent call last):
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1997, in __call__
- return self.wsgi_app(environ, start_response)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1985, in wsgi_app
- response = self.handle_exception(e)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1540, in handle_exception
- reraise(exc_type, exc_value, tb)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1982, in wsgi_app
- response = self.full_dispatch_request()
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1614, in full_dispatch_request
- rv = self.handle_user_exception(e)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1517, in handle_user_exception
- reraise(exc_type, exc_value, tb)
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1612, in full_dispatch_request
- rv = self.dispatch_request()
- File "/usr/local/lib/python2.7/dist-packages/flask/app.py", line 1598, in dispatch_request
- return self.view_functions[rule.endpoint](**req.view_args)
- File "/home/roosa/work/blogfeed/src/feed.py", line 107, in newpost
- postObj = pickle.loads(picklestr)
- ValueError: insecure string pickle
- The debugger caught an exception in your WSGI application. You can now look at the traceback which led to the error. If you enable JavaScript you can also use additional features such as code execution (if the evalex feature is enabled), automatic pasting of the exceptions and much more.
- Brought to you by DON'T PANIC, your friendly Werkzeug powered traceback interpreter.
- Console Locked
- The console is locked and needs to be unlocked by entering the PIN. You can find the PIN printed out on the standard output of your shell that runs the server.
- PIN:
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement