Comments (5)
Original comment by Marcus von Appen (Bitbucket: marcusva, GitHub: marcusva):
- Fixed #48: Be noisy on DLL load failures to avoid users fiddling around with
the warnings parameters.
from py-sdl2.
Original comment by Mike C (Bitbucket: mikechag, GitHub: Unknown):
I was using 0.8.0 at the time. I just upgraded to 0.9.0 and still just go the error (once I uninstalled SDL_ttf)
I thought it might be the IDE (PyCharm) hiding the warnings, but I ran it in a termal and still only got the error message and no warnings
from py-sdl2.
Original comment by Marcus von Appen (Bitbucket: marcusva, GitHub: marcusva):
Usually the warning should be printed through the warnings.warn() function call in line 61. Which version of PySDL do you use?
from py-sdl2.
Original comment by Mike C (Bitbucket: mikechag, GitHub: Unknown):
Both are 64bit.
I was able to determine the issue, and that wasn't it. Both libSDL2 and libSDL2_ttf were installed to /usr/local/lib, which is the default for the configure scripts when built from source. I guess this allowed the dll loader (dll.py) to know that I had it installed, but not where it was installed to.
There were warnings that I was not aware of (I guess maybe there's a switch I need to set to show them?), so I changed the code in DLL.py to print the warning instead, and it gave me:
OSError('libSDL2_ttf-2.0.so.0: cannot open shared object file: No such file or directory',)
That was enough for me to figure out the issue.
So the original issue is all set, and I can chalk that up to me installing from source and/or not having paths correct.
I understand making the library checks warnings, as it could have failures that would get annoying if they show up every time, but maybe after the warning checks, and if it throws a full on error, it shows you all of the warnings in addition to the RuntimeError that's thrown? The exception that's raised, "found %s, but it's not usable for the libary %s", doesn't do much to help troubleshoot the issue in and of itself.
I'm referencing dll.py, lines 50-65
(there's also a typo in the exception; should be library and not libary, but I think that's already been posted as a separate issue)
from py-sdl2.
Original comment by Marcus von Appen (Bitbucket: marcusva, GitHub: marcusva):
This can happen, if one runs a 32-bit python and uses 64-bit SDL2 libraries (or the other way around). Did you ensure that both, Python and your SDL2 libraries use the same bit count?
from py-sdl2.
Related Issues (20)
- pysdl2 gfx not working in termux HOT 4
- Problem with SDL_GL_GetProcAddress() HOT 5
- Render._get_render_drivers() not working correctly
- Units test fail on big-endian architecture HOT 13
- Unit test expects SDL version to stay 2.0.x forever HOT 4
- Handling Resize of Images / Resize of Window with SpriteFactory/Renderer HOT 3
- SDL_TICKS_PASSED doesn't handle wraparound HOT 1
- Unable to set framerate with using the FPSManager HOT 2
- ValueError: NULL pointer access while running the test suite HOT 16
- test_Mix_MusicDuration failure: assert 0.2 < 0.1501... HOT 1
- Unit tests fail with SDL git main (2.25.x)
- How to convert SDL_Surface to pygame.Surface? HOT 3
- Accessing the original ctypes function pointers broke again HOT 2
- Incorrect use of SDL_GetError() to check whether calls failed HOT 6
- TTF_WRAPPED_ALIGN_* is not defined bug HOT 1
- How to delete UserWarning: Using SDL2 binaries from pysdl2-dll 2.28.0 HOT 6
- Window icon and title are not set properly HOT 5
- SDL_gfx: Circle radius greater than 1023 results in deformation HOT 1
- Events (keyboard kew presses) missing when running app in Debian minimum (console only, no X window manager) HOT 6
- SDL_CreateRGBSurfaceWithFormatFrom silently failing when passed a sub-array of a `bytes` object HOT 1
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 py-sdl2.