aschleg / nasapy Goto Github PK
View Code? Open in Web Editor NEWPython wrapper for the NASA API https://api.nasa.gov
License: MIT License
Python wrapper for the NASA API https://api.nasa.gov
License: MIT License
I'm not sure if this wrapper is still maintained, but it is handy and I use it in an insignificant personal project for practicing my python and frontend design. As of today, all *.picture_of_the_day()
calls are failing with a general 500 Timeout. I was able to use EPIC functionality fine in a REPL session and can reproduce the error from both my application and through the interpreter session.
Traceback (most recent call last): File ".venv/lib/python3.12/site-packages/flask/app.py", line 1473, in wsgi_app response = self.full_dispatch_request() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File ".venv/lib/python3.12/site-packages/flask/app.py", line 882, in full_dispatch_request rv = self.handle_user_exception(e) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File ".venv/lib/python3.12/site-packages/flask/app.py", line 880, in full_dispatch_request rv = self.dispatch_request() ^^^^^^^^^^^^^^^^^^^^^^^
File "venv/lib/python3.12/site-packages/flask/app.py", line 865, in dispatch_request return self.ensure_sync(self.view_functions[rule.endpoint])(**view_args) # type: ignore[no-any-return] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "app.py", line 37, in apod return render_template("apod.html", apod=get_APOD()) ^^^^^^^^^^
File "app.py", line 22, in get_APOD return nasa.picture_of_the_day(date=d, hd=True) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File ".venv/lib/python3.12/site-packages/nasapy/api.py", line 184, in picture_of_the_day raise requests.exceptions.HTTPError(r.reason) requests.exceptions.HTTPError: Gateway Timeout
Removed sensitive paths and names, but left in my code calling the function I use, etc. I have an API key and have used nasapy with my app for months now, have not seen this occur before. It could be an ongoing issue with the actual endpoint at NASA, but it has persisted for almost a day now.
Python 3.12
WSL2 Ubuntu Preview (Win 11 Pro)
EDIT:
Apparently it was an issue on NASA's end(point). Was down for about a full day.
The epic
function is just returning an empty list, even with no parameters. (Sorry, I messed up the title markdown. It's supposed to be epic
, not <epic>
)
I am not a great fan of jupyter notebooks (they're like being forced to watch a movie on TV with advertisements) and would rather just run it as a cron job every few days or whatever. Is there a version of it available that would be suitable? Or something available elsewhere in the community?
Hi. In the version of nasapy that installs using pip3 install (0.2.6), the api.py has an error in it when calling the url variable for .techport().
The URL variable that is called is defined as " url = self.host + '/techport/api/projects/' ", but it shouldn't have the "/" at the end. I went in and edited the file to " url = self.host + '/techport/api/projects' " and it worked fine after.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.