discuss-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

self.set_history error for python custom block


From: krono86
Subject: self.set_history error for python custom block
Date: Thu, 21 Sep 2023 17:02:08 +0200

Hello List!
I'm trying to implement a sync block into a OOT module that use previous samples of the input streams.
So, I'm using the method set_history in the constructor.
The problem is that when I use self.set_history(N) I obtain the following errors:

Generating: '/home/userr/workspace/gnuradio-oot/gr-customModule/examples/untitled.py'

Executing: /usr/bin/python3 -u /home/user/workspace/gnuradio-oot/gr-customModule/examples/untitled.py

QSocketNotifier: Can only be used with threads started with QThread
Traceback (most recent call last):
  File "/home/user/workspace/gnuradio-oot/gr-customModule/examples/untitled.py", line 291, in <module>
    main()
  File "/home/user/workspace/gnuradio-oot/gr-customModule/examples/untitled.py", line 269, in main
    tb = top_block_cls()
         ^^^^^^^^^^^^^^^
  File "/home/user/workspace/gnuradio-oot/gr-customModule/examples/untitled.py", line 179, in __init__
    self.customModule_testBlock_0_0 = customModule.testBlock(1, max_lag, lags, alpha, win_len, 1, False)
                                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.11/dist-packages/gnuradio/customModule/testBlock.py", line 33, in __init__
    self.set_history(self.max_pos_lag-self.min_neg_lag+1)
    ^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/gnuradio/gr/gateway.py", line 129, in __getattr__
    if not hasattr(self, "gateway"):
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/gnuradio/gr/gateway.py", line 129, in __getattr__
    if not hasattr(self, "gateway"):
           ^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/gnuradio/gr/gateway.py", line 129, in __getattr__
    if not hasattr(self, "gateway"):
           ^^^^^^^^^^^^^^^^^^^^^^^^
  [Previous line repeated 984 more times]
RecursionError: maximum recursion depth exceeded

>>> Done (return code 1)

I'm using GNU Radio 3.10.5.1 (Python 3.11.2) on Debian 12.
What is going on?
Thanks in advance!
Ivan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]