fusion-flap / flap

Fusion Library of Analysis Programs
MIT License
11 stars 5 forks source link

data_object get_data error handling #48

Closed thelampire closed 4 years ago

thelampire commented 5 years ago

The data object get_data function cannot be debugged. It is nested within a try...except frame and whenever an error occurs within, the only this data_object does is that it is trying to call the f function without a data_source. This shouldn't be nested in there.

The solution: TypeError --> Keyerror (Line 3772, thelampire-patch-02 rev. 31)

sandorzoletnik commented 5 years ago

I don't understand. This was done to enable calling data source get_data functions which do not have a data_source input. I think the function throws a TypeError when it does not have a data_source argument. Is this not right? It will not throw a KeyError

sandorzoletnik commented 4 years ago

Improved error handling, it will call the function without data_source only if the data_source keyword was the problem.