Cannot access login route
akbari59 opened this issue · 3 comments
akbari59 commented
I am learning flask and I tried it out with your repository. I can register a user but I cannot login with the same user using. Following is the stack trace, do you have any idea? I used curl to send request.
Thanks in advance.,
Traceback (most recent call last):
File "_pydevd_frame_eval/pydevd_frame_evaluator_darwin_37_64.pyx", line 95, in _pydevd_frame_eval.pydevd_frame_evaluator_darwin_37_64.get_bytecode_while_frame_eval
KeyError: '/Users/mohammad/anaconda3/envs/py37/lib/python3.7/base64.py'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 2463, in __call__
return self.wsgi_app(environ, start_response)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 2449, in wsgi_app
response = self.handle_exception(e)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask_restful/__init__.py", line 269, in error_router
return original_handler(e)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 1866, in handle_exception
reraise(exc_type, exc_value, tb)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/_compat.py", line 38, in reraise
raise value.with_traceback(tb)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 2446, in wsgi_app
response = self.full_dispatch_request()
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 1951, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask_restful/__init__.py", line 269, in error_router
return original_handler(e)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 1820, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/_compat.py", line 38, in reraise
raise value.with_traceback(tb)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 1949, in full_dispatch_request
rv = self.dispatch_request()
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask/app.py", line 1935, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask_restful/__init__.py", line 462, in wrapper
return self.make_response(data, code, headers=headers)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask_restful/__init__.py", line 491, in make_response
resp = self.representations[mediatype](data, *args, **kwargs)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/site-packages/flask_restful/representations/json.py", line 21, in output_json
dumped = dumps(data, **settings) + "\n"
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/__init__.py", line 238, in dumps
**kw).encode(obj)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/encoder.py", line 201, in encode
chunks = list(chunks)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/encoder.py", line 431, in _iterencode
yield from _iterencode_dict(o, _current_indent_level)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/encoder.py", line 405, in _iterencode_dict
yield from chunks
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/encoder.py", line 438, in _iterencode
o = _default(o)
File "/Users/mohammad/anaconda3/envs/py37/lib/python3.7/json/encoder.py", line 179, in default
raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type bytes is not JSON serializable
akbari59 commented
That would be great, Thanks.
Mohammad
…On Mon, Aug 12, 2019 at 2:13 AM Melih Çolpan ***@***.***> wrote:
Hello Akbar,
Some parts of the project are outdated and need to be updated. At the same
time, my experience with the flask has increased much more after long
projects. The structure of the best case has become clearer over the years.
I'm going to rewrite this project next week. Or rather, I'm going to
overhaul every part of it and push it into this repository. If the problem
is solved in the current situation, I will close this issue.
Yours truly
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#5?email_source=notifications&email_token=ABIW5LNR62XR33OBNJ3R65DQECBZRA5CNFSM4IKYYSEKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD4BJODQ#issuecomment-520263438>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABIW5LPB2GFRSS5FXNFTIELQECBZRANCNFSM4IKYYSEA>
.
--
Best Regards
Mohammad Akbari
tishacian commented
Hello,
I have the same issue when accessing the login route. Do you have an update about that ?
Btw, thanks a lot for this inspiring project and thanks in advance for your time
melihcolpan commented
Hello Tishacian and Akbari,
I included it in the planning, but unfortunately it has gone unnoticed. I published the fix, thank you for reporting.
Cordially