Breaking changes
- Update NumPy version's upper bound to 1.18
- NumPy 1.18 [expires a list of old deprecations](https://numpy.org/devdocs/release/1.18.0-notes.html#expired-deprecations) that might be used in openfisca country models.
Migration details
You might need to change your code if any of the [NumPy expired deprecations](https://numpy.org/devdocs/release/1.18.0-notes.html#expired-deprecations) is used in your model formulas.
Here is a subset of the deprecations that you might find in your model with some checks and migration steps (where `np` stands for `numpy`):
* `Removed deprecated support for boolean and empty condition lists in numpy.select.`
* Before `numpy.select([], [])` result was `0` (for a `default` argument value set to `0`).
* Now, we have to check for empty conditions and, return `0` or the defined default argument value when we want to keep the same behavior.
* Before, integer conditions where transformed to booleans.
* For example, `numpy.select([0, 1, 0], ['a', 'b', 'c'])` result was `array('b', dtype='<U21')`. Now, we have to update such code to: `numpy.select(numpy.array([0, 1, 0]).astype(bool), ['a', 'b', 'c'])`.
* `numpy.linspace parameter num must be an integer.`
* No surprise here, update the `num` parameter in [numpy.linspace](https://numpy.org/doc/1.18/reference/generated/numpy.linspace.html) in order to get an integer.
* `Array order only accepts ‘C’, ‘F’, ‘A’, and ‘K’.`
* Check that [numpy.array](https://numpy.org/doc/1.18/reference/generated/numpy.array.html) `order` argument gets one of the allowed values listed above.
* `UFuncs with multiple outputs must use a tuple for the out kwarg.`
* Update the output type of any used [universal function](https://numpy.org/doc/1.18/reference/ufuncs.html) to get a tuple.