[GH-ISSUE #1229] WiFiManager.h: No such file or directory / Platform.io #1049

Open
opened 2026-02-28 01:28:17 +03:00 by kerem · 19 comments
Owner

Originally created by @entrusc on GitHub (Mar 19, 2021).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1229

Basic Infos

Hardware

WiFimanager Branch/Release: 0.16.0

Esp8266/Esp32:

Hardware: ESP32

Core Version: 2.4.0, staging

Description

I don't know if I'm doing something wrong, but I am unable to use the WifiManager with esp32dev board using Platformio. I am using the following platformio.ini

[env:esp32dev]
platform = espressif32
board = esp32dev
framework = arduino
monitor_speed = 115200
upload_speed = 921600
lib_deps = 
	Button2@1.0.0
	bodmer/TFT_eSPI@^2.3.59
	tzapu/WiFiManager^0.16.0

and I get the following error message:

[...]
src/main.cpp:6:25: fatal error: WiFiManager.h: No such file or directory

*********************************************************************
* Looking for WiFiManager.h dependency? Check our library registry!
*
* CLI  > platformio lib search "header:WiFiManager.h"
* Web  > https://platformio.org/lib/search?query=header:WiFiManager.h
*
********************************************************************

I don't know if this is really a bug with this library, but I'm unable to find a solution for that. Any help would be appreciated. Thanks!

Originally created by @entrusc on GitHub (Mar 19, 2021). Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1229 ### Basic Infos #### Hardware WiFimanager Branch/Release: 0.16.0 Esp8266/Esp32: Hardware: ESP32 Core Version: 2.4.0, staging ### Description I don't know if I'm doing something wrong, but I am unable to use the WifiManager with esp32dev board using Platformio. I am using the following platformio.ini ``` [env:esp32dev] platform = espressif32 board = esp32dev framework = arduino monitor_speed = 115200 upload_speed = 921600 lib_deps = Button2@1.0.0 bodmer/TFT_eSPI@^2.3.59 tzapu/WiFiManager^0.16.0 ``` and I get the following error message: ``` [...] src/main.cpp:6:25: fatal error: WiFiManager.h: No such file or directory ********************************************************************* * Looking for WiFiManager.h dependency? Check our library registry! * * CLI > platformio lib search "header:WiFiManager.h" * Web > https://platformio.org/lib/search?query=header:WiFiManager.h * ******************************************************************** ``` I don't know if this is really a bug with this library, but I'm unable to find a solution for that. Any help would be appreciated. Thanks!
Author
Owner

@EgHubs commented on GitHub (Apr 1, 2021):

I never used it but maybe this will help.

<!-- gh-comment-id:811571241 --> @EgHubs commented on GitHub (Apr 1, 2021): I never used it but maybe [this](https://github.com/tzapu/WiFiManager#install-using-platformio) will help.
Author
Owner

@tablatronix commented on GitHub (Apr 1, 2021):

I updated that page, thanks, master is now development
This should works, maybe a problem with pio lib manager, or pio env, it should auto install deps

<!-- gh-comment-id:811605373 --> @tablatronix commented on GitHub (Apr 1, 2021): I updated that page, thanks, master is now development This should works, maybe a problem with pio lib manager, or pio env, it should auto install deps
Author
Owner

@shellster commented on GitHub (Jun 2, 2021):

I am also experiencing this issue. I had to manually download and include WiFiManager.h and strings_en.h from master in my project before I could get it to compile.

<!-- gh-comment-id:852630053 --> @shellster commented on GitHub (Jun 2, 2021): I am also experiencing this issue. I had to manually download and include `WiFiManager.h` and `strings_en.h` from master in my project before I could get it to compile.
Author
Owner

@tablatronix commented on GitHub (Jun 2, 2021):

Even if you include wifimanager.h alone? Hmm

<!-- gh-comment-id:852631586 --> @tablatronix commented on GitHub (Jun 2, 2021): Even if you include wifimanager.h alone? Hmm
Author
Owner

@shellster commented on GitHub (Jun 3, 2021):

Yeah. I started with just: #include <WifiManager.h> (besides Arduino.h) and adding this line in my platformio.ini:
lib_deps = tzapu/WiFiManager@^0.16.0. When that didn't work, I went and tried to manually install the library in platformio. It still didn't work. I don't think it is too relevant, but I'm using an old NodeMCU with an ESP8266MOD chip. It seems to work just fine when I included local file copies.

<!-- gh-comment-id:853535942 --> @shellster commented on GitHub (Jun 3, 2021): Yeah. I started with just: `#include <WifiManager.h>` (besides Arduino.h) and adding this line in my platformio.ini: `lib_deps = tzapu/WiFiManager@^0.16.0`. When that didn't work, I went and tried to manually install the library in platformio. It still didn't work. I don't think it is too relevant, but I'm using an old NodeMCU with an ESP8266MOD chip. It seems to work just fine when I included local file copies.
Author
Owner

@noweare1 commented on GitHub (Jun 9, 2021):

I am getting the error on PIO .pio/libdeps/esp32dev/WiFiManager/WiFiManager.h:16:25: fatal error: ESP8266WiFi.h: No such file or directory.

After installing the library using platformio I compare the github wifimanager.h file with the wifmanager.h file downloaded into my project by platformio and they are different. Have not tried just a manual install. The github wifimanager.h is the one that is correct don't know how pio is grabbing a different file. The fun never ends.

<!-- gh-comment-id:857796242 --> @noweare1 commented on GitHub (Jun 9, 2021): I am getting the error on PIO .pio/libdeps/esp32dev/WiFiManager/WiFiManager.h:16:25: fatal error: ESP8266WiFi.h: No such file or directory. After installing the library using platformio I compare the github wifimanager.h file with the wifmanager.h file downloaded into my project by platformio and they are different. Have not tried just a manual install. The github wifimanager.h is the one that is correct don't know how pio is grabbing a different file. The fun never ends.
Author
Owner

@tablatronix commented on GitHub (Jun 9, 2021):

Sounds like it doesn't know its esp32, Sounds like a platform issue

<!-- gh-comment-id:857857049 --> @tablatronix commented on GitHub (Jun 9, 2021): Sounds like it doesn't know its esp32, Sounds like a platform issue
Author
Owner

@noweare1 commented on GitHub (Jun 9, 2021):

It is a platform issue. I cloned the repo to my project added #include in main and it all worked.

<!-- gh-comment-id:857906252 --> @noweare1 commented on GitHub (Jun 9, 2021): It is a platform issue. I cloned the repo to my project added #include in main and it all worked.
Author
Owner

@shellster commented on GitHub (Jun 16, 2021):

My problem turned out to be a typo:
#include <WifiManager.h> #Should be: <WiFiManager.h>

Not sure where the typo came from, if I just fat fingered it or if it was incorrectly mentioned in some documentation somewhere. Also uncertain why it worked when I cloned from the repo directly. So to be explicit:

lib_deps = 
    WiFiManager

And in my code:

#include <WiFiManager.h>

<!-- gh-comment-id:862804140 --> @shellster commented on GitHub (Jun 16, 2021): My problem turned out to be a typo: `#include <WifiManager.h> #Should be: <WiFiManager.h>` Not sure where the typo came from, if I just fat fingered it or if it was incorrectly mentioned in some documentation somewhere. Also uncertain why it worked when I cloned from the repo directly. So to be explicit: lib_deps = WiFiManager And in my code: `#include <WiFiManager.h>`
Author
Owner

@abodydz commented on GitHub (Jul 7, 2022):

Same issue but nothing works ):

<!-- gh-comment-id:1177850866 --> @abodydz commented on GitHub (Jul 7, 2022): Same issue but nothing works ):
Author
Owner

