Repository: oscovida/oscovida (language: python)

Issue:
update .pad to .ffill for pandas (resolves oscovida/oscovida#286)
Replaced the deprecated .pad() with the recommended .fillna(method="ffill"). Tested.


Discussion / hints:
# [Codecov](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida) Report
> Merging [#287](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida) (541110b) into [master](https://codecov.io/gh/oscovida/oscovida/commit/9d1d33a8b251af15fcbd86765ee272f1815d7e53?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida) (9d1d33a) will **increase** coverage by `0.23%`.
> The diff coverage is `100.00%`.

[![Impacted file tree graph](https://codecov.io/gh/oscovida/oscovida/pull/287/graphs/tree.svg?width=650&height=150&src=pr&token=UY1ULLTQF1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida)](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida)

```diff
@@            Coverage Diff             @@
##           master     #287      +/-   ##
==========================================
+ Coverage   87.82%   88.06%   +0.23%     
==========================================
  Files           5        5              
  Lines        1035     1022      -13     
==========================================
- Hits          909      900       -9     
+ Misses        126      122       -4     
```


| [Impacted Files](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida) | Coverage Δ | |
|---|---|---|
| [oscovida/oscovida.py](https://codecov.io/gh/oscovida/oscovida/pull/287/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida#diff-b3Njb3ZpZGEvb3Njb3ZpZGEucHk=) | `86.61% <100.00%> (+0.31%)` | :arrow_up: |
| [oscovida/metadata.py](https://codecov.io/gh/oscovida/oscovida/pull/287/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida#diff-b3Njb3ZpZGEvbWV0YWRhdGEucHk=) | `95.77% <0.00%> (-0.18%)` | :arrow_down: |
| [oscovida/plotting\_helpers.py](https://codecov.io/gh/oscovida/oscovida/pull/287/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida#diff-b3Njb3ZpZGEvcGxvdHRpbmdfaGVscGVycy5weQ==) | `100.00% <0.00%> (ø)` | |

------

[Continue to review full report at Codecov](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida).
> **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida)
> `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
> Powered by [Codecov](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=footer&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida). Last update [9d1d33a...541110b](https://codecov.io/gh/oscovida/oscovida/pull/287?src=pr&el=lastupdated&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=oscovida).

Okay, it looks like it works. At least all tests pass locally. Dunno why they are failing on the CI :man_shrugging: 
Let's try to merge it...

Many thanks for your contribution!

Fix patch:
diff --git a/setup.py b/setup.py
index 0bc7e1eb..4b30f864 100644
--- a/setup.py
+++ b/setup.py
@@ -34,7 +34,7 @@ def find_version(*parts):
       packages=find_packages(),
       install_requires=[
           'joblib',
-          'pandas==1.3.1',
+          'pandas',
           'seaborn',
           'matplotlib',
           'markdown',
diff --git a/tools/pelican/content/ipynb/14-day-incidence-germany.ipynb b/tools/pelican/content/ipynb/14-day-incidence-germany.ipynb
index 7967fab7..9153ffa7 100644
--- a/tools/pelican/content/ipynb/14-day-incidence-germany.ipynb
+++ b/tools/pelican/content/ipynb/14-day-incidence-germany.ipynb
@@ -27,9 +27,8 @@
    "metadata": {},
    "outputs": [],
    "source": [
-    "import datetime as dt\n",
     "import pandas as pd\n",
-    "pd.set_option(\"max_rows\", None)\n",
+    "pd.set_option(\"display.max_rows\", None)\n",
     "from oscovida import get_incidence_rates_germany"
    ]
   },
diff --git a/tools/pelican/content/ipynb/14-day-incidence.ipynb b/tools/pelican/content/ipynb/14-day-incidence.ipynb
index 268f338d..7efe3770 100644
--- a/tools/pelican/content/ipynb/14-day-incidence.ipynb
+++ b/tools/pelican/content/ipynb/14-day-incidence.ipynb
@@ -29,9 +29,8 @@
    },
    "outputs": [],
    "source": [
-    "import datetime as dt\n",
     "import pandas as pd\n",
-    "pd.set_option(\"max_rows\", None)\n",
+    "pd.set_option(\"display.max_rows\", None)\n",
     "from oscovida import get_incidence_rates_countries"
    ]
   },


Test patch:
diff --git a/tests/test_corona.py b/tests/test_corona.py
index 3008b17b..c10f2aa1 100644
--- a/tests/test_corona.py
+++ b/tests/test_corona.py
@@ -428,7 +428,6 @@ def test_population():
                  ]
     for country, reg, subreg, ref_pop in reference:
         actual_population = c.population(country, reg, subreg)
-        print(country)
         assert isinstance(actual_population, int)
         assert 0.8 * ref_pop < actual_population < 1.2 * ref_pop
 
diff --git a/tools/test-plots-for-all-regions.ipynb b/tools/test-plots-for-all-regions.ipynb
index 45374889..196c0eaa 100644
--- a/tools/test-plots-for-all-regions.ipynb
+++ b/tools/test-plots-for-all-regions.ipynb
@@ -94,4 +94,4 @@
  },
  "nbformat": 4,
  "nbformat_minor": 4
-}
+}
\ No newline at end of file