Make the preview APK reproducible from its tag

Abierto
#26 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
5/5
Tiempo estimado
Más de una semana
Aptitud para principiantes
35/100
Tipo de issue
Nueva funcionalidad
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
android, github-actions, react-native, typescript

Línea de trabajo

Start with the APK recipe in docs/devices.md and the release workflow in .github/workflows/release-apk.yml; trace how the tag version and workflow run number reach apps/mobile/app.json and the release notes. Build twice from one tag as the recipe describes, then compare the unzipped APK contents while excluding META-INF/. Document each source of differences and whether it was fixed. Done means matching unsigned contents, an automated check, and the recipe on the download page and in release notes.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

accepted help wanted

Why

Anyone can build Hermit from the tag a preview APK came from, but the result doesn't match the published APK byte for byte, and nothing checks it. The PRD lists the reproducible APK as open (SL-45 and NFR-15 in docs/prd/hermit-prd.md). A rebuild that matches, apart from the signature, is how people can trust that the APK is the code they read.

What to do

  1. Make the recipe complete. Before it builds, .github/workflows/release-apk.yml writes the version from the tag, and a versionCode equal to the workflow's run number, into apps/mobile/app.json. Put the same step in the recipe in docs/devices.md ("Or build it yourself"), and print the versionCode in the release notes so a rebuild can use it.
  2. Build twice from the same tag, on two machines or two clean clones, following docs/devices.md. Compare the APKs with the signature left out: unzip both and compare every file except META-INF/, or use diffoscope.
  3. Find and remove each source of difference, such as timestamps, file order, absolute paths, the JavaScript bundle or the native builds. List what you find in the pull request, even the parts you couldn't fix.
  4. When two builds match, add a script or a CI job that checks it, and put the recipe in the release notes.

Done when

  • Two builds from the same tag give APKs that match apart from the signature, and a script or a CI job shows it.
  • docs/devices.md and the site's download page say so, and the release notes carry the recipe.

How to check

Build twice as docs/devices.md says, then compare the unzipped APKs without META-INF/.

Keep in mind

  • Compare unsigned contents. Never ask for the preview key, and never commit a keystore or a password.
  • The app gains no network call. Build-time downloads are fine when their versions are pinned.
Lenguaje dominante
TypeScript
Estrellas
11
Forks
0
Merge medio
10 min
PR fusionados (30 d)
6

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de DojoCodingLabs/hermit

Todos los issues de DojoCodingLabs/hermit

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.