nager/Nager.Date

Incorrect Long Weekend query results for Finland

Closed this issue · 3 comments

Affected country

Finland

Affected public holiday

Christmas Days

Source of the information

https://publicholidays.fi/2024-dates/

More information

Request URL: https://date.nager.at/api/v3/LongWeekend/2024/FI

Expected query result: There is only one long weekend in December 2024, i.e. 06 (Fri) - 08 (Sun). Hence only this date should be listed in the response body (and it is listed correctly).

Actual query result: After 06-Dec, next public holidays in December are on 24-Dec (Tue), 25-Dec (Wed) and 26-Dec (Thu). Hence they should not be listed in the results. However, strange dates are being displayed in the response body. Please check below:

{
    "startDate": "2024-12-21",
    "endDate": "2024-12-24",
    "dayCount": 4,
    "needBridgeDay": true
},
{
    "startDate": "2024-12-24",
    "endDate": "2024-12-29",
    "dayCount": 6,
    "needBridgeDay": true
},
{
    "startDate": "2024-12-21",
    "endDate": "2024-12-25",
    "dayCount": 5,
    "needBridgeDay": true
},
{
    "startDate": "2024-12-21",
    "endDate": "2024-12-26",
    "dayCount": 6,
    "needBridgeDay": true
}

There are possible variants with the inclusion of a bridge day
image

Thanks very much for the clarification @tinohager (also many thanks for this API)!

However, just wondering if it simpler to add only 3 scenarios so that the response would look something like:

{
    "startDate": "2024-12-21",
    "endDate": "2024-12-26",
    "dayCount": 6,
    "needBridgeDay": true
},
{
    "startDate": "2024-12-24",
    "endDate": "2024-12-29",
    "dayCount": 6,
    "needBridgeDay": true
},
{
    "startDate": "2024-12-21",
    "endDate": "2024-12-29",
    "dayCount": 9,
    "needBridgeDay": true
}

Scenario 1: 21 (Sat) - 26 (Thu)
Scenario 2: 24 (Tue) - 29 (Sun)
Scenario 3: 21 (Sat) - 29 (Sun)

Hi can you explain to me what you are using the api for and why it is causing problems for you?