Pygame

Latest version: v2.5.2

Safety actively analyzes 631110 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 10 of 10

1.9.1

1.9.0

1.8.1

Not secure

1.8.0

Not secure
The count can be found with the following command run in the pygame code base:

grep todo test/*.py | wc -l


'[goodfirstissue](https://github.com/pygame/pygame/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22)' is a label applied to issues which would be good for someone who wants to try contributing to a Free, Open Source, or community project (like pygame). A lot of these issues were written up containing unit tests that needed to be finished off.

Unfortunately we will probably run out of things to test in some months. We hope to prepare new types of 'good first issues', and educational material in other areas next. So that there is something else for people who are interested in contributing as a way to learn. Hopefully we can structure it as a learning pathway, with even some advanced topics.



Thanks to Andy Nguyen anguye13, who worked on a number of tests in the display, image, and surface areas.
- [Unit test for image.save_extended()](https://github.com/pygame/pygame/pull/2040)
- [display.set_gamma_ramp() unit test](https://github.com/pygame/pygame/pull/2039)
- [Added unit test: surface.get_shifts()](https://github.com/pygame/pygame/pull/2034)
- [Added unit test: surface.get_pitch()](https://github.com/pygame/pygame/pull/2037)

Adam Andrews adamandrews1 worked on the transform, threads parts of the code base. They have also begun work on cleaning up the buffer code, which is in C and kind of complicated. But that work is still waiting, and will likely make it into the next release.
- [threads.benchmark_workers and threads.WorkerQueue.do](https://github.com/pygame/pygame/pull/2064)
- [pygame.transform.smoothscale](https://github.com/pygame/pygame/pull/2063)
- [Reintroduce sizing checks for transform.smoothscale test](https://github.com/pygame/pygame/pull/2074)

Travis Chang Reminisque
- [Added unit test for mouse.get_cursor()](https://github.com/pygame/pygame/pull/1955)
- [Add unit test for surface.get_losses](https://github.com/pygame/pygame/pull/2020)
- [Add mouse.set_cursor unit test](https://github.com/pygame/pygame/pull/1967)

Dan Lawrence MyreMylar
- [Some colorkey test fixes](https://github.com/pygame/pygame/pull/1913)
- [Testing mixer.music.play() start parameter & adding mp3 warning](https://github.com/pygame/pygame/pull/1886)

khuang0312
- [Added time.get_ticks() and time test improvements](https://github.com/pygame/pygame/pull/1880)
- [surface.get_colorkey() test](https://github.com/pygame/pygame/pull/1881)

lkito
- [Surface.get_bitsize and Surface.get_bytesize tests](https://github.com/pygame/pygame/pull/1898)
- [Surface.test_get_abs_parent and Surface.test_get_abs_offset tests, and fix.](https://github.com/pygame/pygame/pull/1900)

Pedro de la Peña pedrodelapena
- [Unit tests for time.Clock.get_time()](https://github.com/pygame/pygame/pull/1909)
- [Unit tests for transform.rotate()](https://github.com/pygame/pygame/pull/1960)

galexandreg continued to
- [Add time.set_timer() unittest](https://github.com/pygame/pygame/pull/1924)
- [Add some mixer Sound tests](https://github.com/pygame/pygame/pull/1934)

tsadama
- [Added unit tests for display.toggle_fullscreen and display.get_active](https://github.com/pygame/pygame/pull/1927)
- [Added Unit Test for joystick.init()](https://github.com/pygame/pygame/pull/1937)

pygame.joystick tests

raphacosta27 [Add unit test: joystick.quit()](https://github.com/pygame/pygame/pull/1912)
Bill AdditionalPylons [Added unit test: JoystickModuleTest.test_get_count](https://github.com/pygame/pygame/pull/2009)

pygame.display tests

Gabriel Moreira gabsmoreira [Add unit test: display.get_driver](https://github.com/pygame/pygame/pull/1911)
zoldalma999 [Adding unit test to display.iconify](https://github.com/pygame/pygame/pull/2006)
amipy [Added a unit test for display.flip()](https://github.com/pygame/pygame/pull/2054)
DGMcKenney [Adds a unit test of the display.set_icon() function.](https://github.com/pygame/pygame/pull/2042)
Grigoris Tsopouridis gtsopus [Add display.set_gamma unit test](https://github.com/pygame/pygame/pull/1942)

pygame.time tests

Ilia Gogotchuri Gogotchuri [Implemented time.Clock.get_fps unit test](https://github.com/pygame/pygame/pull/1926)
Jim Quach jiquach [Add unit test to Clock.get_rawtime](https://github.com/pygame/pygame/pull/1939)
Aaron Li AaronLi [Added test for time.Clock.tick()](https://github.com/pygame/pygame/pull/1938)
Clark Seanor cruxicheiros [Add basic tests for time.Clock.tick_busy_loop](https://github.com/pygame/pygame/pull/1976)

pygame.threads tests

K Duggan kduggan15 [Adds test for threadloop](https://github.com/pygame/pygame/pull/1961)
Michał Górny mgorny [Replace long-deprecated Thread.isAlive() with .is_alive()](https://github.com/pygame/pygame/pull/1928)
Clark Seanor cruxicheiros [threads.tmap() test and and fix. Unsurfaced bug 1768](https://github.com/pygame/pygame/pull/1965)

pygame.Surface tests

jtoloff [unit test for Surface.get_locks function](https://github.com/pygame/pygame/pull/1980)
41aaronb [Added unit test for the surface.lock() function](https://github.com/pygame/pygame/pull/1977)

other tests

Prasanna Venkatesh hanzohasashi33 [math.Vector.scale_to_length docs and add test for display.set_palette()](https://github.com/pygame/pygame/pull/1972)
zoldalma999 [Add unit test to image.get_extended](https://github.com/pygame/pygame/pull/2002)
Nihal Mittal codescientist703 [Added unit test for pygame.cursors.compile](https://github.com/pygame/pygame/pull/2012)
leopoldwe [Add key.get focused unit test](https://github.com/pygame/pygame/pull/2026)



draw

Josip Komljenović MightyJosip [Fixed drawing of ellipse. No more holes.](https://github.com/pygame/pygame/pull/1994)

Old:
![Old](https://user-images.githubusercontent.com/29337110/86373093-4e61ee80-bc83-11ea-839a-febb416075d1.png)
New:
![New](https://user-images.githubusercontent.com/29337110/86373038-3db17880-bc83-11ea-9b44-903e40eb658b.png)

Scott Noyes snoyes [draw_py._draw_line: Use correct endpoints during swap](https://github.com/pygame/pygame/pull/1964)

Charles charlesej [Fix aatrigon/aapolygon drawing horizontal edges](https://github.com/pygame/pygame/pull/2015)



Math

Daniel Pope lordmauve [Fix OOB access in math.Vector swizzle; add '0' and '1' swizzles](https://github.com/pygame/pygame/pull/2024)

These will be useful to prepare [homogenous coordinates for affine transforms by matrix multiplication](https://en.wikipedia.org/wiki/Transformation_matrix#Affine_transformations). Here is a matrix representing a 2x scale + (3, -1) translation:

python
>>> import numpy as np
>>> from pygame.math import Vector2

0.8

>>> mat = np.array([
... [2, 0, 3],
... [0, 2, -1],
... ])
>>> mat v.xy1

0.6

Community help

A special thanks to all the people who help out others. From making videos, to answering questions, to writing guides. MyreMylar, MichaelCPalmer, jtiai, claudeb, DaFluffyPotato, Rabbid76, The Big Kahuna, sloth, Kingsley, ... and lots of other people.

Special thanks to Zireael07 for cheering on pull requests that people make 🎉


Type hints, and lint tools

We are down to zero alerts on the LGTM linting tool on python and C/C++. We are now the largest python codebase with zero alerts on the LGTM platform (and also the largest C/C++ codebase with zero alerts). This doesn't mean we have perfect code yet however!

pylint

pylint is another python code quality tool we are using. With which we currently have **thousands** of reported issues left. Not only can this tool find correctness problems with the code, it can also offer ideas on how to make the code more readable and 'pythonic'. Once we have the files pylint-clean we can use pylint to take some of the load off the code reviewers.


Dan Lawrence MyreMylar pylint
- [version module](https://github.com/pygame/pygame/pull/1891)
- [sysfont module](https://github.com/pygame/pygame/pull/1892)
- [pkgdata module](https://github.com/pygame/pygame/pull/1893)
- [py_draw.py module](https://github.com/pygame/pygame/pull/1936)
- [midi module](https://github.com/pygame/pygame/pull/1946)
- [locals.py module](https://github.com/pygame/pygame/pull/1921)
- [A start on linting the sprite module](https://github.com/pygame/pygame/pull/1925)


Charles charlesej
- [colordict.py](https://github.com/pygame/pygame/pull/2003)
- [_numpysurfarray.py](https://github.com/pygame/pygame/pull/2004)

Josip Komljenović MightyJosip
- [Rect and Color type hint fixes](https://github.com/pygame/pygame/pull/2079/files)


Android

Some more of the android branch got merged into the main pygame branch.

robertpfeiffer
- [use rwops for font loading](https://github.com/pygame/pygame/pull/2065)
- [Keep all window events in SDL2](https://github.com/pygame/pygame/pull/1897)
- [setup.py cleanup: add -stripped build option to not include docs or tests ](https://github.com/pygame/pygame/pull/1878)


big endian CPU architecture

Thanks to Travis CI, we now have a builder which can test our big endian code. Even though big endian is not very common these days, it's still helpful to support it because it helps shake out some bugs we wouldn't normally see just testing on little endian CPU architectures.

René Dudfield illume [s390x build robot on travis CI for big endian testing](https://github.com/pygame/pygame/pull/1929)
Michał Górny mgorny [Account for big endian support for RGB/BGR images](https://github.com/pygame/pygame/pull/1930)
Dan Lawrence MyreMylar [Remove hard coded RGB bitshifts that don't work with SDL_MapRGB()/SDL_MapRGBA()](https://github.com/pygame/pygame/pull/1919)


image

Sigurður Sveinn Halldórsson siggisv [image.save(namehint='') and image.get_sdl_image_version](https://github.com/pygame/pygame/pull/2053) useful for when saving images to file objects and you want to tell it what format to save in (jpg, png, etc).

python
>>> file = BytesIO()
>>> pygame.image.save(surface, file, namehint='.png')


Documentation and tutorials

css
_________________________
=(__ ___ __ __)=
| |
| |
| python -m pygame.docs |
| |
| A number of small |
| documentation fixes |
| were made in this |
| release. |
| |
|__ ___ __ _____|
=(_________________________)=



Starbuck5 [Fix typo in draw.rst](https://github.com/pygame/pygame/pull/1885)

Dan Lawrence MyreMylar
- [Strengthen warning in event docs about handling the event queue](https://github.com/pygame/pygame/pull/1883)
- [Key constants link added to event documentation](https://github.com/pygame/pygame/pull/2072)

wuzh07 [Fix typos in draw.rect docs](https://github.com/pygame/pygame/pull/1969)
Gerardo Antonio Hagad ginohagad [Chimp tutorial: Changed the variable "wav" to "fullname".](https://github.com/pygame/pygame/pull/2005)

Evan Kanter evank28 [Updated documentation of blit method](https://github.com/pygame/pygame/pull/2035)
Vicente González Ruiz vicente-gonzalez-ruiz [Update SpriteIntro.rst](https://github.com/pygame/pygame/pull/2045)

Douglas douglas-cpp [Fix grammar in sprite docs](https://github.com/pygame/pygame/pull/2062)

mouse

Dan Lawrence MyreMylar [mouse.get_pressed() supports 5 buttons](https://github.com/pygame/pygame/pull/1887)


Optimizations

nthykier [Add a SSE4.2 optimized version of image_tostring for some 32bit surfaces](https://github.com/pygame/pygame/pull/1715). The new pygame.image.tostring is up to 8x faster on x86 and x64 systems.


Bug fixes and Cleanups

René Dudfield illume
- [Manylinux builds tested properly on travis CI](https://github.com/pygame/pygame/pull/1906)
- [Remove unused gp2x files.](https://github.com/pygame/pygame/pull/1917)
- [freetype.py unused imports, and black code formatting](https://github.com/pygame/pygame/pull/1918)
- [Move .appveyor.yml config to buildconfig/appveyor.yml One less file in root.](https://github.com/pygame/pygame/pull/1935)
- [setup.cfg for tooling config. Starting with tox and pylint config.](https://github.com/pygame/pygame/pull/1944)
- [Name some travis ci jobs (SDL1, manylinux)](https://github.com/pygame/pygame/pull/1978) including
- [Atlassian Bitbucket deleted repos. Host windows prebuilts file on pygame website](https://github.com/pygame/pygame/pull/2059)
- [Disable mouse.set_system_cursor on CI](https://github.com/pygame/pygame/pull/2060)
- [Fix mouse.set_system_cursor when using SDL1 to do nothing.](https://github.com/pygame/pygame/pull/2061)


Inada Naoki methane [Avoid PEP393 deprecated APIs.](https://github.com/pygame/pygame/pull/1956)
Niels Thykier nthykier [Fix test failure without SDL_AUDIODRIVER set](https://github.com/pygame/pygame/pull/1987)

Jani Tiainen jtiai [Pipenv: Fixed incorrect base class comparison](https://github.com/pygame/pygame/pull/2001)

Christian Clauss cclauss [Travis CI: Test Py38 on Ubuntu Bionic](https://github.com/pygame/pygame/pull/1727)

Dan Lawrence MyreMylar
- [Alphabetised colourdict.py colour names](https://github.com/pygame/pygame/pull/2068)
- [Defined WINDOWEVENT_MINIMIZED](https://github.com/pygame/pygame/pull/2090)

Sigurður Sveinn Halldórsson siggisv [Fix pygame.event.custom_type() off by one error.](https://github.com/pygame/pygame/pull/2076)

Josip Komljenović MightyJosip
- [Fix event.custom_event first call](https://github.com/pygame/pygame/pull/2071)
- [Add PyCharm config directory to gitignore](https://github.com/pygame/pygame/pull/1941)
- [transform.chop test and fix](https://github.com/pygame/pygame/pull/1996)

Starbuck5 [Internal pyinstaller hook to include dynamic libraries on Windows](https://github.com/pygame/pygame/pull/2058)

Gosha Zacharov Gosha [Allow setting several paths in PYGAME_EXTRA_BASE](https://github.com/pygame/pygame/pull/1989)



sprite

Sigurður Sveinn Halldórsson siggisv [Fix and test sprite.collide_circle_ratio](https://github.com/pygame/pygame/pull/2030)
Josip Komljenović MightyJosip [Fix sprite drawing on Renderer](https://github.com/pygame/pygame/pull/2080)

Reviews

Special thanks to MyreMylar, MightyJosip, charlesej, robertpfeiffer, illume and nthykier who have provided plenty of code reviews and testing of other peoples work.

It's vitally important that people volunteering (sometimes for the first time) are treated with respect and in a friendly way. It's also important that everyone in our community should feel free to review code, so we can all learn from one another.


Issue gardening


css
********
****************
*******************
********************
******************** wWWWw wWWWw
\\ // ******** vVVVv (___) wWWWw (___) vVVVv
\\\// ******* (___) ~Y~ (___) vVVVv ~Y~ (___)
\\\//// ~Y~ \| ~Y~ (___) |/ ~Y~
|||// \| \ |/ \| / \~Y~/ \| \ |/
||||| \\|// \\|// \\|/// \\|// \\|// \\\|///
,,,,,,,,,,,//||||\,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;



This time 4 'critical' backwards compatibility issues were fixed since the last release.

---

- [9 open 'critical' issues](https://github.com/pygame/pygame/issues?q=is%3Aissue+is%3Aopen+label%3Acritical) (backwards compatibility issues reported by people), and 28 closed (last release: 8 open, 24 closed).
- [merged PRs](https://github.com/pygame/pygame/pulls?q=is%3Apr+is%3Aclosed+merged%3A2020-06-01..2020-09-20+sort%3Aupdated-desc+)
- [1890 Commits since 1.9.6 stable release](https://github.com/pygame/pygame/compare/1.9.6...2.0.0.dev12)
- [447 Commits since 2.0.0.dev10 pre release](https://github.com/pygame/pygame/compare/2.0.0.dev10...2.0.0.dev12)

Page 10 of 10

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.