jczic / MicroWebSrv2

The last Micro Web Server for IoTs (MicroPython) or large servers (CPython), that supports WebSockets, routes, template engine and with really optimized architecture (mem allocations, async I/Os). Ready for ESP32, STM32 on Pyboard, Pycom's chipsets (WiPy, LoPy, ...). Robust, efficient and documented!
https://github.com/jczic/MicroWebSrv2
MIT License
662 stars 97 forks source link

WebRoute arguments convert any uppercase characters to lowercase #73

Open SouperMan3 opened 3 years ago

SouperMan3 commented 3 years ago

Using MicroWebSrv2 WebRoutes Arguments converts any Upper case characters to lower

Code Snipit:

@WebRoute(GET, "/capp///

////")
def RequestGetApp(microWebSrv2, request, args):
global lockout, errmax, filepre, useflash, clearsd, accespt, PIRactive, sdCleared
print("Getting config values")

store the return values in the globals

 ...
print(args['pre'])
filepre = args['pre']
...
request.Response.ReturnOk()

REPL output:

Getting config values
bird99
MWS2-DEBUG> From 10.0.0.8:62708 GET /capp/0.5/10/BIRD99/0/0/0/1 >> [200] OK
MWS2-DEBUG> From 10.0.0.8:62708 >> [200] OK