Skip to content
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

Updater generating String error messages #8130

Closed
5 of 6 tasks
earlephilhower opened this issue Jun 16, 2021 · 3 comments · Fixed by #8131
Closed
5 of 6 tasks

Updater generating String error messages #8130

earlephilhower opened this issue Jun 16, 2021 · 3 comments · Fixed by #8131
Assignees
Milestone

Comments

@earlephilhower
Copy link
Collaborator

Basic Infos

  • This issue complies with the issue POLICY doc.
  • I have read the documentation at readthedocs and the issue is not addressed there.
  • I have tested that the issue is present in current master branch (aka latest git).
  • I have searched the issue tracker for a similar issue.
  • If there is a stack dump, I have decoded it.
  • I have filled out all fields below.

Platform

  • Hardware: [all]
  • Core Version: [3.0.0 + git master]
  • Development Env: [Arduino IDE|
  • Operating System: [all]

Settings in IDE

  • Module: [Wemos D1 mini r2]
  • Flash Mode: [dio]
  • Flash Size: [4MB]
  • lwip Variant: [v2 Lower Memory]
  • Reset Method: [ck|nodemcu]
  • Flash Frequency: [40Mhz]
  • CPU Frequency: [80Mhz|160MHz]
  • Upload Using: [SERIAL]
  • Upload Speed: [115200|other]

Problem Description

While debugging #8079 I am getting error messages from String. Need to figure out if this is a String problem, an Updater problem, or just a poorly worded debug message:

12:33:23.841 -> [HTTP-Client][begin] url: https://apps.95wd.com.cn/httpUpdate.ino.generic.bin
12:33:23.841 -> [HTTP-Client][begin] host: apps.95wd.com.cn port: 443 url: /httpUpdate.ino.generic.bin
12:33:23.841 -> [offending String op 134->165 ('x-ESP8266- ... 1662976
12:33:23.841 -> ')]
12:33:23.841 -> [offending String op 165->221 ('x-ESP8266- ... : 431296
12:33:23.841 -> ')]
12:33:23.841 -> [offending String op 221->251 ('x-ESP8266- ... 84e66870
12:33:23.874 -> ')]
12:33:23.874 -> [offending String op 251->294 ('x-ESP8266- ... 4194304
12:33:23.874 -> ')]
12:33:23.874 -> [offending String op 294->318 ('x-ESP8266- ... 38a443e)
12:33:23.874 -> ')]
12:33:23.874 -> [HTTP-Client][sendRequest] type: 'GET' redirCount: 0
12:33:23.874 -> [hostByName] request IP for: apps.95wd.com.cn
12:33:23.874 -> [hostByName] Host: apps.95wd.com.cn IP: 47.100.169.50
12:33:23.874 -> :ref 1

MCVE Sketch

See #8079

@earlephilhower earlephilhower added this to the 3.0.1 milestone Jun 16, 2021
@d-a-v
Copy link
Collaborator

d-a-v commented Jun 16, 2021

It's on us both #7908
edit: wording: "op" => "realloc" ?

@earlephilhower
Copy link
Collaborator Author

Yes, I will do a PR with a reword as well as having the Updater pre-allocate the Strings to avoid the warning in the 1st place. "offending String op xxx" doesn't mean much unless you go to the actual source line (where it is commented well!).

@earlephilhower
Copy link
Collaborator Author

There's not a good way to pre-allocate the String in the httpUpdate class w/o changing the HTTPClient API which I don' t think is a good thing for a 3.0.1 bugfix, so #8131 simply uses a more descriptive warning.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants