Not coercible to endpoint: %s" % (x,)

I’m trying to modify some code from the multi_fft.py example file and
don’t understand what an error message is trying to tell me.
I’ve searched with little success.

The original works, but anything I’ve tried to do (e.g. am
demodulation, audio output, resampling) fails with a similar “not
coercible to endpoint” message.

Original code segment:

for i in range(nchan):
scope = fftsink.fft_sink_c(self, panel,
sample_rate=input_rate/sw_decim,
title=“Input %d” % (i,),
ref_level=80, y_per_div=20)
vbox.Add(scope.win, 10, wx.EXPAND)

         if options.filter:
             chan_filt = gr.fir_filter_ccf(sw_decim,

chan_filt_coeffs)
self.connect((di, i), chan_filt, scope)
else:
self.connect((di, i), scope)

Modified segment:

for i in range(nchan):
scope = fftsink.fft_sink_c(self, panel,
sample_rate=input_rate/sw_decim,
title=“Input %d” % (i,),
ref_level=80, y_per_div=20)
vbox.Add(scope.win, 10, wx.EXPAND)

  rr = blks2.rational_resampler_ccf(3, 2)

         if options.filter:
             chan_filt = gr.fir_filter_ccf(sw_decim,

chan_filt_coeffs)
self.connect((di, i), chan_filt, rr, scope)

         else:
             self.connect((di, i), scope)

raise ValueError, “Not coercible to endpoint: %s” % (x,)

#ValueError: Not coercible to endpoint:
<gnuradio.blks2impl.rational_resampler.rational_resampler_ccf object
at #0x8d94aac>

Dick…

Dear Richard J.

Did you find the ANS or solution.

I got same problem. when I use band pass filter. I got the message Not
coercible to endpoint. I did not solve this problem.

But, I found a discussion in other place.
Maybe you can tell me, what does he means?

==============================================================
by Eric B. Feb 05, 2008
reply: On Tue, Feb 05, 2008 at 12:21:37AM -0800, Fasika A. wrote:

“/usr/local/lib/python2.5/site-packages/gnuradio/gr/basic_flow_graph.py”, line 84, in coerce_endpoint
raise ValueError, “Not coercible to endpoint: %s” % (x,)
ValueError: Not coercible to endpoint: <gnuradio.blks2impl.gmsk.gmsk_demod object at 0xb649deac>

You can’t mix flow_graph and blk2. You should be subclassing
gr.top_block, not gr.flow_graph