USEPA / standardizedinventories

Standardized Release and Waste Inventories
MIT License
25 stars 16 forks source link

Issue with SteWI 1.0.6 GHGRP download and running getInventory function. #137

Closed tjlca closed 1 year ago

tjlca commented 1 year ago

This is happening when 2011 inventories are being built.

GHGRP.main(Option = 'A', Year = [year])
  File "/Users/tghosh/Box Sync/FECM inventory/Industrial-Emissions-Inventory_2011/standardizedinventories-1.0.6/stewi/GHGRP.py", line 710, in main
    ghgrp4 = parse_subpart_L(year)
  File "/Users/tghosh/Box Sync/FECM inventory/Industrial-Emissions-Inventory_2011/standardizedinventories-1.0.6/stewi/GHGRP.py", line 514, in parse_subpart_L
    subpart_L_GWPs = load_subpart_l_gwp()
  File "/Users/tghosh/Box Sync/FECM inventory/Industrial-Emissions-Inventory_2011/standardizedinventories-1.0.6/stewi/GHGRP.py", line 637, in load_subpart_l_gwp
    download_table(filepath=filepath, url=subpart_L_GWPs_url)
  File "/Users/tghosh/Box Sync/FECM inventory/Industrial-Emissions-Inventory_2011/standardizedinventories-1.0.6/stewi/globals.py", line 117, in download_table
    with urllib.request.urlopen(url) as response, open(filepath, 'wb') as out_file:
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 222, in urlopen
    return opener.open(url, data, timeout)
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 525, in open
    response = self._open(req, data)
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 542, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 1397, in https_open
    return self.do_open(http.client.HTTPSConnection, req,
  File "/Users/tghosh/miniconda3/envs/stewi2011/lib/python3.8/urllib/request.py", line 1357, in do_open
    raise URLError(err)
urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self signed certificate in certificate chain (_ssl.c:1131)>
bl-young commented 1 year ago

I'm not able to replicate this. Our actions are able to generate GHGRP data from 2011 just fine (v1.0.6) (see https://github.com/USEPA/standardizedinventories/actions/runs/5249618932/jobs/9482616397).

I believe this certificate issue is on your end.