pablo-s / passes

Manage your digital passes
GNU General Public License v3.0
66 stars 16 forks source link

'File is not a pass' on Pinephone (arm64) #29

Closed joancipria closed 1 year ago

joancipria commented 1 year ago

Hi! I've installed the app on my Pinephone (ARM 64) from Flathub. I wanted to import a .pkpass file previously downloaded from renfe.com (the Spanish national train service). But, the app fails to import and shows the "File is not a pass" message. I've also tried installing the app via AUR passes-git but got the same result. However, I've tried from my desktop computer (via Flathub), and the app correctly imports the file and shows all details.

Moreover, I've tried to generate a sample .pkpass from passsource.com, and the app correctly imports it from my Pinephone.

Therefore, something strange happens when importing Renfe .pkpass files on the Pinephone. ¿How can I debug this issue?

Thanks.

pablo-s commented 1 year ago

Hi @joancipria!

That error means that the imported file is not a zip file, or it is but it does not contain the file pass.json. This logic is in method create of class PassFactory.

The truth is that right now I cannot find a reason why this may fail on different architectures.

Have you tried running the app from command line?

flatpak run me.sanchezrodriguez.passes

Is there any error?

pablo-s commented 1 year ago

I would be happy to investigate further if you do not mind sending the file to me. PKPass files are zip files so it is possible to decompress them and edit/change personal information.

joancipria commented 1 year ago

Thanks for the respone @pablo-s. I've tried executing it from the terminal via flatpak and native AUR. In both cases, there's no output.

The file looks like a zip file, and there is a pass.json file inside. I would be glad to send it to you privately.

pablo-s commented 1 year ago

@joancipria Great! If you want you can send it to me to pablo@sanchezrodriguez.me.

joancipria commented 1 year ago

@joancipria Great! If you want you can send it to me to pablo@sanchezrodriguez.me.

Sent!

pablo-s commented 1 year ago

Thanks @joancipria !

I have already imported the file on my devices... and I have to say that I was not able to reproduce your issue. I have a laptop and a Pinephone Pro. In both devices I could import the pass using the Flathub version of Passes.

How are you transferring the pass to your phone? Can you check if the file got corrupted? Perhaps you can run md5sum on the pass on both devices.

joancipria commented 1 year ago

Thanks for testing it, @pablo-s. You are right. I've downloaded the file via wget + provided URL by Renfe, and, somehow, the file changes and can't be imported. Downloading it via the browser fixes the issue.

Sorry for my fault! And thank you so much for the support.

pablo-s commented 1 year ago

No problem! And feel free to give me any suggestion you have about Passes!