Skip to content

Commit

Permalink
upgrade setuptools
Browse files Browse the repository at this point in the history
  • Loading branch information
aliavni committed May 28, 2024
1 parent 83c496a commit 8e5bba1
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
9 changes: 6 additions & 3 deletions airflow/dags/airbnb_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@
import argparse


parser = argparse.ArgumentParser()
parser.add_argument("--url", dest="url", type=str, help="Inside Airbnb data url")
args = parser.parse_args()
def get_args():
parser = argparse.ArgumentParser()
parser.add_argument("--url", dest="url", type=str, help="Inside Airbnb data url")
return parser.parse_args()


spark = SparkSession.builder.appName("airbnb").getOrCreate()
sc = spark.sparkContext

args = get_args()
df = spark.createDataFrame(pd.read_csv(args.url))

print(f"# of rows: {df.count()}")
Expand Down
2 changes: 1 addition & 1 deletion docker/airflow/requirements_spark.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# requirements should be the same as `docker/spark/requirements.txt`
pandas==2.2.2
setuptools==65.5.0
setuptools==70.0.0
2 changes: 1 addition & 1 deletion docker/spark/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# requirements should be the same as `docker/airflow/requirements_spark.txt`
pandas==2.2.2
setuptools==65.5.0
setuptools==70.0.0

0 comments on commit 8e5bba1

Please sign in to comment.