Setting Parameter Expression during Replication not working

Hi,

I’m trying to set a paramater to an expression during replication and it’s not working.

I don’t get any errors. It’s just that the node is still using a numeric value after replication is done.

Here’s the simplified code that’s not working:

def replicate(comp, allOps, newOps, template, master):
	for c in newOps:
		c.op('trim1').par.start.expr = "op('../table_segments')[parent().digits,1]"
		pass

	return

‘trim1’ is a node inside the container being replicated.

This works fine if I do it from the Textport so I can’t figure out what I’m doing wrong.

EDIT: From Textport, after replication, this works:

op('/container1/base1/item0').op('trim1').par.start.expr = 'op("../table_segments")[parent().digits,1]'

EDIT2:
Upon further inspection, not even this is working inside the post replication loop:

	c.op('trim1').par.start.val = 2

Is there some limitation upon setting some values inside this loop?

Huh… that’s very strange.

What’s your OS and what version of Touch are you using?

Doing a quick pass at this I’m able to set the start and end pars on a trim CHOP. Does this show up correctly for you?
base_replicator_with_digits.tox (1.04 KB)

Very strange and interesting indeed…

I’m using an up-to-date Windows 10 on two different machines, with different 099 beta builds (2017.7180 & 2017.3340). My network doesn’t work on either one.

I just tried your .tox on build 3340 and it’s not working either. When I loaded your file the start and end parameters where set correctly as you had saved them, but when I recreated the OPs in the replicator they where all set to 0.

Here’s my component. Maybe you can try it to see if it works on your machine. I’m assuming you’re running on a Mac as it seems you didn’t run into this problem.

You’ll notice I’m also wiring the replicants inside the loop and that’s working fine, even though that code comes at the end of each iteration.
sample-grouper.tox (1.45 KB)

It’s because they’re set to be clones.

Your master op isn’t using an expression and is over writing your expressions that are being set programatically.

If you use the clone immmue flag you should be all set.
base_clone_immue.tox (1.5 KB)

Ahhh… Silly me, it’s working now.

Thanks!