Skip to content

Commit

Permalink
Check if pandas is recent enough
Browse files Browse the repository at this point in the history
  • Loading branch information
ekluzek committed Nov 19, 2022
1 parent 2e122e0 commit 6b017ae
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions tools/site_and_regional/modify_singlept_site_neon.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@
import numpy as np
import pandas as pd
import xarray as xr
from packaging import version

from datetime import date
from getpass import getuser
Expand Down Expand Up @@ -518,6 +519,12 @@ def main():
if args.debug:
logging.basicConfig(level=logging.DEBUG)

# Check if pandas is a recent enough version
pdvers = pd.__version__
if version.parse(pdvers) < version.parse("1.1.0"):
sys.exit("The pandas version in your python environment is too old, update to a newer version of pandas (>=1.1.0): version=%s", pdvers )


file_time = check_neon_time()

# -- specify site from which to extract data
Expand Down

0 comments on commit 6b017ae

Please sign in to comment.