Skip to content

Commit d9c1c0e

Browse files
authored
Merge branch 'main' into docs-to-stubs
2 parents 2c36fc9 + 71d8b23 commit d9c1c0e

36 files changed

+429
-108
lines changed

.github/workflows/build-macos.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ jobs:
5151

5252
- name: Test for Mac Deps cache hit
5353
id: macdep-cache
54-
uses: actions/cache@v4.1.2
54+
uses: actions/cache@v4.2.0
5555
with:
5656
path: ${{ github.workspace }}/pygame_mac_deps_${{ matrix.macarch }}
5757
# The hash of all files in buildconfig manylinux-build and macdependencies is
@@ -118,14 +118,14 @@ jobs:
118118
- uses: actions/[email protected]
119119

120120
- name: pip cache
121-
uses: actions/cache@v4.1.2
121+
uses: actions/cache@v4.2.0
122122
with:
123123
path: ~/Library/Caches/pip # This cache path is only right on mac
124124
key: pip-cache-${{ matrix.macarch }}-${{ matrix.os }}
125125

126126
- name: Fetch Mac deps
127127
id: macdep-cache
128-
uses: actions/cache@v4.1.2
128+
uses: actions/cache@v4.2.0
129129
with:
130130
path: ${{ github.workspace }}/pygame_mac_deps_${{ matrix.macarch }}
131131
key: macdep-${{ hashFiles('buildconfig/manylinux-build/**') }}-${{ hashFiles('buildconfig/macdependencies/*.sh') }}-${{ matrix.macarch }}

.github/workflows/build-sdl3.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,17 @@ jobs:
8686
cmake --build . --config Release --parallel
8787
sudo cmake --install . --config Release
8888
89+
- name: Install SDL3_image
90+
if: matrix.os != 'windows-latest'
91+
run: |
92+
git clone https://github.com/libsdl-org/SDL_image
93+
cd SDL_image
94+
mkdir build
95+
cd build
96+
cmake -DCMAKE_BUILD_TYPE=Release ..
97+
cmake --build . --config Release --parallel
98+
sudo cmake --install . --config Release
99+
89100
- name: Build with SDL3
90101
run: python3 dev.py build --sdl3
91102

.github/workflows/build-ubuntu-sdist.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ jobs:
8484

8585
- name: Test typestubs
8686
run: |
87-
pip3 install mypy
87+
pip3 install mypy==1.13.0
8888
python3 buildconfig/stubs/stubcheck.py
8989
9090
# We upload the generated files under github actions assets

.github/workflows/release-gh-draft.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ jobs:
6161
run: echo "VER=${GITHUB_REF_NAME#'release/'}" >> $GITHUB_OUTPUT
6262

6363
- name: Generate release attestation
64-
uses: actions/attest-build-provenance@v1.4.4
64+
uses: actions/attest-build-provenance@v2.1.0
6565
with:
6666
subject-path: "pygame-wheels/*"
6767

buildconfig/download_win_prebuilt.py

