AMF-FLX / AMF-BASE-QAQC

AmeriFlux BASE Flux/Met Data QA/QC and Processing
Other
5 stars 7 forks source link

PosixPath breaking joiner in Data QAQC #71

Closed dschristianson closed 1 year ago

dschristianson commented 1 year ago

PosixPath is breaking the

Stacktrace:

2023-09-08 06:44:35,392 [INFO] BASE Generation - Traceback (most recent call last):
  File "main.py", line 114, in main
    process_id, args.site_id, args.resolution)
  File "path/AMF-BASE-QAQC/processing/join_site_data.py", line 435, in driver
    return self.join_site_files(proc_id, site_id, resolution, is_test)
  File "path/AMF-BASE-QAQC/processing/join_site_data.py", line 307, in join_site_files
    proc_id, file_path, file_order)
  File "path/AMF-BASE-QAQC/processing/report_status.py", line 128, in register_base_files
    return self._basic_post_request(req_data, url).strip('"')
  File "path/AMF-BASE-QAQC/processing/report_status.py", line 72, in _basic_post_request
    response = self._basic_post_request_core(msg, url)
  File "path/AMF-BASE-QAQC/processing/report_status.py", line 63, in _basic_post_request_core
    json_data = json.dumps(msg)
  File "/usr/lib/python3.7/json/__init__.py", line 231, in dumps
    return _default_encoder.encode(obj)
  File "/usr/lib/python3.7/json/encoder.py", line 199, in encode
    chunks = self.iterencode(o, _one_shot=True)
  File "/usr/lib/python3.7/json/encoder.py", line 257, in iterencode
    return _iterencode(o, 0)
  File "/usr/lib/python3.7/json/encoder.py", line 179, in default
    raise TypeError(f'Object of type {o.__class__.__name__} '
TypeError: Object of type PosixPath is not JSON serializable