Skip to content

Conversation

@gezmisozkan
Copy link

Hi, I found an issue in timestamp parsing on Windows. When fetching symbols
with very old history (e.g. XAUUSD on OANDA), TradingView returns negative
Unix timestamps for pre-1970 data. datetime.fromtimestamp raises OSError on
Windows for negative values, causing get_hist to fail.

Replacing fromtimestamp with an epoch + timedelta(seconds) calculation fixes
the problem and works consistently across Windows, Linux, and macOS. I can
submit a PR if you’d like.

…stamps

on Windows and restore full historical XAUUSD data.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant