Here in Spain is as @joez says, you can not skip numbers or not mantain de sequence or create subseries. Even more, now here a point-of-sale tickets are ‘simplified invoices’, like full invoices without customer data against the default account, but they have to print all information and taxes as a complete invoice. A billed invoice is inmutable, if you want change you must create a invoice that complement that with own number (here are called ‘facturas rectificativas’, i dont known how translate it sorry … )
Not being able to have numbering jumps, as @joez also says, it does not make sense to number invoices in draft state (in spain), or at least with the same series as the validated and accounted.
In other erps, what I have seen is that there are two types of secuence methods for the series. The ‘strict’ ones, which fulfill the above, and the ‘normal’ ones that would work as is now erpnext.
You can check it with the tryton demo in their website so you do not have to mount anything or try an propietary erp. In the configuration of each module you choose which method to use. What if you can, in the case of the invoices, is to start another series when you close the fiscal year, for example putting the year as a prefix of the series in each fiscal year.
I am a programmer, but we have financiers in the company, any doubt I can consult without problem.
This is a complex issue because every country has its system. The ideal approach will be not to do it in one way or another, but to create an open method (I do not think bad idea the tryton approach) and grow with community feedback.
These workflows are not for pleasure, or from the internal workflow of companies. They are rules dictated by the governments and the fiscal departments, are necessary to respect the laws of each country.