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

NodeMCU-PyFlasher.exe (v5.0.0) Not Working on Windows 10 #78

Closed
Gosokan opened this issue Jun 9, 2021 · 32 comments
Closed

NodeMCU-PyFlasher.exe (v5.0.0) Not Working on Windows 10 #78

Gosokan opened this issue Jun 9, 2021 · 32 comments

Comments

@Gosokan
Copy link

Gosokan commented Jun 9, 2021

Currently using Windows 10 64-bit version 20H2 (OS Build 19042.867)
NodeMCU-PyFlasher.exe v5.0.0 does not display anything when this program is executed.

@starioni
Copy link

Same to me. running the .exe doesn't do anything

@rt400
Copy link

rt400 commented Jun 25, 2021

also same to me. running and closing after couple seconds.

@Fevax
Copy link

Fevax commented Sep 4, 2021

Same issue here

@HRC450
Copy link

HRC450 commented Sep 10, 2021

Same here

@exxoff
Copy link

exxoff commented Oct 21, 2021

Same. Process starts but stops immediately. v.4 x64 works.

@marcelstoer
Copy link
Owner

marcelstoer commented Oct 21, 2021

I can not reproduce this on either of the two Win10 systems I have available; one native, one on VirtualBox. That makes debugging - let alone fixing - this challenging.

Has one of you tried starting the .exe from the Windows "shell" to see if it reports any errors there?

@exxoff
Copy link

exxoff commented Oct 22, 2021

I tried to start it from command prompt, Administrator mode, but nothing. I can see that the process starts but it dies immediately. No output in the command window. Nothing in the event log.

I have tried it on two Windows 10 clients, one Enterprise and one Home edition but it behaves the same.

@marcelstoer
Copy link
Owner

marcelstoer commented Oct 22, 2021

I guess we'll have to do it the trial and error way then.

@exxoff could you please run both of the below binaries from the command prompt and by double clicking and report back, thanks.
https://transfer.sh/b2QFzG/NodeMCU-PyFlasher-with-version.exe
https://transfer.sh/Jz2nLQ/NodeMCU-PyFlasher-non-windowed.exe

@rt400
Copy link

rt400 commented Oct 23, 2021

@marcelstoer i try to run it but no output and not shown anything . Both in command and double click

@marcelstoer
Copy link
Owner

Did you also try the non-windowed version i.e. the behavior is the same for both .exes?

@exxoff
Copy link

exxoff commented Oct 29, 2021

@marcelstoer Nothing. I've tried both of them in Admin mode and not in Admin mode.

@marcelstoer
Copy link
Owner

Thanks! I'll keep digging and will report back.

@marcelstoer
Copy link
Owner

marcelstoer commented Nov 22, 2021

I'd appreciate if everybody following along here could spend 2min testing this version I built on yet another Windows system: https://transfer.sh/Ha0Wj8/NodeMCU-PyFlasher.exe (broken?) https://frightanic.com/misc/NodeMCU-PyFlasher.exe

Thanks for your feedback.

@rt400
Copy link

rt400 commented Nov 23, 2021

link not working

@marcelstoer
Copy link
Owner

marcelstoer commented Nov 23, 2021

Thanks for testing. Works for me but I now also published it to an alternative location (my own domain): https://frightanic.com/misc/NodeMCU-PyFlasher.exe.

@rt400
Copy link

rt400 commented Nov 23, 2021

still not working...

@Gosokan
Copy link
Author

Gosokan commented Nov 24, 2021

I also tried it. Still not working

@wkr1337
Copy link

wkr1337 commented Jan 16, 2022

Same issue, running the .exe doesn't do anything.
Links do not work.

@rt400
Copy link

rt400 commented Jan 18, 2022

@marcelstoer HI, i think i fix the problem by add locate to your code in Main.py

import locate
locale.setlocale(locale.LC_ALL,'C')

its work for me... plz check it and let me know

@marcelstoer
Copy link
Owner

@rt400 thanks, I can definitely try that. I for one won't notice any difference (as the app works just fine on my Windows).

