I've encountered what I think it's a bug. Creating a simple indicator with this OnBarUpdate:
this.Print( "barsAgo " + this.Input[ 0 ] ); this.Print( "barIndex " + this.Input.GetValueAt( this.CurrentBar ) );
Can you check this bug on your end?
Thanks.

Comment