[Gambas-bugtracker] Bug #2766: HttpClient: URL using bad/illegal format or missing URL

bugtracker at gambaswiki.org bugtracker at gambaswiki.org
Thu Jul 13 23:30:10 CEST 2023


http://gambaswiki.org/bugtracker/edit?object=BUG.2766&from=L21haW4-

Omar MORENO reported a new bug.

Summary
-------

HttpClient: URL using bad/illegal format or missing URL

Type             : Bug
Priority         : Medium
Gambas version   : 3.18
Product          : Networking components


Description
-----------

Hello.

I am using the HttpClient class (gb.net.curl)
And it works fine to download APIS (JSON), but now I'm testing with the online api: https://fakestoreapi.com

I can download all categories fine:

electronics
jewelery
men's clothing
women's clothing

I can download the products from the first two categories (electronics, jewelery), but when I try the last two, HttpClient throws an error:

URL using bad/illegal format or missing URL

When I test with chrome browser using the URL:

https://fakestoreapi.com/products/category/women's clothing?limit=10

Works correctly.

Can you check if the class can handle white space and special characters in the URL?

Thank you for your possible responses.


System information
------------------

[System]
Gambas=3.18.3
OperatingSystem=Linux
Distribution=Ubuntu 22.04.2 LTS
Kernel=5.19.0-46-generic
Architecture=x86_64
Cores=8
Memory=13894M
Language=es_ES.UTF-8
Desktop=UBUNTU
DesktopResolution=96
DesktopScale=8
WidgetTheme=yaru
Font=Ubuntu,11

[Programs]
gcc=gcc (Ubuntu 11.3.0-1ubuntu1~22.04.1) 11.3.0

[Libraries]
Cairo=libcairo.so.2.11600.0
Curl=libcurl.so.4.7.0
DBus=libdbus-1.so.3.19.13
GDK2=libgdk-x11-2.0.so.0.2400.33
GDK3=libgdk-3.so.0.2404.29
GStreamer=libgstreamer-1.0.so.0.2003.0
GTK+2=libgtk-x11-2.0.so.0.2400.33
GTK+3=libgtk-3.so.0.2404.29
OpenGL=libGL.so.1.7.0
Poppler=libpoppler.so.118.0.0
QT5=libQt5Core.so.5.15.3
RSvg=librsvg-2.so.2.48.0
SDL=libSDL2-2.0.so.0.18.2
SQLite 3=libsqlite3.so.0.8.6

[Environment]
DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/1000/bus
DESKTOP_SESSION=ubuntu
DISPLAY=:0
GB_GUI=gb.gtk3
GDMSESSION=ubuntu
GIO_LAUNCHED_DESKTOP_FILE=/usr/share/applications/gambas3.desktop
GIO_LAUNCHED_DESKTOP_FILE_PID=2639
GJS_DEBUG_OUTPUT=stderr
GJS_DEBUG_TOPICS=JS ERROR;JS LOG
GNOME_DESKTOP_SESSION_ID=this-is-deprecated
GNOME_SETUP_DISPLAY=:1
GNOME_SHELL_SESSION_MODE=ubuntu
GTK_MODULES=gail:atk-bridge
HOME=<home>
IM_CONFIG_PHASE=1
INVOCATION_ID=7ad6ba89b42c4e83b64c6994caf8b6c0
JOURNAL_STREAM=8:26947
LANG=es_ES.UTF-8
LANGUAGE=es_ES.UTF-8
LC_ADDRESS=es_PA.UTF-8
LC_ALL=es_ES.UTF-8
LC_IDENTIFICATION=es_PA.UTF-8
LC_MEASUREMENT=es_PA.UTF-8
LC_MONETARY=es_PA.UTF-8
LC_NAME=es_PA.UTF-8
LC_NUMERIC=es_PA.UTF-8
LC_PAPER=es_PA.UTF-8
LC_TELEPHONE=es_PA.UTF-8
LC_TIME=es_PA.UTF-8
LOGNAME=<user>
MANAGERPID=1556
PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/snap/bin
PWD=<home>
QT_ACCESSIBILITY=1
QT_IM_MODULE=ibus
QT_LOGGING_RULES=*.debug=false
SESSION_MANAGER=local/<hostname>:@/tmp/.ICE-unix/1738,unix/<hostname>:/tmp/.ICE-unix/1738
SHELL=/bin/bash
SHLVL=0
SSH_AGENT_LAUNCHER=gnome-keyring
SSH_AUTH_SOCK=/run/user/1000/keyring/ssh
SYSTEMD_EXEC_PID=1765
TZ=:/etc/localtime
USER=<user>
USERNAME=<user>
WAYLAND_DISPLAY=wayland-0
XAUTHORITY=/run/user/1000/.mutter-Xwaylandauth.0OL571
XDG_CONFIG_DIRS=/etc/xdg/xdg-ubuntu:/etc/xdg
XDG_CURRENT_DESKTOP=ubuntu:GNOME
XDG_DATA_DIRS=/usr/share/ubuntu:/usr/local/share/:/usr/share/:/var/lib/snapd/desktop
XDG_MENU_PREFIX=gnome-
XDG_RUNTIME_DIR=/run/user/1000
XDG_SESSION_CLASS=user
XDG_SESSION_DESKTOP=ubuntu
XDG_SESSION_TYPE=wayland
XMODIFIERS=@im=ibus
_=/usr/bin/gnome-session




More information about the Bugtracker mailing list