@jenschr commented on GitHub (Nov 30, 2022):

@tablatronix I can confirm this still happens. I'm using PlatformIO Core 6.1.5m Home 3.4.3 with an "adafruit_feather_esp32s3_nopsram" device (https://www.adafruit.com/product/5323). Trying to run the Basic.ino example. The full error messages are below, but briefly said - the IDE is unable to find the files ESP8266WiFi.h, ESP8266WebServer.h and user_interface.h. Is this ineed an unresolved dependency to this repo? https://github.com/esp8266/Arduino/tree/master/libraries/ESP8266WebServer

[{
"resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h",
"owner": "C/C++",
"code": "1696",
"severity": 8,
"message": "cannot open source file "ESP8266WiFi.h"",
"source": "C/C++",
"startLineNumber": 16,
"startColumn": 1,
"endLineNumber": 16,
"endColumn": 25
}]
[{
"resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h",
"owner": "C/C++",
"code": "1696",
"severity": 8,
"message": "cannot open source file "ESP8266WebServer.h"",
"source": "C/C++",
"startLineNumber": 17,
"startColumn": 1,
"endLineNumber": 17,
"endColumn": 30
}]
[{
"resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h",
"owner": "C/C++",
"code": "1696",
"severity": 8,
"message": "cannot open source file "user_interface.h"",
"source": "C/C++",
"startLineNumber": 22,
"startColumn": 3,
"endLineNumber": 22,
"endColumn": 30
}]

