We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
7aa44a7 introduced json.decoder.JSONDecodeError which does not exist in Python 2.7. The following patch should fix that:
json.decoder.JSONDecodeError
From d6ed0f0a2ee3492dafad7790ccc161e4dc54deec Mon Sep 17 00:00:00 2001 From: Pavol Juhas <pavol.juhas@gmail.com> Date: Wed, 12 Dec 2018 11:41:57 -0500 Subject: [PATCH] Avoid use of undefined JSONDecodeError Python 2.7 does not have `json.decoder.JSONDecodeError`. Solution: replace with mock JSONDecodeError. --- conda_build/index.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/conda_build/index.py b/conda_build/index.py index 9f1ccc8c..363302bb 100644 --- a/conda_build/index.py +++ b/conda_build/index.py @@ -169,7 +169,7 @@ def _download_channeldata(channel_url): try: with open(tf) as f: data = json.load(f) - except json.decoder.JSONDecodeError: + except JSONDecodeError: data = {} return data @@ -270,7 +270,7 @@ def get_build_index(subdir, bldpkgs_dir, output_folder=None, clear_cache=False, with open(channeldata_file, "r+") as f: channel_data[channel.name] = json.load(f) break - except (IOError, json.decoder.JSONDecodeError): + except (IOError, JSONDecodeError): time.sleep(0.2) retry += 1 else: -- 2.19.2
The text was updated successfully, but these errors were encountered:
duplicate of #3307, closing
Sorry, something went wrong.
Hi there, thank you for your contribution!
This issue has been automatically locked because it has not had recent activity after being closed.
Please open a new issue if needed.
Thanks!
No branches or pull requests
7aa44a7 introduced
json.decoder.JSONDecodeError
which does not exist in Python 2.7.The following patch should fix that:
The text was updated successfully, but these errors were encountered: