Flasgger failed to load API definition - api

I get this error message when trying to see the Swagger UI with Flasgger:
ERROR in app: Exception on /apispec_1.json [GET]
Traceback (most recent call last):
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 2446, in wsgi_app
response = self.full_dispatch_request()
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1951, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/usr/local/lib/python3.6/site-packages/flask_cors/extension.py", line 161, in wrapped_function
return cors_after_request(app.make_response(f(*args, **kwargs)))
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1820, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/usr/local/lib/python3.6/site-packages/flask/_compat.py", line 39, in reraise
raise value
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1949, in full_dispatch_request
rv = self.dispatch_request()
File "/usr/local/lib/python3.6/site-packages/flask/app.py", line 1935, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/usr/local/lib/python3.6/site-packages/flask/views.py", line 89, in view
return self.dispatch_request(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/flask/views.py", line 163, in dispatch_request
return meth(*args, **kwargs)
File "/usr/local/lib/python3.6/site-packages/flasgger/base.py", line 133, in get
return jsonify(self.loader())
File "/usr/local/lib/python3.6/site-packages/flasgger/base.py", line 465, in get_apispecs
prefix_ids=prefix_ids
File "/usr/local/lib/python3.6/site-packages/flasgger/utils.py", line 747, in extract_definitions
if not getattr(item, 'get'):
AttributeError: 'NoneType' object has no attribute 'get'
I tried everything, but I cannot see anything when I access http://localhost:5000/apidocs. I get error message: Fetch error: INTERNAL SERVER ERROR /apispec_1.json

Related

odoo plm module problem when create a new revision when i press start newrevision get error

plm module problem  when
create a new revision when i press start newrevision  get error 
Error:Odoo Server ErrorTraceback (most recent call last): File "/odoo/odoo/odoo/api.py", line 1049, in get value = self._data[key][field][record._ids[0]]KeyError: 1245During handling of the above exception, another exception occurred:Traceback (most recent call last): File "/odoo/odoo/odoo/fields.py", line 1065, in get value = record.env.cache.get(record, self) File "/odoo/odoo/odoo/api.py", line 1051, in get raise CacheMiss(record, field)odoo.exceptions.CacheMiss: ('mrp.bom(1245,).is_allowed_to_modif_unit', None)During handling of the above exception, another exception occurred:Traceback (most recent call last): File "/odoo/odoo/odoo/models.py", line 4765, in ensure_one _id, = self._idsValueError: too many values to unpack (expected 1)During handling of the above exception, another exception occurred:Traceback (most recent call last): File "/odoo/odoo/odoo/http.py", line 656, in _handle_exception return super(JsonRequest, self)._handle_exception(exception) File "/odoo/odoo/odoo/http.py", line 314, in _handle_exception raise pycompat.reraise(type(exception), exception, sys.exc_info()[2]) File "/odoo/odoo/odoo/tools/pycompat.py", line 87, in reraise raise value File "/odoo/odoo/odoo/http.py", line 698, in dispatch result = self._call_function(**self.params) File "/odoo/odoo/odoo/http.py", line 346, in _call_function return checked_call(self.db, *args, **kwargs) File "/odoo/odoo/odoo/service/model.py", line 98, in wrapper return f(dbname, *args, **kwargs) File "/odoo/odoo/odoo/http.py", line 339, in checked_call result = self.endpoint(*a, **kw) File "/odoo/odoo/odoo/http.py", line 941, in call return self.method(*args, **kw) File "/odoo/odoo/odoo/http.py", line 519, in response_wrap response = f(*args, **kw) File "/odoo/odoo/addons/web/controllers/main.py", line 967, in call_button action = self._call_kw(model, method, args, {}) File "/odoo/odoo/addons/web/controllers/main.py", line 955, in _call_kw return call_kw(request.env[model], method, args, kwargs) File "/odoo/odoo/odoo/api.py", line 759, in call_kw return _call_kw_multi(method, model, args, kwargs) File "/odoo/odoo/odoo/api.py", line 746, in _call_kw_multi result = method(recs, *args, **kwargs) File "/odoo/Enterprise/mrp_plm/models/mrp_eco.py", line 586, in action_new_revision 'previous_bom_id': eco.bom_id.id, File "/odoo/odoo/odoo/models.py", line 4336, in copy new = self.with_context(lang=None).create(vals) File "", line 2, in create File "/odoo/odoo/odoo/api.py", line 440, in _model_create_single return create(self, arg) File "/odoo/mycompany/mrp_production_draft/models/mrp_production.py", line 954, in create res = super(MrpBom, self).create(values) File "", line 2, in create File "/odoo/odoo/odoo/api.py", line 461, in _model_create_multi return create(self, [arg]) File "/odoo/odoo/addons/mail/models/mail_thread.py", line 298, in create thread.message_track(tracked_fields, initial_values) File "/odoo/odoo/addons/mail/models/mail_thread.py", line 640, in message_track tracking = self._message_track_get_changes(tracked_fields, initial_values) File "/odoo/odoo/addons/mail/models/mail_thread.py", line 601, in _message_track_get_changes result[record.id] = record._message_track(tracked_fields, initial_values[record.id]) File "/odoo/odoo/addons/mail/models/mail_thread.py", line 618, in _message_track new_value = getattr(self, col_name) File "/odoo/odoo/odoo/fields.py", line 1069, in get self.determine_value(record) File "/odoo/odoo/odoo/fields.py", line 1182, in determine_value self.compute_value(recs) File "/odoo/odoo/odoo/fields.py", line 1136, in compute_value self._compute_value(records) File "/odoo/odoo/odoo/fields.py", line 1127, in _compute_value getattr(records, self.compute)() File "/odoo/mycompany/mrp_production_draft/models/mrp_production.py", line 945, in get_user self.is_allowed_to_modif_unit = True File "/odoo/odoo/odoo/fields.py", line 1084, in set record.ensure_one() File "/odoo/odoo/odoo/models.py", line 4768, in ensure_one raise ValueError("Expected singleton: %s" % self)ValueError: Expected singleton: mrp.bom(1245, 26)
plm module problem  when
create a new revision when i press start newrevision  get error and cannot add role and user empty i cannnot put anything on role

Tensorboard not working with after upgrading tensorflow from 2.1.2 to 2.3.0

I was using TensorFlow 2.1.2 and TensorBoard 2.4.1,
import os, shutil
import tensorflow as tf
print(tf.__version__)
SUMMARY_DIR = 'summary/testing_this'
if 1:
# SUMMARY_DIR is the path of the directory where the tensorboard SummaryWriter files are written
# the directory is removed, if it already exists
if os.path.exists(SUMMARY_DIR):
shutil.rmtree(SUMMARY_DIR)
train_summary_writer = tf.summary.create_file_writer(os.path.join(SUMMARY_DIR, 'train'))
test_summary_writer = tf.summary.create_file_writer(os.path.join(SUMMARY_DIR, 'test'))
train_summary_counter = 0
for i in range(100):
with train_summary_writer.as_default():
tf.summary.scalar('train/sampled-softmax loss', i+5, step=train_summary_counter)
train_summary_counter += 1
The code written above worked perfectly fine. But as I upgraded to TensorFlow 2.3.0, the following error was thrown-
Serving TensorBoard on localhost; to expose to the network, use a proxy or pass --bind_all
TensorBoard 2.4.1 at http://localhost:6006/ (Press CTRL+C to quit)
E0216 07:39:53.581997 140588167055104 _internal.py:113] Error on request:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: '------WebKitFormBoundary20rNOiiimzABSId3'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 131, in wrapper
return f(self, stream, *args, **kwargs)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 253, in _parse_multipart
form, files = parser.parse(stream, boundary, content_length)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 584, in parse
return self.cls(form), self.cls(files)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/datastructures.py", line 419, in __init__
for key, value in mapping or ():
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 582, in <genexpr>
form = (p[1] for p in formstream if p[0] == "form")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 537, in parse_parts
for ellt, ell in self.parse_lines(file, boundary, content_length):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 451, in parse_lines
terminator = self._find_terminator(iterator)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 368, in _find_terminator
for line in iterator:
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 721, in make_line_iter
first_item = next(_iter, "")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 681, in _make_chunk_iter
item = _read(buffer_size)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: 'Content-Disposition: form-data; name="tag"'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 323, in run_wsgi
execute(self.server.app)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 312, in execute
application_iter = app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 526, in __call__
return self._app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 567, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/security_validator.py", line 80, in __call__
return self._application(environ, start_response_proxy)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/path_prefix.py", line 71, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/experiment_id.py", line 76, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/empty_path_redirect.py", line 47, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 590, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 549, in _route_request
return self.exact_routes[clean_path](environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 238, in application
resp = f(*args[:-2] + (request,))
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/plugins/scalar/scalars_plugin.py", line 166, in scalars_multirun_route
tags = request.form.getlist("tag")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/utils.py", line 90, in __get__
value = self.func(obj)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 480, in form
self._load_form_data()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 319, in _load_form_data
self._get_stream_for_parsing(), mimetype, content_length, options
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 232, in parse
return parse_func(self, stream, mimetype, content_length, options)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 138, in wrapper
chunk = stream.read(1024 * 64)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
E0216 07:39:53.585781 140588158662400 _internal.py:113] Error on request:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: '------WebKitFormBoundary4NW6Hm666U0prn4r'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 131, in wrapper
return f(self, stream, *args, **kwargs)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 253, in _parse_multipart
form, files = parser.parse(stream, boundary, content_length)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 584, in parse
return self.cls(form), self.cls(files)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/datastructures.py", line 419, in __init__
for key, value in mapping or ():
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 582, in <genexpr>
form = (p[1] for p in formstream if p[0] == "form")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 537, in parse_parts
for ellt, ell in self.parse_lines(file, boundary, content_length):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 451, in parse_lines
terminator = self._find_terminator(iterator)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 368, in _find_terminator
for line in iterator:
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 721, in make_line_iter
first_item = next(_iter, "")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 681, in _make_chunk_iter
item = _read(buffer_size)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: 'Content-Disposition: form-data; name="tag"'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 323, in run_wsgi
execute(self.server.app)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 312, in execute
application_iter = app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 526, in __call__
return self._app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 567, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/security_validator.py", line 80, in __call__
return self._application(environ, start_response_proxy)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/path_prefix.py", line 71, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/experiment_id.py", line 76, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/empty_path_redirect.py", line 47, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 590, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 549, in _route_request
return self.exact_routes[clean_path](environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 238, in application
resp = f(*args[:-2] + (request,))
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/plugins/scalar/scalars_plugin.py", line 166, in scalars_multirun_route
tags = request.form.getlist("tag")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/utils.py", line 90, in __get__
value = self.func(obj)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 480, in form
self._load_form_data()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 319, in _load_form_data
self._get_stream_for_parsing(), mimetype, content_length, options
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 232, in parse
return parse_func(self, stream, mimetype, content_length, options)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 138, in wrapper
chunk = stream.read(1024 * 64)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
E0216 07:39:53.721650 140588158662400 _internal.py:113] Error on request:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: '------WebKitFormBoundaryQo6LrfWENvCGlGD7'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 131, in wrapper
return f(self, stream, *args, **kwargs)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 253, in _parse_multipart
form, files = parser.parse(stream, boundary, content_length)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 584, in parse
return self.cls(form), self.cls(files)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/datastructures.py", line 419, in __init__
for key, value in mapping or ():
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 582, in <genexpr>
form = (p[1] for p in formstream if p[0] == "form")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 537, in parse_parts
for ellt, ell in self.parse_lines(file, boundary, content_length):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 451, in parse_lines
terminator = self._find_terminator(iterator)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 368, in _find_terminator
for line in iterator:
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 721, in make_line_iter
first_item = next(_iter, "")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 681, in _make_chunk_iter
item = _read(buffer_size)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: 'Content-Disposition: form-data; name="tag"'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 323, in run_wsgi
execute(self.server.app)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 312, in execute
application_iter = app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 526, in __call__
return self._app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 567, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/security_validator.py", line 80, in __call__
return self._application(environ, start_response_proxy)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/path_prefix.py", line 71, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/experiment_id.py", line 76, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/empty_path_redirect.py", line 47, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 590, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 549, in _route_request
return self.exact_routes[clean_path](environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 238, in application
resp = f(*args[:-2] + (request,))
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/plugins/scalar/scalars_plugin.py", line 166, in scalars_multirun_route
tags = request.form.getlist("tag")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/utils.py", line 90, in __get__
value = self.func(obj)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 480, in form
self._load_form_data()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 319, in _load_form_data
self._get_stream_for_parsing(), mimetype, content_length, options
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 232, in parse
return parse_func(self, stream, mimetype, content_length, options)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 138, in wrapper
chunk = stream.read(1024 * 64)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
E0216 07:39:53.824328 140588158662400 _internal.py:113] Error on request:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: '------WebKitFormBoundaryPDuqOCLNbMBFkkSo'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 131, in wrapper
return f(self, stream, *args, **kwargs)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 253, in _parse_multipart
form, files = parser.parse(stream, boundary, content_length)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 584, in parse
return self.cls(form), self.cls(files)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/datastructures.py", line 419, in __init__
for key, value in mapping or ():
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 582, in <genexpr>
form = (p[1] for p in formstream if p[0] == "form")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 537, in parse_parts
for ellt, ell in self.parse_lines(file, boundary, content_length):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 451, in parse_lines
terminator = self._find_terminator(iterator)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 368, in _find_terminator
for line in iterator:
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 721, in make_line_iter
first_item = next(_iter, "")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wsgi.py", line 681, in _make_chunk_iter
item = _read(buffer_size)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 124, in read_chunk_len
_len = int(line.strip(), 16)
ValueError: invalid literal for int() with base 16: 'Content-Disposition: form-data; name="tag"'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 323, in run_wsgi
execute(self.server.app)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 312, in execute
application_iter = app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 526, in __call__
return self._app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 567, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/security_validator.py", line 80, in __call__
return self._application(environ, start_response_proxy)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/path_prefix.py", line 71, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/experiment_id.py", line 76, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/empty_path_redirect.py", line 47, in __call__
return self._application(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 590, in wrapper
return wsgi_app(environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/backend/application.py", line 549, in _route_request
return self.exact_routes[clean_path](environ, start_response)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 238, in application
resp = f(*args[:-2] + (request,))
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/tensorboard/plugins/scalar/scalars_plugin.py", line 166, in scalars_multirun_route
tags = request.form.getlist("tag")
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/utils.py", line 90, in __get__
value = self.func(obj)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 480, in form
self._load_form_data()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/wrappers/base_request.py", line 319, in _load_form_data
self._get_stream_for_parsing(), mimetype, content_length, options
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 232, in parse
return parse_func(self, stream, mimetype, content_length, options)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/formparser.py", line 138, in wrapper
chunk = stream.read(1024 * 64)
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 137, in readinto
self._len = self.read_chunk_len()
File "/home/ec2-user/anaconda3/envs/tensorflow2_p36/lib/python3.6/site-packages/werkzeug/serving.py", line 126, in read_chunk_len
raise IOError("Invalid chunk header")
OSError: Invalid chunk header
Can somebody please help me run tensorboard with tf 2.3.0?
Downgrading with pip install 'tensorboard<2.4' fixed this for me.
It seems tensorboard 2.4 made some breaking change.

in __getitem__ return self.models[model_name] KeyError: 'mham_app.mham_app' - - -

try to extend timesheet by adding some fields and change name of other but when i inherited the related model which is 'account.analytic.line':
and add the 'analytic ' module in the manifest as depends
from odoo import models, fields, api
class mham_app(models.Model):
_inherit='account.analytic.line'
date_deadline = fields.Date('Deadline')
is_done = fields.Boolean('Done?')
active = fields.Boolean('Active?', default=True)
the follow is the manifest.py file
# any module necessary for this one to work correctly
'depends': ['analytic'],
the following is full error massage
2019-02-05 20:21:54,528 17339 ERROR New_todo odoo.modules.registry: Failed to load registry
Traceback (most recent call last):
File "/odoo/odoo-server/odoo/modules/registry.py", line 60, in __new__
return cls.registries[db_name]
File "/odoo/odoo-server/odoo/tools/func.py", line 69, in wrapper
return func(self, *args, **kwargs)
File "/odoo/odoo-server/odoo/tools/lru.py", line 44, in __getitem__
a = self.d[obj].me
KeyError: 'New_todo'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/odoo/odoo-server/odoo/modules/registry.py", line 86, in new
odoo.modules.load_modules(registry._db, force_demo, status, update_module)
File "/odoo/odoo-server/odoo/modules/loading.py", line 455, in load_modules
env['ir.model.data']._process_end(processed_modules)
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 1624, in _process_end
record.unlink()
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 637, in unlink
self._prepare_update()
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 584, in _prepare_update
model = self.env[rec.model]
File "/odoo/odoo-server/odoo/api.py", line 820, in __getitem__
return self.registry[model_name]._browse((), self)
File "/odoo/odoo-server/odoo/modules/registry.py", line 176, in __getitem__
return self.models[model_name]
KeyError: 'mham_app.mham_app'
2019-02-05 20:21:54,532 17339 INFO New_todo werkzeug: 127.0.0.1 - - [05/Feb/2019 20:21:54] "POST /longpolling/poll HTTP/1.1" 500 - 421 0.353 1.094
2019-02-05 20:21:54,541 17339 ERROR New_todo werkzeug: Error on request:
Traceback (most recent call last):
File "/home/msafi/.local/lib/python3.6/site-packages/werkzeug/serving.py", line 270, in run_wsgi
execute(self.server.app)
File "/home/msafi/.local/lib/python3.6/site-packages/werkzeug/serving.py", line 258, in execute
application_iter = app(environ, start_response)
File "/odoo/odoo-server/odoo/service/server.py", line 350, in app
return self.app(e, s)
File "/odoo/odoo-server/odoo/service/wsgi_server.py", line 128, in application
return application_unproxied(environ, start_response)
File "/odoo/odoo-server/odoo/service/wsgi_server.py", line 117, in application_unproxied
result = odoo.http.root(environ, start_response)
File "/odoo/odoo-server/odoo/http.py", line 1318, in __call__
return self.dispatch(environ, start_response)
File "/odoo/odoo-server/odoo/http.py", line 1291, in __call__
return self.app(environ, start_wrapped)
File "/home/msafi/.local/lib/python3.6/site-packages/werkzeug/wsgi.py", line 766, in __call__
return self.app(environ, start_response)
File "/odoo/odoo-server/odoo/http.py", line 1469, in dispatch
odoo.registry(db).check_signaling()
File "/odoo/odoo-server/odoo/__init__.py", line 81, in registry
return modules.registry.Registry(database_name)
File "/odoo/odoo-server/odoo/modules/registry.py", line 62, in __new__
return cls.new(db_name)
File "/odoo/odoo-server/odoo/modules/registry.py", line 86, in new
odoo.modules.load_modules(registry._db, force_demo, status, update_module)
File "/odoo/odoo-server/odoo/modules/loading.py", line 455, in load_modules
env['ir.model.data']._process_end(processed_modules)
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 1624, in _process_end
record.unlink()
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 637, in unlink
self._prepare_update()
File "/odoo/odoo-server/odoo/addons/base/models/ir_model.py", line 584, in _prepare_update
model = self.env[rec.model]
File "/odoo/odoo-server/odoo/api.py", line 820, in __getitem__
return self.registry[model_name]._browse((), self)
File "/odoo/odoo-server/odoo/modules/registry.py", line 176, in __getitem__
return self.models[model_name]
KeyError: 'mham_app.mham_app' - - -
although of there is no model name mham_app.mham_app
And the error occure also comes if I change the name to something else

using selenium from pythonanywhere?

I want use selenium in pythonanywhere.
this is error log in pythonanywhere.
Traceback (most recent call last):
File "/bin/user_wsgi_wrapper.py", line 154, in __call__
app_iterator = self.app(environ, start_response)
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 2000, in __call__
return self.wsgi_app(environ, start_response)
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1991, in wsgi_app
response = self.make_response(self.handle_exception(e))
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1567, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1988, in wsgi_app
response = self.full_dispatch_request()
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1641, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1544, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1639, in full_dispatch_request
rv = self.dispatch_request()
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/flask/app.py", line 1625, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/home/downtownhub/odermysite/minitwit.py", line 409, in ordercolect
driver = webdriver.Firefox()
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/selenium/webdriver/firefox/webdriver.py", line 135, in __init__
self.service.start()
File "/home/downtownhub/odermysite/env/lib/python3.4/site-packages/selenium/webdriver/common/service.py", line 71, in start
os.path.basename(self.path), self.start_error_message)
selenium.common.exceptions.WebDriverException: Message: 'geckodriver' executable needs to be in PATH.
So I added geckodrive file in Path('/home/downtownhub/odermysite/env/bin').
but it happen same error.
what can I solve it??
Ah, I see you're using a virtualenv. PythonAnywhere uses an old version of Firefox (v17) which is not compatible with the latest selenium/geckodriver. Switch back to selenium 2:
./env/bin/pip install "selenium<3"

Scrapyd S3 feed export "Connection Reset by Peer"

I'm running Scrapyd with a FEED_URI set to export to S3, but I received the following error at the very end of my scrape. Note that it successfully uploaded a few hundred kb of data to the bucket as the scrape began, then threw this error at the end:
2014-11-24 10:11:23+0000 [word] ERROR: Error storing csv feed (2285242 items) in: s3://kitchen.bucket/FoodItem.csv
Traceback (most recent call last):
File "/usr/lib/python2.7/threading.py", line 783, in __bootstrap
self.__bootstrap_inner()
File "/usr/lib/python2.7/threading.py", line 810, in __bootstrap_inner
self.run()
File "/usr/lib/python2.7/threading.py", line 763, in run
self.__target(*self.__args, **self.__kwargs)
--- <exception caught here> ---
File "/usr/lib/python2.7/dist-packages/twisted/python/threadpool.py", line 191, in _worker
result = context.call(ctx, function, *args, **kwargs)
File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 118, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/usr/lib/python2.7/dist-packages/twisted/python/context.py", line 81, in callWithContext
return func(*args,**kw)
File "/usr/local/lib/python2.7/dist-packages/scrapy/contrib/feedexport.py", line 101, in _store_in_thread
key.set_contents_from_file(file)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 1291, in set_contents_from_file
chunked_transfer=chunked_transfer, size=size)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 748, in send_file
chunked_transfer=chunked_transfer, size=size)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 949, in _send_file_internal
query_args=query_args
File "/usr/local/lib/python2.7/dist-packages/boto/s3/connection.py", line 664, in make_request
retry_handler=retry_handler
File "/usr/local/lib/python2.7/dist-packages/boto/connection.py", line 1068, in make_request
retry_handler=retry_handler)
File "/usr/local/lib/python2.7/dist-packages/boto/connection.py", line 939, in _mexe
request.body, request.headers)
File "/usr/local/lib/python2.7/dist-packages/boto/s3/key.py", line 842, in sender
http_conn.send(chunk)
File "/usr/lib/python2.7/httplib.py", line 805, in send
self.sock.sendall(data)
File "/usr/lib/python2.7/ssl.py", line 329, in sendall
v = self.send(data[count:])
File "/usr/lib/python2.7/ssl.py", line 298, in send
v = self._sslobj.write(data)
socket.error: [Errno 104] Connection reset by peer
Looks similar to boto issue 2207. I'm using gbirke's MultiFeedExporter, and received a similar error on both of my items.