Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

In France, these rules are available as a website, an API, a NPM package, and raw rules in the https://publi.codes language.

https://mon-entreprise.urssaf.fr/développeur




Here's that NPM package: https://www.npmjs.com/package/modele-social and https://github.com/betagouv/mon-entreprise

This is incredible. I absolutely love the idea of official, government-supported machine readable versions of these kinds of rules.


thats pretty cool, I wonder though what the implication is if there is a bug or package hijacking? Are you expected to cross check the calculations and they are only offered as a convenience, and not authoritative?


The formulas are published in a programming language called M. There is an open source implementation [1].

> There is currently no legal guarantee of any kind about the correctness of the code produced by the Mlang compiler, or by the results produced by the interpreter of Mlang. However, authors have been in contact with DGFiP to validate Mlang, and the system passes all the private DGFiP tests as of Sept. 2022 for the version of the source files responsible for computing the tax on the 2018, 2019, 2020 and 2021 income.

[1] https://github.com/MLanguage/mlang


MLanguage in this context is not M, aka MUMPS.

MUMPS ("Massachusetts General Hospital Utility Multi-Programming System"), or M, is an imperative, high-level programming language with an integrated transaction processing key–value database. It was originally developed at Massachusetts General Hospital for managing hospital laboratory information systems.

https://en.wikipedia.org/wiki/MUMPS


Useful comment. Unfortunately M or MUMPS is still in active use at EPIC, etc. Far too many good grads of midwest schools get sucked into working for EPIC or the insurance mines in Des Moines, Omaha, etc. UW Madison, UIUC, and Michigan are way too good of schools to be sending their grads to work on medical records or insurance.


No it's not. M is a very old programming language created by "Bercy", for the "Impôt sur le Revenu".

Mon-entreprise is coded in publi.codes, a more recent language.

Mon-entreprise is focused on the social contributions (payroll), subject of OP.


Do you also worry that rogue employees or literally anybody with the keys to the office of a printer could have been changing the texts of laws as printed in official publications and books for the past few hundred years?

If not, why not?


Way? I thought the op was saying the French government published the code. Totally different if not.


Is this a toy? I get this warning on the English version of that website:

"Calculations are indicative. They are not a substitute for actual statements from Urssaf, the tax authorities or any other organization."

[1] https://mycompanyinfrance.urssaf.fr/developer/iframe?module=...


The code of this relatively recent project wasn't promoted (yet ?) as the internal official closed-source calculator.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: