Git Product home page Git Product logo

Comments (7)

kayhayen avatar kayhayen commented on September 24, 2024

Can you use --force-stdout and --force-stderr to capture potential errors. I also forgot, but I believe they default to %NULL% with disabled console, and not %NONE% but if they do, not all code works with pythonw.exe which is the equivalent.

from nuitka.

GelzoneCC avatar GelzoneCC commented on September 24, 2024

The output of --force-stderr, it shows:
"\\srv\folder\python_exe
CMD.EXE was started with the above path as the current directory. UNC paths are not supported.
Defaulting to Windows directory."

But the error message is English version. I am Chinese user, so the real message is
run_on_svr_issue
Sorry for hiding the real path for confidentiality.

The output of --force-stdout was nothing, no message shows.

from nuitka.

GelzoneCC avatar GelzoneCC commented on September 24, 2024

But as I mentioned before, aftre I removed the --disable-console, even though it showed the error message I just gave, the .exe still worked well.

from nuitka.

kayhayen avatar kayhayen commented on September 24, 2024

Well, it probably requires a console for some reason, and if you don't disable it, there will already be one. If you dive deep and figure out, what their issue is with not having a console, great. But it's not an issue with Nuitka, more Windows and Selenium I guess. It cannot make software work in contexts, where it is not already working. And pythonw.exe seems unsupported by Selenium in network paths.

from nuitka.

kayhayen avatar kayhayen commented on September 24, 2024

You can still try the current development version and --windows-console=attach, but I don't think it will make a difference if you launch it via Explorer. I know it's not practical, but if you used Selenium and its downloaded Browsers from the network paths, you probably would have the same issue of being unable to use pythonw.exe and not python.exe. If however, you succeed in that, there would be something to debug in Nuitka.

One thing that I have done in the past is to remove UNC paths during compilation, if possible. From there, I remember it is possible to iterate the drives and find a mount point. That is the same, but of course only if it exists, and if it doesn't, then you are still lost. Nuitka creates short paths for __file__, and applying those conversions would be great for both compile time and run time.

I remember spending some quality time on this. A general solution is not easy, though, but I assume even partial ones will be helpful.

That would mitigate the issue. Of course, the real fix is to make all Python software work with UNC paths, but we can only dream of that.

from nuitka.

GelzoneCC avatar GelzoneCC commented on September 24, 2024

Yes, I agree with you that it seems it's not the Nuitka issue because the .exe only can't run on network path with --disable-console. Maybe it needs a console to run well on the network path.
Anyway, the issue is not a big impact on the crawler tool, just sacrificing a little user experience.

Furthermore, I think this may not be my last crawler tool, so I will keep spending time figuring it out.
I will try --windows-console=attach you mentioned and find the way toward the selenium or webdriver-manager package. Maybe the answer is there.

Thank for your reply.

from nuitka.

kayhayen avatar kayhayen commented on September 24, 2024

Ok, seems we are giving up for now.

from nuitka.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.