V
V
Viktor Paperno2018-08-20 05:04:21
Python
Viktor Paperno, 2018-08-20 05:04:21

What to do if an array is written in a Python string?

I'm trying to get information using the requests library . It comes in this format:
b'[{},{}]
How do I convert this to a list?
eval does not work, due to the fact that there is a complex structure inside.
I need to convert this to a list of dictionaries.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question