<!-- gh-comment-id:1332321957 --> @jenschr commented on GitHub (Nov 30, 2022): @tablatronix I can confirm this still happens. I'm using PlatformIO Core 6.1.5m Home 3.4.3 with an "adafruit_feather_esp32s3_nopsram" device (https://www.adafruit.com/product/5323). Trying to run the Basic.ino example. The full error messages are below, but briefly said - the IDE is unable to find the files ESP8266WiFi.h, ESP8266WebServer.h and user_interface.h. Is this ineed an unresolved dependency to this repo? https://github.com/esp8266/Arduino/tree/master/libraries/ESP8266WebServer [{ "resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h", "owner": "C/C++", "code": "1696", "severity": 8, "message": "cannot open source file \"ESP8266WiFi.h\"", "source": "C/C++", "startLineNumber": 16, "startColumn": 1, "endLineNumber": 16, "endColumn": 25 }] [{ "resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h", "owner": "C/C++", "code": "1696", "severity": 8, "message": "cannot open source file \"ESP8266WebServer.h\"", "source": "C/C++", "startLineNumber": 17, "startColumn": 1, "endLineNumber": 17, "endColumn": 30 }] [{ "resource": "/Users/jensa/Documents/PlatformIO/Projects/RGBWifiMan/.pio/libdeps/adafruit_feather_esp32s3_nopsram/WiFiManager/WiFiManager.h", "owner": "C/C++", "code": "1696", "severity": 8, "message": "cannot open source file \"user_interface.h\"", "source": "C/C++", "startLineNumber": 22, "startColumn": 3, "endLineNumber": 22, "endColumn": 30 }]
Author
Owner

@jenschr commented on GitHub (Nov 30, 2022):

@tablatronix if you can point me where to look (as in where the library containing ESP8266WiFi.h is from) I'll dig into this and produce a PR.

<!-- gh-comment-id:1332326763 --> @jenschr commented on GitHub (Nov 30, 2022): @tablatronix if you can point me where to look (as in where the library containing ESP8266WiFi.h is from) I'll dig into this and produce a PR.
Author
Owner

@tablatronix commented on GitHub (Nov 30, 2022):

I use 6.1.5, your enviroment or platform has an issue I would assume. You are using esp32 not esp8266, what in your platformio.ini ?

<!-- gh-comment-id:1332332469 --> @tablatronix commented on GitHub (Nov 30, 2022): I use 6.1.5, your enviroment or platform has an issue I would assume. You are using esp32 not esp8266, what in your platformio.ini ?
Author
Owner

