PyneCore v6.9.4 released — scripts can now declare their own timeframe in indicator(),…

Features

  • Script-level timeframe / timeframe_gaps in indicator(): the script runs once per completed period aggregated from the chart feed, with na or forward-filled values on the other chart bars. No higher-timeframe value is ever visible early.
  • timeframe.period, main_period, multiplier, time(""), time_close and bars_back follow the declared run timeframe; syminfo.period keeps describing the data grid.

Fixes

  • Orders resting at one price level now trigger in the order they reached the book, not entries first.
  • An exit leg activated behind a reversing entry is no longer cancelled by that entry’s fill; it closes what is left and opens the remainder under its own exit id.
  • An exit leg bound to an entry that fills intrabar gets the rest of that bar’s path instead of waiting for the next bar.
  • strategy.exit now covers pyramid adds that fill after the call, sized and priced from their own fill; trailing legs seed their water mark from the entry they are bound to.
  • array.join()’s separator is optional — TradingView defaults it to the empty string.
  • ta.valuewhen()’s occurrence ring stays out of the bar rollback, so a calc_on_order_fills bar records one push per execution.
  • lib.time inside a nested helper reads history on the chart-bar grid instead of its own call grid.
  • time_close on D/W/M bars returns the end of the last scheduled session of the period, including effective-dated session corrections.
  • A request.security context’s own read falls back to the caller’s default instead of returning None before the first publication.

Performance

  • Security ring lookups are binary searches instead of copying the whole close column: a daily plus 1-minute context run went from over 2100 seconds to 161, with every plot still matching.

Full release notes: https://github.com/PyneSys/pynecore/releases/tag/v6.9.4