Skip to content

Commit

Permalink
Add pandera as a core dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
Jianjie Liu committed Oct 8, 2021
1 parent 33c05cd commit 84d83e2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
11 changes: 4 additions & 7 deletions recommenders/datasets/movielens.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
import shutil
import warnings
import pandas as pd
import pandera as pa
from pandera import Field
from pandera.typing import Series
from typing import Optional
from zipfile import ZipFile
from recommenders.datasets.download_utils import maybe_download, download_path
Expand All @@ -21,6 +24,7 @@
DEFAULT_GENRE_COL,
)


try:
from pyspark.sql.types import (
StructType,
Expand All @@ -34,13 +38,6 @@
except ImportError:
pass # so the environment without spark doesn't break

try:
import pandera as pa
from pandera import Field
from pandera.typing import Series
except ImportError:
pass # so the environment without recommender['dev'] doesn't break


class _DataFormat:
def __init__(
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
"cornac>=1.1.2,<2",
"scikit-surprise>=0.19.1,<=1.1.1",
"retrying>=1.3.3",
"pandera[strategies]>=0.6.5", # For generating fake datasets
]

# shared dependencies
Expand Down Expand Up @@ -75,7 +76,6 @@
],
"dev": [
"black>=18.6b4,<21",
"pandera[strategies]>=0.6.5", # For generating fake datasets
"pytest>=3.6.4",
"pytest-cov>=2.12.1",
"pytest-mock>=3.6.1", # for access to mock fixtures in pytest
Expand Down

0 comments on commit 84d83e2

Please sign in to comment.