After calling CustomTicksDelete() method, ticks are properly deleted from ticks database of the custom symbol.
But, when adding new ticks to the database results in error if their times_msc value happens before the last time_msc value that was there.
Only ticks added after are able to be added.
This can be a bug. Otherwise, how to properly handle this, please?
Agreed. That's why it is written 'possibly a bug'.
For a test case, we have this code which started acting weird since build 1930. It has been working just fine in any build before it.
Just add a CustomTicksDelete(...) call in it and watch it how it goes.
Do you really want to have it fixed ?
Provide a test case yourself please.
I saw similar "bug/feature" occured sporadically in builds much earlier than 1940. The only obvious workaround I know is to show a warning and suggest a user to clean up the custom symbol and recreate it anew or do it from your MQL code.
When I first started playing with Custom Symbols (can't remember the build), I had a similar problem, and believed I had narrowed down the problem happening due to delays in MetaTrader updating and flushing the files to disk. I would often delete the files completely and restart the process.
However, since then, I have not used that function anymore, so never encountered the problem again.