10000 中華民國 Taiwan Holidays Calculation Incorrect · Issue #490 · commenthol/date-holidays · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
中華民國 Taiwan Holidays Calculation Incorrect #490
Open
@bai-yi-bai

Description

@bai-yi-bai

Hi,

I discovered the public holiday calculation for 中華民國 Taiwan are incorrect when using stretch-my-time-off which uses date-holidays as a source. zachd/stretch-my-time-off#11.
I am not a expert on how things work in Taiwan, but these are great tools I want to improve. I didn't want to make a PR because I am not 100% sure how to fix all the problems.

Let's start with the reference calculated dates by date-holidays for 中華民國 Taiwan for 2025 and compare it to official Taiwanese government data. According to Directorate-General of Personnel Administration, Executive Yuan 2025Work Calendar and https://focustaiwan.tw/society/202406270019, there are several discrepancies for 2025, and the DPGA maintains a calendar list going back to 2001.

I found three issues looking at 2025, but there could be more:

  1. 農曆除夕 Chinese New Year starts 2025-01-27 and ends of 2025-01-31
  2. 兒童節 + 淸明節 Children's Day & Tomb Sweeping Day starts 2025-04-03 and ends 2025-04-04
  3. 端午節 Dragon Boat Festival is 2025-05-30

Chinese New Year

It looks like several years are incorrect.

  1. Possible Typo?

chinese 01-0-01 if Monday then next Friday if Tuesday then next Saturdayif Wednesday then next Sunday if Thursday then next Monday if Friday then next Tuesday if Saturday then next Wednesday if Sunday then next Thursday:
contains "Saturdayif" is this supposed to contain a space? "Saturday if"?

  1. Possible Incorrect Placement of Conditional for Chinese New Year's Eve / Chinese New Year

Should the "if" statement for "農曆年初一" instead be "除夕" Move it from the first day 一 to the Eve? From line 27 to line 23?

  1. Make-up Days

One other issue with date-holidays is that I'm not sure it can include the concept of work days. For example, 2025-02-08 is a "make-up" work day.

"The day before Lunar New Year's Eve which falls on Jan. 27, a Monday, is also designated a holiday and will be made up on a later Saturday on Feb. 8, the DGPA said in a press release."

兒童節 + 淸明節 Children's Day & Tomb Sweeping Day

According to the DPGA:

  1. Children’s Day: 1 day of holiday. If the Children’s Day falls on the same day as Tomb Sweeping Day, the holiday will be held the day before. However, if Children’s Day falls on a Thursday, the holiday will be held the following day.

So, somehow additional logic would need to be implemented to handle this.

端午節 Dragon Boat Festival

customary holidays involve a day off except for Chinese New Year with three consecutive days off

So, somehow an additional day needs to be added. I don't know if the current language for date-holidays supports this.

How to Proceed

I suppose, I found this problem and perhaps I can help make the data match the official calendars...

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0