resources_by_asset_folder Not working
@someshfengde is already working on this.
Since Oct 1, 2024.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 25/100
Research direction
Start with the resources_by_asset_folder function and trace the request through execute_request.py, which is named in the traceback. Reproduce the call in the reported Python 3.10 and Django SDK 1.38.0 environment, then verify that it reaches the intended endpoint and returns a response that can be parsed successfully instead of a 404 HTML page.
Written by the indexing model from the issue text.
Description
Error parsing server response (404) when function is called
Behaviour - Functions are not working as expected
Error screenshots or Stack Trace
JSONDecodeError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/cloudinary/api_client/execute_request.py in execute_request(http_connector, method, params, headers, auth, api_url, **options)
74 try:
---> 75 result = json.loads(body.decode('utf-8'))
76 except Exception as e:
7 frames
JSONDecodeError: Expecting value: line 1 column 1 (char 0)
During handling of the above exception, another exception occurred:
GeneralError Traceback (most recent call last)
/usr/local/lib/python3.10/dist-packages/cloudinary/api_client/execute_request.py in execute_request(http_connector, method, params, headers, auth, api_url, **options)
76 except Exception as e:
77 # Error is parsing json
---> 78 raise GeneralError("Error parsing server response (%d) - %s. Got - %s" % (response.status, body, e))
79
80 if "error" in result:
GeneralError: Error parsing server response (404) - b'\n<html lang='en' xml:lang='en' xmlns='[https://www.w3.org/1999/xhtml](https://www.w3.org/1999/xhtml/)'>\n<meta charset='utf-8'>\n<meta content='width=device-width, initial-scale=1.0' name='viewport'>\n<title>Cloudinary - Page not found</title>\n<link href='//fonts.googleapis.com/css?family=Roboto:500,400italic,300,700,500italic,400&display=swap' rel='stylesheet'>\n<link href='//fonts.googleapis.com/css?family=Montserrat:300,500,700&display=swap' rel='stylesheet'>\n<link href='//fonts.googleapis.com/css?family=Roboto+Mono:300,400&display=swap' rel='stylesheet'>\n<link href='[https://plus.google.com/+Cloudinary](https://plus.google.com/+Cloudinary/)' rel='publisher'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_57/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_57/console/favicon.png/)' rel='apple-touch-icon' sizes='57x57'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_114/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_114/console/favicon.png/)' rel='apple-touch-icon' sizes='114x114'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_72/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_72/console/favicon.png/)' rel='apple-touch-icon' sizes='72x72'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_144/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_144/console/favicon.png/)' rel='apple-touch-icon' sizes='144x144'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_60/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_60/console/favicon.png/)' rel='apple-touch-icon' sizes='60x60'>\n<link href='[https://res.cloudinary.com/prod/image/upload/w_120/console/favicon.png](https://res.cloudinary.com/prod/image/upload/w_120/console/favicon.png/)' rel='apple-touch-icon' sizes='120x...
I am working on Colab
Environment and Frameworks (fill in the version numbers)
- Summary: Python and Django SDK for Cloudinary - 1.38.0
- Python Version - 3.10
- Dominant language
- Python
- Stars
- 262
- Forks
- 133
- Avg merge
- 3m
- Merged PRs (30d)
- 1
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from cloudinary/pycloudinary
-
Difficulty 4/5 3-5 days Newbie friendliness 30/100
cloudinary/pycloudinary#385 · 2 comments ·
-
cloudinary.api.resources_by_asset_folder ErrorMay be free again @atdcloud claimed this 1266 days ago, and no pull request is open. Openquestion
cloudinary/pycloudinary#349 · 1 reaction · 1 assignee ·
-
Feature: Bad Format exceptionMay be free again @const-cloudinary claimed this 2139 days ago, and no pull request is open. Open
cloudinary/pycloudinary#266 · 2 comments · 1 assignee ·
-
CloudinaryFileField doesn't show checkbox for clear the fieldMay be free again @YomesInc claimed this 2229 days ago, and no pull request is open. Open
cloudinary/pycloudinary#258 · 2 comments · 1 assignee ·
-
How to use CloudinaryField to accept images/url from other sources?May be free again @lukitsbrian claimed this 2453 days ago, and no pull request is open. Openquestion
cloudinary/pycloudinary#233 · 2 comments · 1 assignee ·
All issues in cloudinary/pycloudinary
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 70/100
peach-mitao/peach#693 ·
Maintainers usually reply within 1 day
-
FTP reads inside a transaction use a nonexistent staging pathPossibly taken @Harsh23Kashyap claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
fsspec/filesystem_spec#2463 ·
Maintainers usually reply within 1 day
-
comp/cli P2 tool/code-exec type/bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
NousResearch/hermes-agent#155989 ·
Maintainers usually reply within 1 day
-
PipesFileMessageReader parses a partially written message line: tail_file yields a line before its newline arrivesPossibly taken @PCTEJA claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
dagster-io/dagster#34442 ·
Maintainers usually reply within 1 day