Skip to content

Commit feb7a22

Browse files
committed
Merge remote-tracking branch 'origin/25.x' into 25.x
# Conflicts: # ruby/ext/google/protobuf_c/message.c # ruby/lib/google/protobuf/ffi/descriptor_pool.rb # ruby/tests/basic.rb # ruby/tests/basic_test.proto
2 parents b4e54cc + a2e03a3 commit feb7a22

File tree

157 files changed

+2403
-820
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+2403
-820
lines changed

.bazelrc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ build:ubsan --copt=-DUNDEFINED_SANITIZER=1
2626
# Workaround for the fact that Bazel links with $CC, not $CXX
2727
# https://github.com/bazelbuild/bazel/issues/11122#issuecomment-613746748
2828
build:ubsan --copt=-fno-sanitize=function --copt=-fno-sanitize=vptr
29+
# Abseil passes nullptr to memcmp with 0 size
30+
build:ubsan --copt=-fno-sanitize=nonnull-attribute
2931

3032
# TODO: migrate all dependencies from WORKSPACE to MODULE.bazel
3133
# https://github.com/protocolbuffers/protobuf/issues/14313

.github/BUILD.bazel

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# This information is extracted from the MacOS runner specs located at:
2-
# https://github.com/actions/runner-images/blob/main/images/macos/macos-12-Readme.md
2+
# https://github.com/actions/runner-images/blob/main/images/macos/macos-13-Readme.md
33
#
44
# When updating, also ensure the "xcode_destination" entries in
55
# `.github/workflows/test_objectivec.yml` are supported for the given versions

.github/workflows/scorecard.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
4848
# format to the repository Actions tab.
4949
- name: "Upload artifact"
50-
uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
50+
uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0
5151
with:
5252
name: SARIF file
5353
path: results.sarif

.github/workflows/staleness_check.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ jobs:
1818
strategy:
1919
fail-fast: false
2020
matrix:
21-
branch: [main, 22.x, 23.x, 24.x]
21+
branch: [25.x]
2222
os: [{ name: Linux, value: ubuntu-latest}]
2323

2424
name: Test staleness ${{ matrix.os.name }} ${{ github.head_ref && 'PR' || matrix.branch }}
@@ -39,6 +39,8 @@ jobs:
3939
run: echo "MAIN_RUN=1" >> $GITHUB_ENV
4040

4141
- name: Run all staleness tests
42+
env:
43+
USE_BAZEL_VERSION: '6.3.2'
4244
# Run all tests if either of the following is true, otherwise simply run the query to make
4345
# sure it continues to work:
4446
# 1) If this is not a commit-based run it means it's scheduled or manually dispatched. In
@@ -51,9 +53,9 @@ jobs:
5153
# commit.
5254
run: |
5355
set -ex
56+
echo "Please run ./regenerate_stale_files.sh to regenerate stale files";
5457
if [[ -z $COMMIT_TRIGGERED_RUN || -z $MAIN_RUN ]]; then
55-
bazel query 'attr(tags, "staleness_test", //...)' | xargs bazel test $BAZEL_FLAGS || \
56-
echo "Please run ./regenerate_stale_files.sh to regenerate stale files"
58+
bazel query 'attr(tags, "staleness_test", //...)' | xargs bazel test $BAZEL_FLAGS
5759
else
5860
bazel query 'attr(tags, "staleness_test", //...)'
5961
fi

.github/workflows/test_cpp.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ jobs:
1919
config:
2020
- { name: Optimized, flags: --config=opt }
2121
- { name: Debug, flags: --config=dbg }
22-
- { name: ASAN, flags: --config=asan, runner: ubuntu-22-large }
23-
- { name: MSAN, flags: --config=docker-msan, runner: ubuntu-22-large }
24-
- { name: TSAN, flags: --config=tsan }
22+
- { name: ASAN, flags: --config=asan, runner: ubuntu-20-4core }
23+
- { name: MSAN, flags: --config=docker-msan, runner: ubuntu-20-4core }
24+
- { name: TSAN, flags: --config=tsan, runner: ubuntu-20-4core }
2525
- { name: UBSAN, flags: --config=ubsan }
2626
- { name: No-RTTI, flags: --cxxopt=-fno-rtti }
2727
include:
@@ -77,7 +77,7 @@ jobs:
7777
matrix:
7878
arch: [x86_64, aarch64]
7979
name: Linux Release ${{ matrix.arch}}
80-
runs-on: ubuntu-latest
80+
runs-on: ubuntu-20-4core
8181
steps:
8282
- name: Checkout pending changes
8383
uses: protocolbuffers/protobuf-ci/checkout@v2
@@ -314,12 +314,12 @@ jobs:
314314
matrix:
315315
include:
316316
- name: MacOS
317-
os: macos-12
318-
cache_key: macos-12
317+
os: macos-13
318+
cache_key: macos-13
319319
bazel: test //src/...
320320
- name: MacOS Apple Silicon (build only)
321-
os: macos-12
322-
cache_key: macos-12-arm
321+
os: macos-13
322+
cache_key: macos-13-arm
323323
# Current github runners are all Intel based, so just build/compile
324324
# for Apple Silicon to detect issues there.
325325
bazel: build --cpu=darwin_arm64 //src/...
@@ -347,7 +347,7 @@ jobs:
347347
matrix:
348348
include:
349349
- name: MacOS CMake
350-
os: macos-12
350+
os: macos-13
351351
flags: -DCMAKE_CXX_STANDARD=14
352352
cache-prefix: macos-cmake
353353
- name: Windows CMake
@@ -367,7 +367,7 @@ jobs:
367367
vsversion: '2019'
368368
cache-prefix: windows-2019-cmake
369369
# windows-2019 has python3.7 installed, which is incompatible with the latest gcloud
370-
python-version: '3.8'
370+
python-version: '3.9'
371371
- name: Windows CMake 32-bit
372372
os: windows-2022
373373
flags: >-