Lines changed: 24 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -78,16 +78,20 @@ def get_urls(x86=True, x64=True):
7878
url_sha1 = []
7979
url_sha1.extend([
8080
[
81-
'https://github.com/libsdl-org/SDL/releases/download/release-2.30.9/SDL2-devel-2.30.9-VC.zip',
82-
'd89a2ad46b98ba08db5ec5877cb2fde46e127825',
81+
'https://github.com/libsdl-org/SDL/releases/download/release-2.30.10/SDL2-devel-2.30.10-VC.zip',
82+
'42378fd090d547d03dca8c9df584ba8f38555809',
8383
],
8484
[
8585
'https://github.com/libsdl-org/SDL/releases/download/preview-3.1.6/SDL3-devel-3.1.6-VC.zip',
8686
'7a3b9ed85cfe735c7e106d98c4b6395a113e5d7e'
8787
],
8888
[
89-
'https://github.com/pygame-community/SDL_image/releases/download/2.8.2-pgce/SDL2_image-devel-2.8.2-VCpgce.zip',
90-
'983484dd816abf25cdd5bce88ac69dbca1ea713a'
89+
'https://github.com/pygame-community/SDL_image/releases/download/2.8.3-pgce/SDL2_image-devel-2.8.3-VCpgce.zip',
90+
'71ad2b5aacbc934a39e390ad733421313dd5d059'
91+
],
92+
[
93+
'https://github.com/libsdl-org/SDL_image/releases/download/preview-3.1.0/SDL3_image-devel-3.1.0-VC.zip',
94+
'8538fea0cc4aabba2fc64db06196f1bb76a2785f'
9195
],
9296
[
9397
'https://github.com/libsdl-org/SDL_ttf/releases/download/release-2.22.0/SDL2_ttf-devel-2.22.0-VC.zip',
@@ -205,14 +209,26 @@ def copy(src, dst):
205209
copy(
206210
os.path.join(
207211
temp_dir,
208-
'SDL2_image-devel-2.8.2-VCpgce/SDL2_image-2.8.2'
212+
'SDL2_image-devel-2.8.3-VCpgce/SDL2_image-2.8.3'
213+
),
214+
os.path.join(
215+
move_to_dir,
216+
prebuilt_dir,
217+
'SDL2_image-2.8.3'
218+
)
219+
)
220+
copy(
221+
os.path.join(
222+
temp_dir,
223+
'SDL3_image-devel-3.1.0-VC/SDL3_image-3.1.0'
209224
),
210225
os.path.join(
211226
move_to_dir,
212227
prebuilt_dir,
213-
'SDL2_image-2.8.2'
228+
'SDL3_image-3.1.0'
214229
)
215230
)
231+
216232
copy(
217233
os.path.join(
218234
temp_dir,
@@ -238,12 +254,12 @@ def copy(src, dst):
238254
copy(
239255
os.path.join(
240256
temp_dir,
241-
'SDL2-devel-2.30.9-VC/SDL2-2.30.9'
257+
'SDL2-devel-2.30.10-VC/SDL2-2.30.10'
242258
),
243259
os.path.join(
244260
move_to_dir,
245261
prebuilt_dir,
246-
'SDL2-2.30.9'
262+
'SDL2-2.30.10'
247263
)
248264
)
249265
copy(

buildconfig/manylinux-build/docker_base/sdl_libs/build-sdl2-libs.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ set -e -x
33

44
cd $(dirname `readlink -f "$0"`)
55

6-
SDL2_VER="2.30.9"
6+
SDL2_VER="2.30.10"
77
SDL2="SDL2-$SDL2_VER"
8-
IMG2_VER="2.8.2"
8+
IMG2_VER="2.8.3"
99
IMG2="SDL2_image-$IMG2_VER"
1010
TTF2_VER="2.22.0"
1111
TTF2="SDL2_ttf-$TTF2_VER"
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
30dfa86fcced174fef0ed78ffa53476a31765e19cdcdf8233ab92876445b4dedaa758fc42a3ec332324d13faa2daafcadcc44fc0f536a2969ef836162ec3cd36 SDL2-2.30.9.tar.gz
2-
0ff345824f95158dfa72f83f9d4a540601c178cd759334bf849c14a2920b5330d0763413b58c08b3deba8d3a4ccb6ea2a8159f87efe4cbb0e8ea850f63d09454 SDL2_image-2.8.2.tar.gz
1+
bcb220749cd3b0874288d617419e622701138bcb8fe55e9b665e8843c65afda031d01afe0d11e308a9608724ed151f342e5f5670c84204b36943cb323ced41da SDL2-2.30.10.tar.gz
2+
b49e466494a4bebcacc09e3fe2afbe5edbae636c007cd26e7e04301bf8fe54db6751258b750a79656e5aa261869900d39703f1311df4c63ef415ae443f62295f SDL2_image-2.8.3.tar.gz
33
5ddbc4b0b5fad2e0844a503daa79564b912654192599ef8fa7698531f08323ce01801f6bb17b2b3905020a3df362a967b7566ae725eb085da991578cc0807aad SDL2_mixer-2.8.0.tar.gz
44
34a1d210d8f1b1e802139d65ba47e36033bb7881e75a8862c1b1c515565bef85e3d81ee42e952aa664de043debef387ba60088a9cf3ba3297413db39a13af912 SDL2_ttf-2.22.0.tar.gz

buildconfig/stubs/pygame/__init__.pyi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ from .constants import (
111111
BLENDMODE_ADD as BLENDMODE_ADD,
112112
BLENDMODE_BLEND as BLENDMODE_BLEND,
113113
BLENDMODE_MOD as BLENDMODE_MOD,
114+
BLENDMODE_MUL as BLENDMODE_MUL,
114115
BLENDMODE_NONE as BLENDMODE_NONE,
115116
BLEND_ADD as BLEND_ADD,
116117
BLEND_ALPHA_SDL2 as BLEND_ALPHA_SDL2,

buildconfig/stubs/pygame/constants.pyi

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ BIG_ENDIAN: int
3434
BLENDMODE_ADD: int
3535
BLENDMODE_BLEND: int
3636
BLENDMODE_MOD: int
37+
BLENDMODE_MUL: int
3738
BLENDMODE_NONE: int
3839
BLEND_ADD: int
3940
BLEND_ALPHA_SDL2: int

buildconfig/stubs/pygame/display.pyi

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,14 +44,16 @@ def set_mode(
4444
display: int = 0,
4545
vsync: int = 0,
4646
) -> Surface: ...
47-
def get_surface() -> Surface: ...
47+
def get_surface() -> Optional[Surface]: ...
4848
def flip() -> None: ...
4949
@overload
50+
def update() -> None: ...
51+
@overload
5052
def update(
51-
rectangle: Optional[Union[RectLike, Iterable[Optional[RectLike]]]] = None, /
53+
rectangle: Optional[Union[RectLike, Iterable[Optional[RectLike]]]], /
5254
) -> None: ...
5355
@overload
54-
def update(x: int, y: int, w: int, h: int, /) -> None: ...
56+
def update(x: float, y: float, w: float, h: float, /) -> None: ...
5557
@overload
5658
def update(xy: Point, wh: Point, /) -> None: ...
5759
def get_driver() -> str: ...

0 commit comments

Comments
 (0)