Remove and return an item from the queue. If optional args block is true and timeout is None (the default), block if necessary until an item is available.
from itertools import zip_longest
l = ['2018-01-01', 'yandex', 'cpc', 100]
for z in zip_longest(*[iter(l)] * 4):
first, second, third, forth = z
print({first:{second:{third:forth}}})