Am 08.09.2023 um 01:21 schrieb Cottrell, Allin:
On Thu, Sep 7, 2023 at 6:11 AM Sven Schreiber
<sven.schreiber(a)fu-berlin.de> wrote:
Hopefully this situation is going to normalize again, but I wonder if
gretl could somehow detect that the server isn't really working. Perhaps
it would be enough to simply extend the message in gretl's error dialog.
Gretl gets data from sourceforge via the libcurl API (see
https://curl.se/libcurl/c/ ) and all the relevant code is in
lib/src/gretl_www.c in the git source tree. If anyone can see a way to
get a more informative error message in case such transactions go
wrong, that would be all to the good.
Actually, I believe that the error message is coming from gui/database.c
in the function populate_remote_func_list, line 4063. And since this
whole function appears to be only relevant in an online/internet
context, perhaps the error message could simply include an additional
hint like "(server unreachable?)".
OTOH, previously in that function there's a call to
list_remote_function_packages, and if there's an error from there, then
show_network_error is done. I guess this is what you meant when
referring to lib/src/gretl_www.c. So maybe the question is why there's
no error coming from there? For example, the called function
urlinfo_finalize sets the error to E_DATA if (u->datalen == 0), which
sounds relevant and OK, but still doesn't seem to trigger the error
handling.
But again, potentially there's an easy workaround just by providing a
hint to the user.
cheers
sven