Skip to content

Commit

Permalink
multiple countries bug fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
martinbenes1996 committed Aug 22, 2020
1 parent fc1ddf5 commit df37525
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions eurostat_deaths/deaths.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ def deaths(regions = None, sex = None, age = None, start = None):
f = None
for pre in regions:
matches = chunk['region'].str.startswith(pre)
f = f | matches if f else matches
f = f | matches if f is not None else matches
chunk = chunk[f]
# all chunk filtered out
if len(chunk.index) == 0:
Expand Down Expand Up @@ -123,5 +123,5 @@ def deaths(regions = None, sex = None, age = None, start = None):

if __name__ == "__main__":
logging.basicConfig(level = logging.INFO)
x = deaths(["CZ"], start = datetime(2019,1,1))
x = deaths(["CZ","PL"], start = datetime(2019,1,1))
print(x)
4 changes: 2 additions & 2 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

setuptools.setup(
name = 'eurostat_deaths',
version = '0.1.0',
version = '0.1.1',
author = 'Martin Beneš',
author_email = 'martinbenes1996@gmail.com',
description = 'Web Scraper for Eurostat data.',
Expand All @@ -21,7 +21,7 @@
packages=setuptools.find_packages(),
license='MIT',
url = 'https://github.com/martinbenes1996/eurostat_deaths',
download_url = 'https://github.com/martinbenes1996/eurostat_deaths/archive/0.1.0.tar.gz',
download_url = 'https://github.com/martinbenes1996/eurostat_deaths/archive/0.1.1.tar.gz',
keywords = ['eurostat', 'deaths', 'web', 'html', 'webscraping'],
install_requires = reqs,
package_dir={'': '.'},
Expand Down

0 comments on commit df37525

Please sign in to comment.