Compute bank holidays for France
Branch: master
Clone or download
Latest commit 41f28a9 Jan 5, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci Circle: cache by Python version #2 Oct 15, 2018
jours_feries_france Pentecôte to Lundi de Pentecôte Jan 5, 2019
tests Pentecôte to Lundi de Pentecôte Jan 5, 2019
.gitignore First commit Jul 4, 2018
LICENSE First commit Jul 4, 2018
README.md Pentecôte to Lundi de Pentecôte Jan 5, 2019
setup.cfg First commit Jul 4, 2018
setup.py Release 0.4 Jan 5, 2019

README.md

Software License CircleCI

Jours Fériés France

This library computes bank holidays dates for France, for a given year.

Installation

pip install jours-feries-france

Usage

from jours_feries_france.compute import JoursFeries

res = JoursFeries.for_year(2018)
# res is now a dict
# {
#     'Armistice': datetime.date(2018, 11, 11),
#     'Ascension': datetime.date(2018, 5, 10),
#     'Assomption': datetime.date(2018, 8, 15),
#     'Fête Nationale': datetime.date(2018, 7, 14),
#     'Fête du travail': datetime.date(2018, 5, 1),
#     "Jour de l'an": datetime.date(2018, 1, 1),
#     'Lundi de Pâques': datetime.date(2018, 4, 2),
#     'Noël': datetime.date(2018, 12, 25),
#     'Lundi de Pentecôte': datetime.date(2018, 5, 21),
#     'Toussaint': datetime.date(2018, 11, 1),
#     'Victoire des alliés': datetime.date(2018, 5, 8)
# }

# You can also get specific bank holidays as a datetime.date
print (JoursFeries.lundiDePaques(2018))
print (JoursFeries.ascension(2018))
print (JoursFeries.pentecote(2018))
print (JoursFeries.jourDeLAn(2018))
print (JoursFeries.feteDuTravail(2018))
print (JoursFeries.victoireDesAllies(2018))
print (JoursFeries.feteNationale(2018))
print (JoursFeries.toussaint(2018))
print (JoursFeries.assomption(2018))
print (JoursFeries.armistice(2018))
print (JoursFeries.noel(2018))

# The Alsace-Moselle region has 2 extra bank holidays.
# You can include them this way
res = JoursFeries.for_year(2018, include_alsace=True)

print (JoursFeries.vendrediSaint(2018))
print (JoursFeries.saintEtienne(2018))

Data

If you just want a CSV dump, check out the "Jours fériés en France" opendata dataset available on data.gouv.fr.

REST API

Looking for a JSON API? Check out this GitHub project.

School holidays

Interested in school holidays as well (vacances scolaires in French)? There is another pip package for this! Check out https://github.com/AntoineAugusti/vacances-scolaires-france

Notice

This software is available under the MIT license and was developed as part of the Entrepreneur d'Intérêt Général program by the French government.

Projet développé dans le cadre du programme « Entrepreneur d’intérêt général ».