Romanian public holidays are a moving target, and your deadline counter is wrong
· 4-minute read · Engineering · by Direct Softworks
Orthodox Easter moves every year on a different calendar to the Western one. Hard-code a holiday list and your working-day arithmetic expires quietly, in spring.

Any Romanian business system eventually needs to count working days. Payment terms. Delivery windows. The five working days for transmitting an invoice to e-Factura. Statutory notice periods.
Counting working days needs a holiday calendar, and the Romanian one is harder than it looks for one specific reason.
The problem is Easter, twice over
Most Romanian public holidays are fixed dates. New Year, 24 January, 1 May, 1 June, 1 December, Christmas. Those are easy.
Then there is Orthodox Easter, with Good Friday and Easter Monday, and Pentecost fifty days later, also two days. That is four or five moving days depending on how you count, and they move by a lot: Orthodox Easter can fall anywhere from early April to early May.
Two things make it worse than the equivalent problem elsewhere.
It is not Western Easter. The Orthodox date is computed on the Julian calendar and then converted, so it usually differs from the Catholic and Protestant date, sometimes by a week, sometimes by more than a month. Any library or list you find that says "Easter" probably means the Western one. Using it produces a calendar that is correct in the years the two coincide and silently wrong in the years they do not, which is most of them.
Pentecost depends on it. Get Easter wrong and you get a second pair of wrong days seven weeks later, so the error appears twice in a spring and nobody connects the two.
And on top of the algorithmic ones, the government occasionally declares an additional non-working day to bridge a holiday that falls on a Tuesday or Thursday. Those are announced, not computed, and no algorithm produces them.
Why hard-coding fails quietly
The natural first implementation is a list of dates for the current year, or the next two.
It works. It keeps working. Then it runs off the end of the list, and what happens next is the problem: an absent date is not an error, it is a working day. So the system does not fail, it silently starts counting Easter Monday as a working day and every deadline computed through that week is one day early or late.
Nobody notices in testing, because tests do not usually run in April. Nobody notices in production, because a deadline being wrong by a day looks like a normal deadline.
If you take one thing from this: a hard-coded holiday list must know when it runs out, and say so. Store the last year the list covers, and make the working-day function throw, or at least alarm loudly, when asked about a date beyond it. A noisy failure in January beats a quiet wrong answer in April.
What to do instead
Compute the fixed days, compute the movable ones from Orthodox Easter, and keep a small manual list of the bridge days.
The Easter calculation is the Meeus Julian algorithm, and it is short. What matters is testing it against known dates from published sources for a spread of years, including years where the Orthodox and Western dates diverge widely, because that is exactly the case a wrong implementation gets wrong.
Treat the bridge days as data, not code. They are announced each year. A small table, updated annually, with an obvious place to put them. And the same expiry rule applies: if the table has nothing for the coming year, that is worth an alert in December rather than a surprise in June.
Put it in one function. isWorkingDay(date) and addWorkingDays(date, n), used everywhere. The failure we see most often is not a wrong calendar, it is three different calendars in one codebase, because three developers each needed working days and each solved it locally.
Test the boundaries, not the middle. The bugs are all at edges: a deadline starting on a Friday, a period spanning Easter, a run that crosses the New Year, a period entirely inside a holiday week.
The related trap
Deadlines expressed in hours instead of working days.
A queue that fires 120 hours after invoice issue was correct when the rule was five calendar days, and became wrong when the e-Factura window moved to five working days in January 2026. Nothing errored. The counter kept counting, and it is now wrong in the safe direction most weeks and in the expensive direction precisely around Easter and early December, which is when the holidays cluster.
That is the shape of every bug in this article: not a crash, not an exception, just arithmetic that used to be right and quietly is not, in a week when everybody is on holiday and nobody is looking.