syrusakbary / promise

Ultra-performant Promise implementation in Python
MIT License
362 stars 76 forks source link

DataLoader swallows original exceptions #74

Open sebastiandev opened 5 years ago

sebastiandev commented 5 years ago

When executing the batch_load_fn if an error occurs, the exception been raised is not the original one, but an Exception which references the original one in its message, like:

Data loader batch_load_fn function raised an Exception: DomainError("Invalid id 'test' in id ",)

My custom exception is a DomainError but it gets lost and re-raised as an Exception

sebastiandev commented 5 years ago

@syrusakbary is anyone maintaining this library? this error is pretty urgent in order to make this production ready.

syrusakbary commented 4 years ago

@sebastiandev if you would like, I'd welcome a PR :)