Code fails when there is no date from a certain time range. Add handling it for example by putting concat in the try-except block. Also consider the possibility to add a parameter to allow a user to decide if the code should or shouldn't fail if output is empty.
Code fails when there is no date from a certain time range. Add handling it for example by putting concat in the try-except block. Also consider the possibility to add a parameter to allow a user to decide if the code should or shouldn't fail if output is empty.