Hello, many thanks for your kind support and great advice! I removed my old Python installation, downloaded a new one from python.org, installed it (and selected something like install paths in the install dialog), the paths were the same as you indicated. I used the command you provided to install Leo: py -m pip install leo, the install process was successful. And yes, I'm able to run it with py -m leo.core.runLeo command.
I created a shortcut with this command, Leo starts in Windows, the only drawback is that it opens a Terminal window which I don't need but this is a minor stuff. This is a Windows 10 system, I selected Run: Minimized in the shortcut properties. You made my day, Leo is an important tool for me. Thank you once again! Your help makes difference! On Monday, October 3, 2022 at 4:33:25 PM UTC+2 tbp1...@gmail.com wrote: > I'm puzzled by the long, complicated paths being reported. I've never > seen paths like that, at least not on Windows computers. A typical path on > my system would be > > C:\Users\tom\AppData\Roaming\Python\Python310\site-packages\leo\core > > None of those caches and strange numbers; none of that > *PythonSoftwareFoundation > stuff*. Now, if you were installing, say, the Anaconda python > environment, it might be different, but you haven't said. > > I'm also puzzled by your install message "Successfully built leo". A > normal install on Windows wouldn't build it. It would install a pre-built > package. > > You can find out where Leo is located in your file system like this: > > py -c "import leo; print(leo.__file__)" > > instead of "py", use whatever command you normally use to launch Python, > like "python3" or whatever it is. On my Windows system, the result is > > C:\Users\tom\AppData\Roaming\Python\Python310\site-packages\leo\__init__.py > > As for the enchant package, I wouldn't have thought that Leo wouldn't run > without it. Leo's code that tries to import it and to use it isn't active > if the enchant package can't be imported. In fact, it looks like the > enchant module exists but in a weird way. The message > > 'C:\Users\user\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\enchant\data\mingw64/lib/enchant-2\enchant_hunspell.dll': > > The specified module could not be found. > > has an impossible path (one with some forward slashes), and the fact that > it was built with the mingw compiler system is very non-standard for a > normal Windows install. It again makes me think that you installed using > some environment like Anaconda or some such, and the installer got confused > by a mixture of Windows and Linux paths. > > I suggest that you try installing Python and then Leo directly from a > Windows console - assuming that you are really on Windows, as indicated by > the path "C:\Users\user\AppData\Local\Packages". BTW, an ordinary Python > install gets located into "C:\Users\user\AppData\Local\Programs", again > showing that there is something non-standard about your install. Download > the Windows Python3 installer from python.org. Run it - don't use > Anaconda or any other pre-packaged environment for Python - just > double-click on its icon. When that is finished, run it and check to make > sure you are actually running the newly installed version. The install > should have installed a launcher that you can invoke by just typing "py" in > a Windows console windows (i.e., a cmd.exe window). > > Once that has been done, install Leo using pip. I suggest installing the > latest version. You should make sure you are using the pip program that > belongs to your newly-installed python, and the best way to do that is to > run it as a module: > > py -m pip install leo > > Again, if "py" isn't the right command to launch the newly installed > Python executable, type the right command name instead. > > You can check to see if the newly installed python package uses the > standard Windows system paths: > > py -c "import sys; print('\n'.join(sys.path))" > > You should see something much like this: > > C:\Users\tom\AppData\Local\Programs\Python\Python310\python310.zip > C:\Users\tom\AppData\Local\Programs\Python\Python310\DLLs > C:\Users\tom\AppData\Local\Programs\Python\Python310\lib > C:\Users\tom\AppData\Local\Programs\Python\Python310 > C:\Users\tom\AppData\Roaming\Python\Python310\site-packages > C:\Users\tom\AppData\Local\Programs\Python\Python310\lib\site-packages > > C:\Users\tom\AppData\Local\Programs\Python\Python310\lib\site-packages\win32 > > C:\Users\tom\AppData\Local\Programs\Python\Python310\lib\site-packages\win32\lib > > C:\Users\tom\AppData\Local\Programs\Python\Python310\lib\site-packages\Pythonwin > > Notice that these paths are much shorter and simpler than the paths > reported in the error messages from your previous attempt, and they are > mostly in "C:\Users\tom\AppData\Local\Programs", not > "C:\Users\tom\AppData\Local\Packages". > > Once installed, make sure to run the version of Leo that you just > installed and not some other. This is important because your earlier > attempts might have left a path that would launch some other version. The > easiest way to make sure is: > > py -m leo.core.runLeo > > If this new install seems to work right, you can think again about whether > you want to try to use whatever other environment is on your system > (Anaconda or whatever). You probably won't need it. > On Monday, October 3, 2022 at 9:25:39 AM UTC-4 uu86...@gmail.com wrote: > >> Thank you very much! I used double dash and the installer worked >> successfully: >> ... >> Successfully built leo >> Installing collected packages: leo >> Attempting uninstall: leo >> Found existing installation: leo 6.6.4 >> Uninstalling leo-6.6.4: >> Successfully uninstalled leo-6.6.4 >> WARNING: The scripts leo-c.exe, leo-console.exe, leo-m.exe and >> leo-messages.exe are installed in >> 'C:\Users\user\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\Scripts' >> >> which is not on PATH. >> Consider adding this directory to PATH or, if you prefer to suppress >> this warning, use --no-warn-script-location. >> Successfully installed leo-6.3 >> >> >> C:\Users\user\Apps\Leo\leo-editor-6.3> >> >> However, my attempt to launch Leo is unsuccessful: >> C:\Users\user>python C:\Users\user\Apps\Leo\leo-editor-6.3\launchLeo.py >> >> >> ** (python3.10.exe:8084): WARNING **: 15:22:23.005: Error loading plugin: >> 'C:\Users\user\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\enchant\data\mingw64/lib/enchant-2\enchant_hunspell.dll': >> >> The specified module could not be found. >> >> Leo 6.3 >> Invalid language code for Enchant 'en-US' >> Using "en_US" instead >> Use @string enchant_language to specify your language >> Can not create empty workbook >> Traceback (most recent call last): >> >> File >> "C:\Users\user\Apps\Leo\leo-editor-6.3\leo\commands\spellCommands.py", line >> 353, in open_dict_file >> d = enchant.DictWithPWL(language, fn) >> >> File >> "C:\Users\user\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\enchant\__init__.py", >> >> line 781, in __init__ >> super().__init__(tag, broker) >> >> File >> "C:\Users\user\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\enchant\__init__.py", >> >> line 542, in __init__ >> super().__init__() >> >> ... >> >> What else do I miss? It's hard to believe that Leo can't launch due to >> missing hunspell module. >> >> Thank you once again! >> >> >> On Monday, October 3, 2022 at 2:36:17 PM UTC+2 tbp1...@gmail.com wrote: >> >>> This follows a very common convention. A single-letter parameter on the >>> command line takes a single dash, longer parameters take a double dash. >>> E.g., >>> >>> -h >>> --help >>> >>> Some programs don't quite follow the convention (java, for example, >>> understands java -version) but Python and Leo do. >>> >>> On Monday, October 3, 2022 at 8:30:48 AM UTC-4 Thomas Passin wrote: >>> >>>> I believe you need to type two dashes for the "editable" parameter: >>>> >>>> pip install --editable .... >>>> >>>> >>>> On Monday, October 3, 2022 at 7:23:41 AM UTC-4 uu86...@gmail.com wrote: >>>> >>>>> I also tried to avoid cloud storage and whitespace issues by copying >>>>> Leo to another folder, but it did not help either: >>>>> C:\Users\user>pip install -editable >>>>> C:\Users\user\Apps\Leo\leo-editor-6.3 >>>>> >>>>> ERROR: ditable is not a valid editable requirement. It should either >>>>> be a path to a local project or a VCS URL (beginning with bzr+http, >>>>> bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, >>>>> git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, >>>>> hg+ssh, >>>>> hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file). >>>>> >>>>> On Monday, October 3, 2022 at 1:11:03 PM UTC+2 User User wrote: >>>>> >>>>>> Update: trying to deal with whitespace in the path did not help: >>>>>> C:\Users\user>pip install -editable "C:\Users\user\OneDrive - >>>>>> User\Apps\Leo\leo-editor-6.3" >>>>>> ERROR: ditable is not a valid editable requirement. It should either >>>>>> be a path to a local project or a VCS URL (beginning with bzr+http, >>>>>> bzr+https, bzr+ssh, bzr+sftp, bzr+ftp, bzr+lp, bzr+file, git+http, >>>>>> git+https, git+ssh, git+git, git+file, hg+file, hg+http, hg+https, >>>>>> hg+ssh, >>>>>> hg+static-http, svn+ssh, svn+http, svn+https, svn+svn, svn+file). >>>>>> On Monday, October 3, 2022 at 1:07:11 PM UTC+2 User User wrote: >>>>>> >>>>>>> Hi everyone, >>>>>>> >>>>>>> many thanks to Edward and the community for beautiful Leo. Need your >>>>>>> help installing it on Windows. >>>>>>> >>>>>>> I usually work in Linux and install Leo successfully by downloading >>>>>>> and unpacking leo-editor-6.3.zip and running launchLeo.py with gui=qt >>>>>>> key. >>>>>>> However, it did not work for me in Windows. >>>>>>> >>>>>>> I already have Python and Qt on my PC. This is what I tried: >>>>>>> C:\Users\user>python C:\Users\user\OneDrive - >>>>>>> User\Apps\Leo\leo-editor-6.3\launchLeo.py --gui=qt >>>>>>> It fails: can't find '__main__' module in 'C:\\Users\\user\\OneDrive' >>>>>>> >>>>>>> When I try to run pip install according to Installing from sources >>>>>>> recommendations I get: >>>>>>> C:\Users\user>pip install -editable C:\Users\user\OneDrive - >>>>>>> User\Apps\Leo\leo-editor-6.3 >>>>>>> ERROR: Directory 'C:\\Users\\user\\OneDrive' is not installable. >>>>>>> Neither 'setup.py' nor 'pyproject.toml' found. >>>>>>> >>>>>>> "Installing Leo with pip" recommendation did not work for me either. >>>>>>> Also, I prefer Leo 6.3. >>>>>>> >>>>>>> Appreciate any advice on how to install Leo (ideally, 6.3) on >>>>>>> Windows! >>>>>>> >>>>>>> Kind regards, Serhii >>>>>> >>>>>> -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to leo-editor+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/leo-editor/34f23a8c-e705-429e-a7db-b9ddafe16338n%40googlegroups.com.