.github/workflows/test_objectivec.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@ jobs:
2525
destination: "platform=macOS"
2626
xc_project: "ProtocolBuffers_OSX.xcodeproj"
2727
- platform: "iOS"
28-
destination: "platform=iOS Simulator,name=iPhone 13,OS=latest"
28+
destination: "platform=iOS Simulator,name=iPhone 14,OS=latest"
2929
xc_project: "ProtocolBuffers_iOS.xcodeproj"
3030

3131
name: Xcode ${{ matrix.platform}} ${{ matrix.xc_config }}
32-
runs-on: macos-12
32+
runs-on: macos-13
3333
env:
3434
DEVELOPER_DIR: /Applications/Xcode_14.1.app/Contents/Developer
3535
steps:
@@ -72,7 +72,7 @@ jobs:
7272
PLATFORM: ["ios", "macos", "tvos"]
7373
CONFIGURATION: ["Debug", "Release"]
7474
name: CocoaPods ${{ matrix.PLATFORM}} ${{ matrix.CONFIGURATION}}
75-
runs-on: macos-12
75+
runs-on: macos-13
7676
env:
7777
DEVELOPER_DIR: /Applications/Xcode_14.1.app/Contents/Developer
7878
steps:
@@ -115,7 +115,7 @@ jobs:
115115
- platform: "macOS"
116116
bazel_targets: //objectivec/...
117117
name: Bazel ${{ matrix.platform }} ${{ matrix.config.name }}
118-
runs-on: macos-12
118+
runs-on: macos-13
119119
steps:
120120
- name: Checkout pending changes
121121
uses: protocolbuffers/protobuf-ci/checkout@v2

.github/workflows/test_php.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,10 +150,9 @@ jobs:
150150
strategy:
151151
fail-fast: false # Don't cancel all jobs if one fails.
152152
matrix:
153-
version: ['8.0']
154-
153+
version: ['8.2']
155154
name: MacOS PHP ${{ matrix.version }}
156-
runs-on: macos-12
155+
runs-on: macos-13
157156
steps:
158157
- name: Checkout pending changes
159158
uses: protocolbuffers/protobuf-ci/checkout@v2
@@ -167,7 +166,7 @@ jobs:
167166
run: brew install coreutils gd
168167

169168
- name: Pin PHP version
170-
uses: shivammathur/setup-php@7fdd3ece872ec7ec4c098ae5ab7637d5e0a96067 # 2.26.0
169+
uses: shivammathur/setup-php@a4e22b60bbb9c1021113f2860347b0759f66fe5d # 2.30.0
171170
with:
172171
php-version: ${{ matrix.version }}
173172

.github/workflows/test_php_ext.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
bazel build //php:release $BAZEL_FLAGS;
3232
cp bazel-bin/php/protobuf-*.tgz .
3333
34-
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
34+
- uses: actions/upload-artifact@50769540e7f4bd5e21e526ee35c689e35e0d6874 # v4.4.0
3535
with:
3636
name: protobuf-php-release
3737
path: protobuf-*.tgz
@@ -45,7 +45,7 @@ jobs:
4545
name: Build ${{ matrix.version }}
4646
runs-on: ubuntu-latest
4747
steps:
48-
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
48+
- uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 #4.1.8
4949
with:
5050
name: protobuf-php-release
5151

.github/workflows/test_python.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ jobs:
6464
flags: --define=use_fast_cpp_protos=true
6565

6666
name: MacOS ${{ matrix.type }} ${{ matrix.version }}
67-
runs-on: macos-12
67+
runs-on: macos-13
6868
steps:
6969
- name: Checkout pending changes
7070
uses: protocolbuffers/protobuf-ci/checkout@v2

