-
Notifications
You must be signed in to change notification settings - Fork 320
Add support to build on SDK 37 #6590
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Changes from all commits
c3df770
5f51cf4
f1c07ca
48daee0
b898334
574a73a
e7dcdb9
c3ac3a0
7ecf8e1
db85ab4
17f789f
dc80a1e
98800e7
256438e
7dc54cf
e840248
5eb3e60
33ca5df
1188433
8a59e91
a747510
9e387f2
beda413
04d7c97
8f9b979
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -21,7 +21,9 @@ jobs: | |
| ref: ${{ github.event.release.tag_name }} | ||
| fetch-depth: 0 | ||
| persist-credentials: false | ||
| - uses: GetStream/android-ci-actions/actions/setup-java@main | ||
| - uses: GetStream/stream-build-conventions-android/.github/workflows/android-ci.yml@feature/rahullohra/build-on-sdk-37 | ||
| with: | ||
| java-version: '21' | ||
|
Comment on lines
+24
to
+26
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🔴 Critical | ⚡ Quick win 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -euo pipefail
echo "Changed file:"
git ls-files .github/workflows/attach-release-apk.yml || true
echo
echo "Workflow excerpt:"
if [ -f .github/workflows/attach-release-apk.yml ]; then
sed -n '1,120p' .github/workflows/attach-release-apk.yml | cat -n
fi
echo
echo "Relevant references in workflows:"
rg -n "uses: GetStream/stream-build-conventions-android/.github/workflows/android-ci.yml|android-ci.yml|setup-java|getstream|GetStream" .github/workflows || true
echo
echo "Check repository context for workflow files on referenced repo unavailable?"
python3 - <<'PY'
# Deterministic check: parse YAML-like uses entries and identify /workflows/ paths under steps.
import pathlib,re
p=pathlib.Path('.github/workflows/attach-release-apk.yml')
if not p.exists():
print("file missing")
raise SystemExit
text=p.read_text()
lines=text.splitlines()
in_steps=False
step_depth=0
uses_entries=[]
for i,line in enumerate(lines,1):
if re.match(r'\s*steps:\s*$', line):
in_steps=True
step_depth=len(line)-len(line.lstrip())+2
continue
if in_steps:
m=re.match(r'\s{4}uses:\s*(.+)\s*$', line)
if m:
uses_entries.append((i,m.group(1).strip()))
if re.match(r'^\S', line):
break
print("uses entries near job:")
for i,u in uses_entries:
print(f"{i}: {u}")
print("uses paths under steps that target workflow files:", [u for i,u in uses_entries if '/workflows/' in u])
PYRepository: GetStream/stream-chat-android Length of output: 1944 Move the reusable workflow call out of
🤖 Prompt for AI Agents |
||
| - name: Prepare signing environment | ||
| env: | ||
| RELEASE_KEYSTORE: ${{ secrets.RELEASE_KEYSTORE }} | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can't we regenerate them locally like today? I checked on my machine and:
I'd avoid having to rely on CI for regenerating snapshots if possible, as it will slow us down compared to today. Also one less workflow + script to maintain. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
| name: Record Paparazzi Snapshots | ||
|
|
||
| # Manually-triggered job that regenerates Paparazzi golden images on the CI runner (Linux/amd64) | ||
| # and uploads them as an artifact. Paparazzi renders via native layoutlib, whose pixels depend on | ||
| # OS + architecture, so goldens must be produced in the same environment which verifies — | ||
| # the CI runner. | ||
| # Download the artifact with scripts/paparazzi-pull-goldens.sh, then commit + push. | ||
| # Deliberately does NOT commit back: no write permissions needed, and you review the diff locally. | ||
| on: | ||
| # Manual trigger — only works once this file is on the default branch (kept for later). | ||
| workflow_dispatch: | ||
| # Branch trigger — works from a feature branch without default-branch access. The heavy job is | ||
| # gated by a commit-message marker (see the job's `if:`) so ordinary pushes don't run it. | ||
| # To trigger: git commit --allow-empty -m "record goldens [record-paparazzi]" && git push | ||
| push: | ||
| branches: | ||
| - "feature/rahullohra/**" | ||
|
|
||
| concurrency: | ||
| group: record-paparazzi-${{ github.ref }} | ||
| cancel-in-progress: true | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: | ||
| record: | ||
| name: Record golden images (Linux/amd64) | ||
| runs-on: ubuntu-latest # Same runner as the verify job, so recorded pixels match verification. | ||
| # Run only on manual dispatch, or on a push whose commit message contains [record-paparazzi]. | ||
| if: >- | ||
| github.event_name == 'workflow_dispatch' || | ||
| contains(github.event.head_commit.message, '[record-paparazzi]') | ||
| steps: | ||
| - uses: actions/checkout@v7 | ||
| - name: Setup Java | ||
| uses: actions/setup-java@v4 | ||
| with: | ||
| java-version: '21' # Paparazzi 2.0.0-alpha05 requires JDK 21. | ||
| distribution: temurin | ||
| - name: Setup Gradle | ||
| uses: gradle/actions/setup-gradle@v4 | ||
|
Check failure on line 42 in .github/workflows/record-paparazzi.yml
|
||
|
|
||
| - name: Record Paparazzi goldens | ||
| # cleanRecord so stale / differently-named goldens are removed and the artifact is the | ||
| # exact set the current tests produce under this Paparazzi/layoutlib version. | ||
| run: ./gradlew cleanRecordPaparazziDebug --stacktrace | ||
| - name: Upload recorded goldens | ||
| uses: actions/upload-artifact@v4 | ||
| with: | ||
| name: paparazzi-goldens | ||
| # Paths are preserved relative to the workspace, i.e. <module>/src/test/snapshots/..., | ||
| # so the local pull script can overlay them straight onto the repo root. | ||
| path: '**/src/test/snapshots/**' | ||
| if-no-files-found: error | ||
| retention-days: 7 | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -22,7 +22,6 @@ plugins { | |
| alias(libs.plugins.detekt) apply false | ||
| alias(libs.plugins.shot) apply false | ||
| alias(libs.plugins.androidx.navigation) apply false | ||
| alias(libs.plugins.gitversioner) | ||
| alias(libs.plugins.gradle.versions) | ||
| alias(libs.plugins.binary.compatibility.validator) | ||
| } | ||
|
|
@@ -98,6 +97,23 @@ subprojects { | |
| } | ||
|
|
||
| apply(plugin = "io.gitlab.arturbosch.detekt") | ||
|
|
||
| // Align the androidx.test family across every configuration. Shot (in the sample apps) drags an | ||
| // old androidx.test (core 1.5.0 / monitor 1.6.0 / storage 1.4.2) onto the main runtime classpath | ||
| // via fragment-testing / compose-ui-test, while androidx.test.ext:junit 1.2.1 needs newer ones on | ||
| // the androidTest classpath. AGP consistent resolution then can't reconcile the two. Forcing the | ||
| // family (main included) makes both classpaths resolve the same versions. | ||
| configurations.configureEach { | ||
| resolutionStrategy { | ||
| force( | ||
| "androidx.test:core:1.6.1", | ||
| "androidx.test:core-ktx:1.6.1", | ||
| "androidx.test:runner:1.6.2", | ||
| "androidx.test:monitor:1.7.2", | ||
| "androidx.test.services:storage:1.5.0", | ||
| ) | ||
| } | ||
| } | ||
|
Comment on lines
+101
to
+116
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It isn't Shot — it's It's also unused: that module has no I removed that line and this block together and re-resolved: ui-components-sample, compose-sample and ui-uitests androidTest classpaths all resolve, and the Worth preferring that: |
||
| } | ||
|
|
||
| tasks.withType<DependencyUpdatesTask> { | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wouldn't use temporary branch names. We can publish a release with a version suffix (e.g. 0.14.0-sdk37, 1.0.0-beta, or something along those lines) and point to that. Adding support in GetStream/stream-build-conventions-android#73
Aside from that, this seems incorrect. The step was using an action but now points to a workflow 🤔