Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

Android autolinking keeps a stale autolinking.json when only bun.lock changes, since bun.lock isn't in the default lockFiles

Ouverte Adaptée aux débutants
#59,693 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Les mainteneurs répondent en général sous 2 jours

Personne n'a encore pris cette issue.

Évaluation

Difficulté
1/5
Temps estimé
Moins d'une heure
Accessibilité débutants
85/100
Type d'issue
Bug
Clarté
Clairement spécifiée
Activité
Active
Stack technique
bun, kotlin, react-native
Domaine
build-system

Piste de recherche

Commence dans packages/gradle-plugin/settings-plugin/src/main/kotlin/com/facebook/react/ReactSettingsExtension.kt, au niveau de la liste par défaut lockFiles autour des lignes 48-61, qui nomme actuellement les fichiers de configuration yarn, npm, pnpm et react-native mais pas bun. Ajoute bun.lock à cet ensemble par défaut afin que les modifications le concernant déclenchent la commande de configuration d'autolinking. Vérifie avec le reproducer lié en exécutant bun install et ./gradlew help, puis vérifie que build/generated/autolinking/autolinking.json indique la version nouvellement installée.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

Description

The settings plugin reruns the autolinking config command only when one of lockFiles changed, and the default list in ReactSettingsExtension.autolinkLibrariesFromCommand is yarn.lock, package-lock.json, package.json, react-native.config.js and pnpm-lock.yaml. A project installed with bun has bun.lock, so when a change touches only bun.lock (a lock-file refresh, or pulling a teammate's one), android/build/generated/autolinking/autolinking.json keeps the libraries' config from before it.

Steps to reproduce
  1. Clone https://github.com/YevheniiKotyrlo/rn-autolinking-cache-bun-lock. ReproducerApp installs with bun (isolated linker) and lists react-native-safe-area-context as ^5.10.0; the last commit moves it from 5.10.1 to 5.11.0 in bun.lock alone.
  2. git switch --detach HEAD~1, then in ReproducerApp run bun install, and in ReproducerApp/android run ./gradlew help. build/generated/autolinking/autolinking.json has "version": "5.10.1" for react-native-safe-area-context.
  3. git switch main, then bun install and ./gradlew help again.

Expected: the config command reruns, and autolinking.json has "version": "5.11.0", as npx react-native config now prints.

Actual: autolinking.json still has "version": "5.10.1", while 5.11.0 is installed and npx react-native config prints "version": "5.11.0".

React Native Version

0.89.0-nightly-20261030-4afc5d5b9

Affected Platforms

Build - Windows

Output of npx @react-native-community/cli info
System:
  OS: Windows 11 10.0.26300
  CPU: "(32) x64 AMD Ryzen 9 9950X3D 16-Core Processor          "
  Memory: 132.59 GB / 255.67 GB
Binaries:
  Node:
    version: 26.12.1
    path: C:\Program Files\nodejs\node.EXE
  Yarn:
    version: 1.22.22
    path: C:\Users\yevhe.YEVHENII\AppData\Roaming\npm\yarn.CMD
  npm:
    version: 12.2.1
    path: C:\Program Files\nodejs\npm.CMD
  Watchman: Not Found
SDKs:
  Android SDK:
    API Levels:
      - "33"
      - "35"
      - "35"
      - "35"
      - "36"
      - "37"
      - "37"
    Build Tools:
      - 35.0.0
      - 36.0.0
      - 36.1.0
      - 37.0.0
    System Images:
      - android-26 | Google APIs Intel x86_64 Atom
      - android-28 | Google APIs Intel x86_64 Atom
      - android-29 | Google APIs Intel x86_64 Atom
      - android-30 | Google APIs Intel x86_64 Atom
      - android-31 | Google APIs Intel x86_64 Atom
      - android-32 | Google APIs Intel x86_64 Atom
      - android-33 | Google APIs Intel x86_64 Atom
      - android-34 | Google APIs Intel x86_64 Atom
      - android-35 | Google APIs Intel x86_64 Atom
      - android-36.1 | Google Play Intel x86_64 Atom
      - android-36.1 | Pre-Release 16 KB Page Size Google Play Intel x86_64 Atom
      - android-37.0 | Google APIs Intel x86_64 Atom
    Android NDK: Not Found
  Windows SDK: Not Found
IDEs:
  Android Studio: AI-262.9437.185.2621.16467767
  Visual Studio: Not Found
Languages:
  Java:
    version: 17.0.20.1
    path: C:\Program Files\Microsoft\jdk-17.0.20.101-hotspot\bin\javac.EXE
  Ruby: Not Found
npmPackages:
  "@react-native-community/cli":
    installed: 21.0.0-alpha.1
    wanted: 21.0.0-alpha.1
  react:
    installed: 19.3.0
    wanted: 19.3.0
  react-native:
    installed: 0.89.0-nightly-20261030-4afc5d5b9
    wanted: 0.89.0-nightly-20261030-4afc5d5b9
  react-native-windows: Not Found
npmGlobalPackages:
  "*react-native*": Not Found
Android:
  hermesEnabled: true
  newArchEnabled: true
iOS:
  hermesEnabled: Not found
  newArchEnabled: Not found
Stacktrace or Logs
$ grep '"version"' android/build/generated/autolinking/autolinking.json   # after step 3
          "version": "5.10.1",
$ npx react-native config | grep '"version": "5'
          "version": "5.11.0",
MANDATORY Reproducer

https://github.com/YevheniiKotyrlo/rn-autolinking-cache-bun-lock

Screenshots and Videos

No response

Langage dominant
C++
Étoiles
127k
Forks
25.4k
Merge moyen
2 j 1 h
PR mergées (30 j)
67

Préparer son environnement

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de react/react-native

Toutes les issues de react/react-native

Issues similaires

Plus d'issues C++

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.