.github/workflows/test_ruby.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,14 @@ jobs:
1919
include:
2020
# Test both FFI and Native implementations on the highest and lowest
2121
# Ruby versions for CRuby and JRuby, but only on Bazel 5.x.
22-
- { name: Ruby 2.7, ruby: ruby-2.7.0, ffi: NATIVE }
23-
# TODO Re-enable these once flakes are fixed
24-
#- { name: Ruby 2.7, ruby: ruby-2.7.0, ffi: FFI }
2522
- { name: Ruby 3.0, ruby: ruby-3.0.2 }
2623
- { name: Ruby 3.1, ruby: ruby-3.1.0 }
2724
- { name: Ruby 3.2, ruby: ruby-3.2.0, ffi: NATIVE }
25+
- { name: Ruby 3.3, ruby: ruby-3.3.0, ffi: NATIVE }
2826
# TODO Re-enable these once flakes are fixed
2927
#- { name: Ruby 3.2, ruby: ruby-3.2.0, ffi: FFI }
30-
- { name: JRuby 9.4, ruby: jruby-9.4.3.0, ffi: NATIVE }
31-
- { name: JRuby 9.4, ruby: jruby-9.4.3.0, ffi: FFI }
28+
- { name: JRuby 9.4, ruby: jruby-9.4.6.0, ffi: NATIVE }
29+
- { name: JRuby 9.4, ruby: jruby-9.4.6.0, ffi: FFI }
3230

3331
name: Linux ${{ matrix.name }}${{ matrix.ffi == 'FFI' && ' FFI' || '' }}
3432
runs-on: ubuntu-latest
@@ -40,7 +38,7 @@ jobs:
4038
- name: Run tests
4139
uses: protocolbuffers/protobuf-ci/bazel-docker@v2
4240
with:
43-
image: ${{ matrix.image || format('us-docker.pkg.dev/protobuf-build/containers/test/linux/ruby:{0}-6.3.0-66964dc8b07b6d1fc73a5cc14e59e84c1c534cea', matrix.ruby) }}
41+
image: ${{ matrix.image || format('us-docker.pkg.dev/protobuf-build/containers/test/linux/ruby:{0}-6.3.0-384d5abe83a791c6b1ce04f5d7bc0b1f84a30d38', matrix.ruby) }}
4442
credentials: ${{ secrets.GAR_SERVICE_ACCOUNT }}
4543
bazel-cache: ruby_linux/${{ matrix.ruby }}_${{ matrix.bazel }}
4644
bazel: test //ruby/... //ruby/tests:ruby_version --test_env=KOKORO_RUBY_VERSION --test_env=BAZEL=true ${{ matrix.ffi == 'FFI' && '--//ruby:ffi=enabled --test_env=PROTOCOL_BUFFERS_RUBY_IMPLEMENTATION=FFI' || '' }}
@@ -67,9 +65,10 @@ jobs:
6765
with:
6866
image: i386/ruby:2.7.3-buster
6967
credentials: ${{ secrets.GAR_SERVICE_ACCOUNT }}
68+
# Pin to Ruby 2.7 compatible bundler version.
7069
command: >-
7170
/bin/bash -cex '
72-
gem install bundler;
71+
gem install bundler -v 2.4.22;
7372
cd /workspace/ruby;
7473
bundle;
7574
PROTOC=/workspace/${{ steps.cross-compile.outputs.protoc }} rake;
@@ -98,9 +97,10 @@ jobs:
9897
with:
9998
image: arm64v8/ruby:2.7.3-buster
10099
credentials: ${{ secrets.GAR_SERVICE_ACCOUNT }}
100+
# Pin to Ruby 2.7 compatible bundler version.
101101
command: >-
102102
/bin/bash -cex '
103-
gem install bundler;
103+
gem install bundler -v 2.4.22;
104104
cd /workspace/ruby;
105105
bundle;
106106
PROTOC=/workspace/${{ steps.cross-compile.outputs.protoc }} rake;
@@ -125,15 +125,15 @@ jobs:
125125
#- { version: "3.2", ffi: FFI }
126126

127127
name: MacOS Ruby ${{ matrix.version }}${{ matrix.ffi == 'FFI' && ' FFI' || '' }}
128-
runs-on: macos-12
128+
runs-on: macos-13
129129
steps:
130130
- name: Checkout pending changes
131131
uses: protocolbuffers/protobuf-ci/checkout@v2
132132
with:
133133
ref: ${{ inputs.safe-checkout }}
134134

135135
- name: Pin Ruby version
136-
uses: ruby/setup-ruby@ee26e27437bde475b19a6bf8cb73c9fa658876a2 # v1.134.0
136+
uses: ruby/setup-ruby@961f85197f92e4842e3cb92a4f97bd8e010cdbaf # v1.165.0
137137
with:
138138
ruby-version: ${{ matrix.version }}
139139

0 commit comments

Comments
 (0)