# How to run two node in different thread?

**URL:** <https://forum.opencyphal.org/t/how-to-run-two-node-in-different-thread/1588>\
**Category:** PyCyphal\
**Created:** [February 7, 2022, 7:00am UTC](https://forum.opencyphal.org/t/how-to-run-two-node-in-different-thread/1588 "2022-02-07T07:00:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![geeed](https://forum.opencyphal.org/letter_avatar_proxy/v4/letter/g/3da27b/32.png) [@geeed](https://forum.opencyphal.org/u/geeed)\
**Post date:** [February 7, 2022, 7:00am UTC](https://forum.opencyphal.org/t/how-to-run-two-node-in-different-thread/1588/1 "2022-02-07T07:00:54Z")

</div>

I try several ways but error arise, such as:

```auto
RuntimeError: Task <Task pending name='Task-18' coro=<Queue.get() running at /usr/lib/python3.8/asyncio/queues.py:163> cb=[_release_waiter(<Future pendi...66ff9b610>()]>)() at /usr/lib/python3.8/asyncio/tasks.py:429]> got Future <Future pending> attached to a different loop

```

What is the typical way to create a uavcan node running on an independent thread? Could you show me a demo?  
Thanks a lot!

---

<div class="post-metadata">

**Author:** ![pavel.kirienko](https://forum.opencyphal.org/user_avatar/forum.opencyphal.org/pavel.kirienko/32/9_2.png) [@pavel.kirienko](https://forum.opencyphal.org/u/pavel.kirienko)\
**Post date:** [February 7, 2022, 1:11pm UTC](https://forum.opencyphal.org/t/how-to-run-two-node-in-different-thread/1588/2 "2022-02-07T13:11:11Z")

</div>

First, you start the thread, then you initialize the node in it. You can’t start a node in one thread and continue using it in a different thread, this is an intentional limitation of asyncio.
