Closed devoplot closed 4 months ago
Do you have the full stack? Which version of .NET your program is running under ? Maybe the logs also
ok I think I found the problem. What you describe is actually a side-effect of having the SessionStore.Write throw an exception (pretty bad behavior for production code - Heroku example is just a demo, not production-grade code).
This means you likely have had a DB error happening before that exception. Check your logs. That DB exception messed with the internal state of session JsonWriter which then fails on all future calls to Session.Save.
In any case, I will harden Session.Save to prevent the exception you described. But you should seek to resolve your DB writing problems.
I faced with the strange error that occasionally happened :
but right now I see it almost on each API call.
I use WTelegramClient" 4.0.0 ( tried as well 4.0.1) and PostgreSQL to store session as in example https://github.com/wiz0u/WTelegramClient/blob/master/Examples/Program_Heroku.cs