erikas-taroza / audiotags

Read and write audio metadata in Flutter. Supports multiple formats.
https://pub.dev/packages/audiotags
MIT License
9 stars 4 forks source link

Error parsing file with no tags #3

Closed sanihaq closed 1 year ago

sanihaq commented 1 year ago
[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: FfiException(RESULT_ERROR, ERR: This file does not have any tags., null)
#0      FlutterRustBridgeBase._transformRust2DartMessage
basic.dart:129
#1      FlutterRustBridgeBase.executeNormal.<anonymous closure>
basic.dart:70
<asynchronous suspension>
#2      AudioTags.read
audiotags.dart:9
<asynchronous suspension>
#3      _FilesListState.build.<anonymous closure>.<anonymous closure>
main.dart:123
<asynchronous suspension>

sample file in attachment (github doesn't allow mp3 file directly)

erikas-taroza commented 1 year ago

The error is intended, just not handled properly. If there are no tags, null will be returned. However, if there is another error (ex. wrong path), that will still be thrown.

Fixed in 04ebbe592dfeede7911771258c3f102940108122. Will publish to pub.dev soon.

sanihaq commented 1 year ago

not every image is getting parsed. it's there in file explorer view. is it an error??

erikas-taroza commented 1 year ago

not every image is getting parsed. it's there in file explorer view. is it an error??

Please create a new issue and include the file you are having problems with. I don't have any files with full metadata attached. audiotags reads the CoverFront image so the image is possibly located under a different name. I can improve the image support.

sanihaq commented 1 year ago

@erikas-taroza submitted new issue #4