Comments (4)
I'll be more specific as I've found where the issue is.
When some sort of error occurs and an ApiError
is thrown the following exception is thrown:
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/convertapi/exceptions.py", line 14, in __str__
message = "%s Code: %s. %s" % (self.message, self.code, self.invalid_parameters)
AttributeError: 'ApiError' object has no attribute 'message'
The issue is that self.message
is never defined in ApiError, therefore __str__
fails. Adding self
to where message is defined in __init__
will fix the issue.
from convertapi-python.
My idea is that the problem appears when response does not has an actual response model and API error json model binding fails. It could happen when server return 500 for some unknown reason.
from convertapi-python.
In my case I realised this issue when we sent a faulty file path. Only after making the change above I could see the actual error that was returned which was code 5007 - Unable to download remote file'.
So that's not a random 500 error.
from convertapi-python.
Thanks @mayaizart for the fix PR. Merged and released 1.1.1 version.
from convertapi-python.
Related Issues (20)
- Increase default TimeOut to 1000 HOT 1
- "Unable to access the file." or "Unable to download the file" errors in Django HOT 2
- Unable to parse pdf to csv using convertapi HOT 1
- Files array syntax error in Python snippet HOT 2
- Multiprocessing module not allowing children processes HOT 1
- I am facing 500:Internal Server Error for URL in version 1.4.0 HOT 4
- JSONDecodeError when getting/polling a 202/Conversion in progress response HOT 3
- Incorrect Links in the readme and documentation HOT 1
- Emoji is converted into bullets after converting into PDF HOT 1
- HTTPSConnectionPool error HOT 2
- File conversion
- Do not pass any TimeOut property to ConvertAPI and set HTTP Client timeout to 1800 seconds HOT 2
- convert parameters override
- Deactivate SSL Certrificate verification? HOT 1
- Alternative converter parameter is case-sensitive HOT 1
- Set conversion location option HOT 1
- ConvertApiUser.SecondsLeft property is depreciated
- Convert PDF to DOCX: List with bulletpoints has different spaces HOT 1
- Token authentication method HOT 2
- Conversions takes significantly more time compared to converting in browser HOT 17
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from convertapi-python.