-5
C:\Users\User>python2
'python2' is not recognized as an internal or external command,
operable program or batch file.

C:\Users\User>python
Python 2.7.13 (v2.7.13:a06454b1afa1, Dec 17 2016, 20:53:40) [MSC v.1500 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.

Altough I do have python installed when I type python2 in my cmd it doesn't see it.

Xotiic
  • 61
  • 1
  • 1
  • 4
  • windows doesn't know what 'python2' is. Why do you need it to? – SuperStew Jul 09 '21 at 15:36
  • 1
    And why do you expect it to be `python2`? Clearly it is just `python`. – DeepSpace Jul 09 '21 at 15:36
  • Then I don't need really need it? – Xotiic Jul 09 '21 at 15:38
  • I'm currently using hatch but it doesn't open my chrome browser so I thought that maybe it had something to do with that I was using the python command instead of the python2 command – Xotiic Jul 09 '21 at 15:43
  • no. your 'python' command is still opening python 2.7 – SuperStew Jul 09 '21 at 15:45
  • ```DevTools listening on ws://127.0.0.1:4963/devtools/browser/38d51d55-7c68-4939-94eb-86bec7aaff5e [13096:8132:0709/173854.294:ERROR:device_event_log_impl.cc(214)] [17:38:54.294] USB: usb_device_handle_win.cc:1058 Failed to read descriptor from node connection: A device attached to the system is not functioning. (0x1F) [13096:8132:0709/173854.304:ERROR:device_event_log_impl.cc(214)] [17:38:54.303] Bluetooth: bluetooth_adapter_winrt.cc:1072 Getting Default Adapter failed. ``` this is the code I get when entering ```python main.py``` on hatch in cmd – Xotiic Jul 09 '21 at 15:48
  • Add any errors, or other info to the actual question, not as comments. – SiHa Jul 09 '21 at 15:53

1 Answers1

-3

You can rename your python.exe into python2.exe and set the enviromental PATH properly to this renamed exe. Afterwards you can use python2 as an alias from command line (cmd)

Manute
  • 83
  • 3
  • Doing this leads to all sorts of confusion later. It would be better to create shortcuts/symbolic links to accomplish the same effect. – Marcel Wilson Jul 09 '21 at 15:54