0

I'm trying data subscription feature of TDengine.

I tested its Python demo.

from taos.tmq import TaosConsumer

# Syntax: `consumer = TaosConsumer(*topics, **args)`
#
# Example:
consumer = TaosConsumer('topic1', 'topic2', td_connect_ip = "127.0.0.1", group_id = "local")

...

When executing the script, there is an error information:

ImportError: cannot import name 'TaosConsumer'

Did I miss some steps?

JamesLiu
  • 1
  • 2

1 Answers1

0

I think you need to update the version of taospy on your system - taospy is the TDengine connector for Python.

Try running pip install -U taospy to update it and then do your test again.

Make sure you're running Python 3.7 or later.

drcstov
  • 1
  • 1