How did you arrive at this conclusion? How did you debug this?

@marcelstoer
Copy link
Owner

@faizakbar18
Copy link

not working for me, still does not display anything

@rt400
Copy link

rt400 commented Jan 18, 2022

not working for me, still does not display anything

https://github.com/rt400/Tasmota-Config-Backup/raw/master/NodeMCU-PyFlasher.exe

Please try this and let me know if its work...

@rt400
Copy link

rt400 commented Jan 18, 2022

@rt400 thanks, I can definitely try that. I for one won't notice any difference (as the app works just fine on my Windows).

How did you arrive at this conclusion? How did you debug this?

Well I started playing with your code, I tried to create the BUILD myself but it did not work.
I finally tried running it through the CONSOLE and saw that it threw an error on something belonging to LOCATE. After an in-depth Google search I saw a solution that suggests adding these lines and this should solve the problem. By the way this is a known issue of wxPython and it has not yet been resolved.
I added these lines and created a new BUILD and it just opens and runs.
Where did you Add those lines ? cause what you send not open for me..

@marcelstoer
Copy link
Owner

marcelstoer commented Jan 18, 2022

@rt400 Thanks for the hints but your comment left me a bit puzzled.

In your earlier comment at #78 (comment) you said that you had run it through the console and it didn't give any hints? How apparently

it threw an error on something belonging to LOCATE

Btw, I used import locale not locate as the latter does not exist.

I asked my favorite search engine about this "locale + wxPython" issue and found a couple of discussions which I'm linking below for reference. Some of them cross-reference one another:

One other thing... above you both said

I tried to create the BUILD myself but it did not work.
...
I added these lines and created a new BUILD

I am assuming (since you uploaded a .exe) you eventually did manage to fix this.

Based on the wxPython forum threads I now have this patch (locally) and created https://frightanic.com/misc/NodeMCU-PyFlasher-with-ResetLocale.exe

--- a/Main.py	(revision 4899c16d4ec1c5c7794f39e7b6e97757db62d21e)
+++ b/Main.py	(date 1642536158773)
@@ -13,6 +13,10 @@
 import images as images
 from serial import SerialException
 from serial.tools import list_ports
+import locale
+
+
+locale.setlocale(locale.LC_ALL, 'C')
 
 __version__ = "5.0.0"
 __flash_help__ = '''
@@ -416,6 +420,7 @@
 # ----------------------------------------------------------------------------
 class App(wx.App, wx.lib.mixins.inspection.InspectionMixin):
     def OnInit(self):
+        self.ResetLocale()
         wx.SystemOptions.SetOption("mac.window-plain-transition", 1)
         self.SetAppName("NodeMCU PyFlasher")

@rt400
Copy link

rt400 commented Jan 18, 2022

@marcelstoer
in comment 78 I run only your builds file (.EXE) that you upload and one of them should open the console, also run it the EXE from cmd.

It's locale Not locate...bad typing sorry...

Now i download your build and its work... Finally !!!!
Greate Job ! I used alot with your pyFlasher.

@exxoff
Copy link

exxoff commented Jan 18, 2022

@marcelstoer I can confirm, it works for me too now.

Good work!

/ Per

@marcelstoer
Copy link
Owner

Thanks folks for sticking around and for providing valuable feedback.

tl;dr
Until I create a new release please use https://frightanic.com/misc/NodeMCU-PyFlasher-with-ResetLocale.exe

@canedje
Copy link

canedje commented Feb 20, 2022

This latest version "resetLocal" is working again. Thanks

@leowinterde
Copy link

Please a new release here on github for valid checksums, thanks.

@Ledzz
Copy link

Ledzz commented Apr 18, 2023

@marcelstoer hello! The latest release is not working for me, and also the link you provided is no longer exists. Anyway, thank you for your help!

@marcelstoer
Copy link
Owner

Thanks for heads up Artem. No idea why the patched file vanished from my server. It's fixed now.

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

No branches or pull requests

13 participants