{
  "id": 22937563,
  "title": "Stop hard-coding holidays: 4 free calendar datasets for developers",
  "url": "https://urgent.news/2026/12/01/stop-hard-coding-holidays-4-free-calendar-datasets-for-developers",
  "topic": "tech",
  "section": "Tech",
  "published": "2026-12-01T10:09:34.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/toolwix/stop-hard-coding-holidays-4-free-calendar-datasets-for-developers-153j"
  },
  "original_language": null,
  "account": "Developers should avoid hard-coding holidays in their code, as bugs often arise during holidays, clock changes, or when the library lacks support for a specific calendar. To address this issue, ToolWix has published four calendar datasets as plain CSV and JSON files, generated from the same code used for their date tools. These datasets are licensed under CC BY 4.0, allowing commercial use with proper attribution.\n\nThe first dataset contains business days and payroll dates from 2026 to 2030 for US, UK (three regions), Canada, and Australia. It can be used to add business days while skipping holidays by leveraging the pandas library in Python. The code example demonstrates how to add three business days to a given date, skipping US national holidays. However, it is recommended to raise an error for dates outside the specified range instead of treating them as regular days.\n\nThe second dataset focuses on paydays that move according to a common convention of paying on the previous business day. It includes data for the US region with weekly schedules and scheduled pay dates.\n\nThe third dataset details DST (Daylight Saving Time) clock changes for New York and London in 2027. It shows when the US moves forward on 14 March and the UK on 28 March, as well as when they move back on 31 October (UK) and 7 November (US), causing a 9:00 New York meeting to occur at different London times during the transition period.\n\nThe fourth dataset offers a solution for converting dates to the Nepali calendar in JavaScript, known as Bikram Sambat. Since Nepali month lengths are not based on a consistent formula, a lookup table is the practical approach. The provided code fetches the dataset from GitHub and creates a mapping of Gregorian dates to their corresponding Bikram Sambat dates. It is suggested to bundle a copy of the file for production use rather than fetching it from GitHub at runtime.\n\nLastly, the fifth dataset provides world calendars from 2026 to 2030, featuring seven calendars side by side. This dataset can be accessed using the Hugging Face dataset library in Python.",
  "summary": "Date bugs rarely show up on the day you write the code. They show up on a holiday, on a clock-change weekend, or when someone needs a calendar your library does not have. We publish four calendar datasets as plain CSV and JSON, generated from the same code as the date tools on ToolWix (disclosure: that is our site). They are CC BY 4.0, so commercial use is fine with credit. Dataset Covers Links…",
  "summary_source": "publisher",
  "key_points": [],
  "editors_take": null,
  "opinion": false,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "machine_translated": false,
  "ai_generated": true,
  "disclaimer": "Accounts, briefs, key points, the editor’s take and translations are written by software from other outlets’ reporting and may contain errors. A summary whose summary_source is \"publisher\" is the outlet’s own feed text. Always check the linked original."
}