-
Notifications
You must be signed in to change notification settings - Fork 7.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
esp_https_ota API might be calling custom http_client_init_cb after performing the request instead of before doing so. (IDFGH-8080) #9581
Comments
Hello @rommo911 , |
hello @hmalpani , |
@rommo911 Are you also using partial download feature with your example? |
@hmalpani nope not at the moment. |
@rommo911 Can you verify once if partial download is enabled or not? I tested with both the cases and header was not added only when partial download was enabled. |
@hmalpani actually sorry i was mistaken , the partial download was active indeed in my code. i will test again later today to disable it. |
…sp_http_client_perform()` instead of before. Closes #9581
* timer: propagate isr register failure Closes espressif#9651 * mcpwm: fix multiplication overflow in converting us to compare ticks Closes espressif#9648 * heap: remove misleading info about malloc being equivalent to heap_caps_malloc(p, MALLOC_CAP_8BIT) The actual memory allocated for malloc() depends on a lot of factors, see heap_caps_malloc_default() Closes espressif#7659 * esp-rom: fixed error in miniz header documention for tdefl_init Closes espressif#8435 * temperature_sensor: Fix issue that value is not accurate on ESP32-S3 * esp_https_ota: fix bug where `http_client_init_cb` is called after `esp_http_client_perform()` instead of before. Closes espressif#9581 * Tasmota changes * Fix linker error for C3 * Avoid bootloop if chip is unknown In case the PSIRAM chip is unknown, return an error and disable PSRAM instead of calling abort() and causing a bootloop * Support for xiaomi single core ESP32 * Fix linker error for rom_temp_to_power * fix linker error r_lld_ext_adv_dynamic_aux_pti_process * Hide download percent when not interactive * list(APPEND esptool_elf2image_args --dont-append-digest) * Use native Apple ARM toolchains * add package.json * add submodules * 8575d75 Co-authored-by: morris <[email protected]> Co-authored-by: Marius Vikhammer <[email protected]> Co-authored-by: Cao Sen Miao <[email protected]> Co-authored-by: Harshit Malpani <[email protected]> Co-authored-by: Mahavir Jain <[email protected]>
* timer: propagate isr register failure Closes espressif#9651 * mcpwm: fix multiplication overflow in converting us to compare ticks Closes espressif#9648 * heap: remove misleading info about malloc being equivalent to heap_caps_malloc(p, MALLOC_CAP_8BIT) The actual memory allocated for malloc() depends on a lot of factors, see heap_caps_malloc_default() Closes espressif#7659 * esp-rom: fixed error in miniz header documention for tdefl_init Closes espressif#8435 * temperature_sensor: Fix issue that value is not accurate on ESP32-S3 * esp_https_ota: fix bug where `http_client_init_cb` is called after `esp_http_client_perform()` instead of before. Closes espressif#9581 * Tasmota changes * Fix linker error for C3 * Avoid bootloop if chip is unknown In case the PSIRAM chip is unknown, return an error and disable PSRAM instead of calling abort() and causing a bootloop * Support for xiaomi single core ESP32 * Fix linker error for rom_temp_to_power * fix linker error r_lld_ext_adv_dynamic_aux_pti_process * Hide download percent when not interactive * list(APPEND esptool_elf2image_args --dont-append-digest) * Use native Apple ARM toolchains * add package.json * add submodules * 8575d75 * Arduino tinyusb v0.14.0 stripped Co-authored-by: morris <[email protected]> Co-authored-by: Marius Vikhammer <[email protected]> Co-authored-by: Cao Sen Miao <[email protected]> Co-authored-by: Harshit Malpani <[email protected]> Co-authored-by: Mahavir Jain <[email protected]>
…sp_http_client_perform()` instead of before. Closes #9581
Environment
git describe --tags
to find it): v4.4.1Problem Description
In the esp_https_ota_config_t there is a section for adding an http_client_init_cb to add custom headers to the http request.
i notices it did not work for me to add my custom authorization token when asking for a firmware file from my server
the i checked esp_https_ota.c and found out that the calling of this callback (http_client_init_cb ) is done after
esp_http_client_perform()
, this means the custom headers are added after the http is perfomred. is this normal ? i moved the line of thehttp_client_init_cb
calling right befor theesp_http_client_perform()
and afteresp_http_client_init()
and things worked fine for me.Expected Behavior
calling the
http_client_init_cb
beforeesp_http_client_perform()
in the esp_https_ota.cActual Behavior
the
http_client_init_cb
called afteresp_http_client_perform()
in the esp_https_ota.cSteps to reproduce
step 1: typical use of esp_https_ota api with adding (http_client_init_cb ) to the handle.
sdkconfig.txt
The text was updated successfully, but these errors were encountered: