Hi dev.to — I'm Ray, a retail trader with a day job, and this is my weekend side project: Pine2Py (pine2py.com).
The problem was my own. I'd prototype a strategy in Pine Script on TradingView, then want to backtest it properly in Python — on my own data, across more symbols, with parameters swept systematically. Hand-rewriting worked, but every rewrite risked quietly changing the strategy's logic, and I never fully trusted a backtest of code that might not be the strategy I charted.
So I built the converter I wanted. It's a real transpiler — a full Pine front-end parser, not regex find-and-replace. Paste a Pine Script v5 or v6 indicator or strategy, get back a single readable Python file (types annotated, structure preserved) that runs bar-by-bar on your own OHLCV data through the PyneCore runtime.
Some numbers, because specifics matter: I tested it against a corpus of 1,909 real-world scripts. In my testing, 99.7% compile and 98.4% fully translate. The rest fail loudly with diagnostics — I'd rather tell a user "this construct isn't supported" than hand them subtly wrong code and a backtest they can't trust.
The least obvious lesson of the project: a transpiler is only as correct as the runtime under it. Two classes of scripts crashed because of bugs in the stock runtime, not in my translation. I ended up shipping a patched runtime build alongside the converter (free download on the site) and being explicit that stock PyPI PyneCore isn't supported. Testing the translator + runtime as a pair, on adversarial scripts, is the thing I'd do from day one if I started over.
Monetisation, kept deliberately simple: a free account (sign-in by email code, no password, no card) includes 3 conversions. Pro is $12/month for unlimited, paid through Paddle. I opened the paid tier a few days ago, so the honest revenue figure right now is: just launched.
It won't make anyone's strategy profitable — it's a converter, not a signal. It just moves your code faithfully so your backtests mean what you think they mean.
If you've ported trading code between languages, or you're building dev tools solo, I'd love to hear what worked for you — and if you try it, throw your ugliest script at it and tell me what breaks. Those reports are how the last few percent got fixed.
— Ray
Top comments (0)