mirror of
https://github.com/sprockets/sprockets.mixins.avro-publisher.git
synced 2024-11-28 19:29:55 +00:00
Flake8: fixes after running flake8
This commit is contained in:
parent
a06f5ef614
commit
95f8f987ba
2 changed files with 14 additions and 13 deletions
|
@ -14,9 +14,10 @@ import io
|
||||||
import json
|
import json
|
||||||
import logging
|
import logging
|
||||||
|
|
||||||
from sprockets.mixins import amqp, http
|
|
||||||
import fastavro
|
import fastavro
|
||||||
|
|
||||||
|
from sprockets.mixins import amqp, http
|
||||||
|
|
||||||
__version__ = '3.0.0'
|
__version__ = '3.0.0'
|
||||||
|
|
||||||
LOGGER = logging.getLogger(__name__)
|
LOGGER = logging.getLogger(__name__)
|
||||||
|
|
|
@ -1,29 +1,29 @@
|
||||||
import json
|
|
||||||
import io
|
import io
|
||||||
import os
|
import json
|
||||||
import sys
|
|
||||||
import logging
|
import logging
|
||||||
|
import os
|
||||||
import random
|
import random
|
||||||
|
import sys
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
from tornado import concurrent, locks, testing, web
|
|
||||||
import fastavro
|
import fastavro
|
||||||
from pika import spec
|
from pika import spec
|
||||||
|
from tornado import concurrent, locks, testing, web
|
||||||
|
|
||||||
from sprockets.mixins import amqp, avro_publisher
|
from sprockets.mixins import amqp, avro_publisher
|
||||||
|
|
||||||
LOGGER = logging.getLogger(__name__)
|
LOGGER = logging.getLogger(__name__)
|
||||||
|
|
||||||
MESSAGE_TYPE = "example.avro.Test"
|
MESSAGE_TYPE = 'example.avro.Test'
|
||||||
|
|
||||||
AVRO_SCHEMA = {
|
AVRO_SCHEMA = {
|
||||||
"namespace": "example.avro",
|
'namespace': 'example.avro',
|
||||||
"type": "record",
|
'type': 'record',
|
||||||
"name": "User",
|
'name': 'User',
|
||||||
"fields": [
|
'fields': [
|
||||||
{"name": "name", "type": "string"},
|
{'name': 'name', 'type': 'string'},
|
||||||
{"name": "favorite_number", "type": ["int", "null"]},
|
{'name': 'favorite_number', 'type': ['int', 'null']},
|
||||||
{"name": "favorite_color", "type": ["string", "null"]}]}
|
{'name': 'favorite_color', 'type': ['string', 'null']}]}
|
||||||
|
|
||||||
|
|
||||||
def deserialize(value):
|
def deserialize(value):
|
||||||
|
|
Loading…
Reference in a new issue