@jenschr commented on GitHub (Nov 30, 2022):

This is in my ini and here you can see the problem:
[env:adafruit_feather_esp32s3_nopsram]
platform = espressif32
board = adafruit_feather_esp32s3_nopsram
framework = arduino
lib_deps = tzapu/WiFiManager@^0.16.0

For some reason, I have a two year old version as the only option to install. If I look at WiFiManager in the PIO Library browser, the 0.16.0 version is the most recent I can install. I can see from the changelog that this obviously is a very old version, but the version dropdown in the PlatformIO Libraries listing only allows me to select versions 0.15.0 and 0.16.0. That's the issue.

My PlatformIO is fully updated and so are all dependencies that I know of. What can cause this?

<!-- gh-comment-id:1332351198 --> @jenschr commented on GitHub (Nov 30, 2022): This is in my ini and here you can see the problem: [env:adafruit_feather_esp32s3_nopsram] platform = espressif32 board = adafruit_feather_esp32s3_nopsram framework = arduino lib_deps = tzapu/WiFiManager@^0.16.0 For some reason, I have a two year old version as the only option to install. If I look at WiFiManager in the PIO Library browser, the 0.16.0 version is the most recent I can install. I can see from the changelog that this obviously is a very old version, but the version dropdown in the PlatformIO Libraries listing only allows me to select versions 0.15.0 and 0.16.0. That's the issue. My PlatformIO is fully updated and so are all dependencies that I know of. What can cause this?
Author
Owner

@tablatronix commented on GitHub (Nov 30, 2022):

WiFiManager@^0.16.0 does not support esp32, you need to use git master or one of the beta releases

<!-- gh-comment-id:1332380336 --> @tablatronix commented on GitHub (Nov 30, 2022): WiFiManager@^0.16.0 does not support esp32, you need to use git master or one of the beta releases
Author
Owner

@tablatronix commented on GitHub (Nov 30, 2022):

lib_deps =
https://github.com/tzapu/WiFiManager.git

<!-- gh-comment-id:1332391520 --> @tablatronix commented on GitHub (Nov 30, 2022): lib_deps = https://github.com/tzapu/WiFiManager.git
Author
Owner

@jenschr commented on GitHub (Dec 1, 2022):

That's great since it resolves my immediate issue, but it won't help anyone using the standard Library handling in PlatfromIO and it'll generate lots of unneeded issues here on Github. What would be required to make this work with the PlatformIO library manager? Is there aything I can help to make that "just work"?

<!-- gh-comment-id:1332937126 --> @jenschr commented on GitHub (Dec 1, 2022): That's great since it resolves my immediate issue, but it won't help anyone using the standard Library handling in PlatfromIO and it'll generate lots of unneeded issues here on Github. What would be required to make this work with the PlatformIO library manager? Is there aything I can help to make that "just work"?
Author
Owner

@jenschr commented on GitHub (Dec 1, 2022):

According to the documentation (https://docs.platformio.org/en/latest/librarymanager/creating.html#publishing), one needs to use the "pio pkg publish" command in PlatformIO for every release to publish. According to https://registry.platformio.org/libraries/tzapu/WiFiManager this was last done two years ago. I think that's the root issue here.

<!-- gh-comment-id:1332951621 --> @jenschr commented on GitHub (Dec 1, 2022): According to the documentation (https://docs.platformio.org/en/latest/librarymanager/creating.html#publishing), one needs to use the "pio pkg publish" command in PlatformIO for every release to publish. According to https://registry.platformio.org/libraries/tzapu/WiFiManager this was last done two years ago. I think that's the root issue here.
Author
Owner

@tablatronix commented on GitHub (Dec 1, 2022):

platformio library manager does not support beta releases

<!-- gh-comment-id:1333114658 --> @tablatronix commented on GitHub (Dec 1, 2022): platformio library manager does not support beta releases
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/WiFiManager#1049
No description provided.