Snappy error on Mac OS Ventura: "no native library is found for os.name=Mac and os.arch=aarch64"

Ouverte
#573 0 commentaires 1 réaction 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Évaluation

Difficulté
4/5
Temps estimé
3-5 jours
Accessibilité débutants
35/100
Type d'issue
Bug
Clarté
Plutôt claire
Activité
À l'abandon
Stack technique
java
Domaine
backend

Piste de recherche

Start by reading SnappyLoader.findNativeLibrary in SnappyLoader.java and checking how it maps Mac and aarch64 to the native library path; the report says the jar contains the dylib under org/xerial/snappy/native/Mac/aarch64. Reproduce with the reported Java 17 and Apple Silicon setup if available, then check the native-loading tests. Done when the bundled library is found and loaded for this platform.

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

Description

Hello snappy team,

running an application on Mac M1 Pro with Ventura 13.6.6, Java Temurin-17.0.9+9 and Snappy 1.1.10.5, I keep getting the following error:

Caused by: java.lang.NoClassDefFoundError: Could not initialize class org.xerial.snappy.Snappy
	at org.apache.parquet.hadoop.DirectCodecFactory$SnappyCompressor.compress(DirectCodecFactory.java:291)
...
Caused by: java.lang.ExceptionInInitializerError: Exception org.xerial.snappy.SnappyError: no native library is found for os.name=Mac and os.arch=aarch64
	at org.xerial.snappy.SnappyLoader.findNativeLibrary(SnappyLoader.java:331)
	at org.xerial.snappy.SnappyLoader.loadNativeLibrary(SnappyLoader.java:171)
	at org.xerial.snappy.SnappyLoader.load(SnappyLoader.java:152)
	at org.xerial.snappy.Snappy.<clinit>(Snappy.java:47)

Snappy is brought in here as a transitive dependency via Apache parque-hadoop 1.10.1.
I have already extracted the Snappy jar and verified that it contains the file libsnappyjava.dylib under org/xerial/snappy/native/Mac/aarch64.

Is it a known issue? Any idea how to fix this? Thanks.

Langage dominant
Java
Étoiles
1.1k
Forks
261
Merge moyen
2 min
PR mergées (30 j)
2

Préparer son environnement

Ce projet ne fournit ni conteneur de développement, ni Dockerfile, ni guide de contribution : l'installation est à votre charge. Commencez par son README, et consultez notre guide de la première contribution pour les étapes générales.

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 xerial/snappy-java

Toutes les issues de xerial/snappy-java

Issues similaires

Plus d'issues Java

Recevez les nouvelles issues par e-mail

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