class Question(models.Model):
title = ...
slug = ...
class Answer(models.Model):
question = models.ForeignKey(Question, on_delete=... )
order = models.IntegerField(_('Очередность ответов'), ...)
is_right = models.BooleanField(_('Является ли правильным'), ...)
...
как сделать так, чтобы при появлении нового платежа можно было получить данные из него?
Вх1 . Вх2 . Выход
0 0 1
0 1 1
1 0 1
1 1 0
Python 2.7, Ubuntu 18.04, pymatgen-2019.7.2
The pymatgen development team will phase out Py2k support over the course of 2018. From v2018.1.1, new features implemented in pymatgen no longer need to support Py2k (i.e., unittests do not need to pass Py2k testing), though existing features will still be Py2k compatible. From v2019.1.1, pymatgen will be Py3k only.
Users who need Python 2.7 support should install v2018.x, you may also need to enforce an older version of numpy (`pip install numpy==1.16.4 `).
import re
str1 = """text[{"requestId":"1570025055889434-3249353475-man1-4890","title":"село Александрия""address":"Россия, Республика Республика, район, село ","coordinates":[47.574769,42.318674]]}text"""
print(re.findall("text(.*)text", str1)[0])