I’m trying to track down a memory leak in some code which runs on an ESP 01. I was thrilled to see some static analysis tools had been included, however I’m having some trouble with them.
If I “Inspect” my project for memory, I get a nice little list. However, if I flip the switch for “Check Code”, it goes about half way and then dies with Bad JSON.
After reading some github issues, I brought up a pio terminal and tried:
pio check --skip-packages
–skip-packages, as it chokes on some ESP core file without it and I saw in another forum post that this would help it proceed, which it does.
That call, over five to ten minutes, proceeds to run my 32gb system almost completely out of ram (icons stop drawing, etc). It did show a few low-severity issues before causing me to be logged out of Windows! I don’t think it made it very far though.
I’m able to build and flash my ESP01 with this project fine. Any thoughts on how to get the GUI to finish “Inspecting” in a reasonable amount of time?
Thanks!
platformio.ini:
[env:esp01]
platform = espressif8266
board = esp01
framework = arduino
lib_deps =
adafruit/Adafruit NeoPixel@^1.7.0
painlessmesh/painlessMesh@^1.4.5
yiannisbourkelis/Uptime Library@^1.0.0
monitor_port = COM4
monitor_speed = 115200
build_type = debug
monitor_filters = esp8266_exception_decoder
check_tool = cppcheck
About:
Version: 1.51.1 (user setup)
Commit: e5a624b788d92b8d34d1392e4c4d9789406efe8f
Date: 2020-11-10T23:34:32.027Z
Electron: 9.3.3
Chrome: 83.0.4103.122
Node.js: 12.14.1
V8: 8.3.110.13-electron.0
OS: Windows_NT x64 10.0.19041