Traceback (most recent call last):


 "/home/allen/.local/share/virtualenvs/scraper-etbRBiK9/lib/python3.6/site-packages/ruia/spider.py", line 383, in handle_request

callback_result, response = await request.fetch_callback(self.sem)


 "/home/allen/.local/share/virtualenvs/scraper-etbRBiK9/lib/python3.6/site-packages/ruia/request.py", line 159, in fetch_callback

callback_result = await self.callback(response)


 "/mnt/f/workspace/git/scraper/scraper/cnu.py", line 92, in save_image

await f.write(response.html)


 "/home/allen/.local/share/virtualenvs/scraper-etbRBiK9/lib/python3.6/site-packages/aiofiles/threadpool/utils.py", line 36, in method

return (yield from self._loop.run_in_executor(self._executor, cb))


 "/usr/lib/python3.6/concurrent/futures/thread.py", line 56, in run

result = self.fn(*self.args, **self.kwargs)
TypeError: a bytes-like object is required, not 'str'

Traceback (most recent call last):


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/worker.py", line 205, in start

self.blueprint.start(self)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/bootsteps.py", line 119, in start

step.start(parent)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/bootsteps.py", line 369, in start

return self.obj.start()


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/consumer/consumer.py", line 317, in start

blueprint.start(self)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/bootsteps.py", line 119, in start

step.start(parent)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/consumer/consumer.py", line 593, in start

c.loop(*c.loop_args())


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/loops.py", line 88, in asynloop

update_qos()


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/kombu/common.py", line 417, in update

return self.set(self.value)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/kombu/common.py", line 410, in set

self.callback(prefetch_count=new_value)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/consumer/tasks.py", line 47, in set_prefetch_count

apply_global=qos_global,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/kombu/messaging.py", line 558, in qos

apply_global)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/channel.py", line 1812, in basic_qos

wait=spec.Basic.QosOk,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/abstract_channel.py", line 59, in send_method

return self.wait(wait, returns_tuple=returns_tuple)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/abstract_channel.py", line 79, in wait

self.connection.drain_events(timeout=timeout)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/connection.py", line 491, in drain_events

while not self.blocking_read(timeout):


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/connection.py", line 497, in blocking_read

return self.on_inbound_frame(frame)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/method_framing.py", line 77, in on_frame

callback(channel, msg.frame_method, msg.frame_args, msg)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/connection.py", line 501, in on_inbound_method

method_sig, payload, content,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/abstract_channel.py", line 128, in dispatch_method

listener(*args)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/amqp/channel.py", line 1597, in _on_basic_deliver

fun(msg)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/kombu/messaging.py", line 624, in _receive_callback

return on_m(message) if on_m else self.receive(decoded, message)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/consumer/consumer.py", line 567, in on_task_received

callbacks,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/strategy.py", line 157, in task_message_handler

if (req.expires or req.id in revoked_tasks) and req.revoked():


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/request.py", line 280, in revoked

'expired' if expired else 'revoked', False, None, expired,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/worker/request.py", line 263, in _announce_revoked

self.id, reason, request=self, store_result=self.store_errors,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/backends/base.py", line 191, in mark_as_revoked

traceback=None, request=request)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/backends/base.py", line 322, in store_result

request=request, **kwargs)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django_celery_results/backends/database.py", line 35, in _store_result

task_kwargs=task_kwargs,


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django_celery_results/managers.py", line 50, in _inner

return fun(*args, **kwargs)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django_celery_results/managers.py", line 126, in store_result

obj, created = self.get_or_create(task_id=task_id, defaults=fields)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django/db/models/manager.py", line 82, in manager_method

return getattr(self.get_queryset(), name)(*args, **kwargs)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django/db/models/query.py", line 488, in get_or_create

return self._create_object_from_params(lookup, params)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django/db/models/query.py", line 521, in _create_object_from_params

params = {k: v() if callable(v) else v for k, v in params.items()}


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/django/db/models/query.py", line 521, in <dictcomp>

params = {k: v() if callable(v) else v for k, v in params.items()}


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/app/trace.py", line 642, in __protected_call__

return orig(self, *args, **kwargs)


 "/opt/rh/rh-python36/root/usr/lib/python3.6/site-packages/celery/app/task.py", line 375, in __call__

return self.run(*args, **kwargs)
TypeError: add() missing 2 required positional arguments: 'x' and 'y'
