
Python in the Windows 10 May update - pplonski86
https://devblogs.microsoft.com/python/python-in-the-windows-10-may-2019-update/
======
neuland
A lot of people are mentioning Apple removing scripting languages at the same
time as Windows is adding it. The stub is nice for learners. But ultimately I
like Apple's decision to remove them. You should not be relying on system
installed interpreters, because you end up with an ancient, unmaintained
version. And you are co-mingling all your dependencies with whatever else is
installed. Everyone should be using virtualenv. And it should be easier to use
virtualenv.

~~~
rossdavidh
It depends on who you're talking about. There is an attitude of, "if you can't
install a virtualenv as step 1 in learning how to do python, you don't deserve
to learn python". Not, I would hope, consciously thought of in that way, but
that's the practical affect.

I use virtualenv. When I was first learning to program, and I believe python
is a better choice for a first language than PHP or Javascript, it would have
been a substantial obstacle to have to do the virtualenv route first. Yeah,
it's easy if you've done it and know how to figure out what the problem is if
something goes wrong. It's an obstacle if you're just starting out, and I
think keeping the on-ramp simple is very important for the long-term health of
a language community.

Which suggests that, because python's on-ramp just got easier, it's long-term
prospects just got better.

~~~
RussianCow
If you're just learning, you don't need to mess around with virtualenvs; you
can install Python via the official Windows installer and install packages
globally. I don't feel like installing something is a very big initial hurdle
to overcome, as opposed to having it be pre-installed (but potentially very
outdated in the future).

~~~
naniwaduni
On the contrary, installing something is the biggest hurdle after perhaps
coming up with the idea that there's something here to be learned at all. And
sometimes it's part of the latter.

------
todd8
In the past when I needed a calculator on someone’s Mac, I just started Python
in a terminal and typed in expressions to be evaluated. It was nice to be able
to find it on any Mac and it’s much nicer to type into Python’s REPL than
clicking on a calculator’s GUI buttons. Now, Windows machines will have Python
and Macs may not.

On Macs and Linux I can still use the bc command instead (it’s an old Unix
command) but it’s far less handy than Python. See the bc man page.

There’s also dc, the even less used, reverse Polish notation calculator. It is
a standard Unix command that predates bc.

Interestingly, the dc “language” is older than C, Awk, Perl, or any other
programming language still found on Unix systems. It is implemented in C’s
predecessor, the language B.

You can tell that bc and dc are early Unix commands from their names, many of
the oldest Unix commands are just two characters long.

~~~
yokohummer7
Wait, how do they build dc? Is there a B compiler for 64-bit systems?

~~~
stordoff
Assuming it's OpenBSD or GNU dc, it appears to be written in C.

------
MarcScott
This is great for learners looking to write their first few lines of code. No
more wondering which Python version to install, or having to check the box to
have Python added to your path.

Now we just need a better bundled IDE. Idle is a horrible first editor, but
the added burden of installing a better IDE means it's the one most often used
by beginners.

~~~
Mister_Snuggles
I've been using Visual Studio Code for my Python development lately, it seems
like it would be a sensible choice to bundle (or install on demand) with
Windows.

~~~
MarcScott
VS Code has too steep a learning curve for someone who has never even written
Hello World!

Learning to code is hard enough, without having to learn a new software UI,
especially if all you've ever done on a computer is browse Facebook and write
Word documents.

If you want a great example of a beginner's/child's first IDE, have a look at
SonicPi

~~~
pfranz
I remember in college being thrown into Visual Studio. I got things to work
basically from a checklist. For the longest time includes and building/linking
were mysteries done in the background. I feel like a lot of people were
"programming by coincidence."

I think I still hold a grudge and prefer the command line to compile (which is
its own mess).

------
noname120
It looks like this update breaks already-installed Python execution if its
position in the PATH environment variable is after the WindowsApps folder. [1]

[1] [https://devblogs.microsoft.com/python/python-in-the-
windows-...](https://devblogs.microsoft.com/python/python-in-the-
windows-10-may-2019-update/#comments-35)

~~~
ChrisSD
That is how PATH works. An installer would have to be doing something
seriously wonky to get that wrong.

~~~
noname120
They could have used another mechanism than PATH.

~~~
vetinari
bash does exactly that - it has command_not_found_handle function and
distributions define it, so they can offer package installation for any
command not found.

------
el_cujo
It's interesting seeing this the same week Apple announces it's cutting out of
the box Python.

~~~
shawnz
Note that the latest version to ship with mac OS was 2.7, so it didn't exactly
ship with well-maintained support

~~~
larkost
This statement is misleading. Apple kept up with the 2.x versions, the same as
almost every linux distro. Only recently have the linux distros started to
move on to Python 3.x. And most of them still include Python 2.x (specifically
2.7) as the default `python`, and have added Python 3.x as `python3`.

It is not correct to say that Apple did not maintain support for it.

~~~
em500
Current macOS system Python is 2.7.10 (Mojave 10.14.5).

Upstream Python is 2.7.15.

~~~
ploxiln
... and 2.7.10 is from May 2015 - 4 years ago

------
nimbius
sort of a selective use case here, but im an automotive mechanic that started
learning python to track engine firmware, mileages, and tools at work. I
always did this on a raspberry pi, partly because it makes doing computer
stuff a bit more approachable than the ole black and beige dell laptop. We
have windows desktops for the office area, but I never once considered using
them for this.

Do people develop python in Windows? is there any distinct advantage? example:
the pi costs $30 and a used keyboard/monitor from a pawn shop, but anything
with windows is way more expensive.

~~~
enumjorge
I’m a little confused by your first question. I’m going to guess you’re mostly
used to interacting with Windows to browse the web, use Office, or other
software specific to your business. In that case, yes, that same computer can
be used to program python and people do it all the time. A computer is a
computer.

Yes there are some advantages, but those aren’t Windows specific. The
advantages also apply to traditional desktops/laptops running MacOS or Linux.
There are tools written for those platforms that won’t be available on the pi,
although the raspberry pi ecosystem is rich enough that that won’t matter
much. There’s also the specs of the machine. A beefier machine can power
multiple monitors that can let you see more code at a time. That’s just
surface level. We can chat more if you’re interested.

Having said that, sounds like what you have right now is working for you.
There’s no need to switch to something else if you’re making progress. It’s
pretty cool that you got started this way. I wasn’t aware that python is used
by car mechanics.

------
johnhattan
Just tried it. Looks like the latest Windows update installs a stub that sends
the Windows app-store to the Python installer page if you type "Python" from
the command line.

FWIW, the publisher for the MS app-store Python is "Python Software
Foundation" and it, far as I can tell, is just ordinary Python and not some
MS-only weirdness. It adds start menu links to the Python REPL and the IDLE
tool.

~~~
make3
you didn't read the article

~~~
johnhattan
Yes I did. I just wanted to relate my personal experience with it. Sometimes
I'll see an article about something new just to discover that it's actually
for an update that's a couple of weeks away. In this case, I just wanted to
verify that it's working as advertised.

------
chaostheory
Looking at the bigger trend, it feels like recently MS is doing everything it
can to engage developers. imo Apple is doing the opposite with bad keyboards
and the continued refusal to give developers a reasonably priced, expandable
box like the ancient G models or the old cheese grater product line.

------
stestagg
It's interesting that as Apple start considering not bundling scripting
languages[1], Microsoft start doing so.

Both sides may have wildly different reasons for making these changes, but the
net result seems quite indicative right now.

[1]
[https://developer.apple.com/documentation/macos_release_note...](https://developer.apple.com/documentation/macos_release_notes/macos_10_15_beta_release_notes#3318248)

~~~
romwell
You know, when Ballmer chanted "Developer, developers, developers" back in the
day, people made fun of him for years.

But really, that's where that ship is heading now, and it's paying off.

------
SketchySeaBeast
While I don't like the "let's teach everyone to become coders!" thing that
some companies seem to be pressing, I think this is a great addition for
dabblers, or for people who are on their parents computer and want to do
something quick without installing a bunch of junk. I really like this.

Edit: Oh, I see it's from the store. Well, that doesn't help anything at all.

~~~
bollockitis
When I was 11 years old I was looking at a bit of code in a magazine and,
being curious to know what it did, I booted up my parents' old IBM PC. I typed
GWBASIC.EXE into the command line and I was astounded that it worked.

Maybe that isn't so relevant now that it's easy to find and install software
but my journey with programming began that day when I was magically dumped
into that BASIC interpreter.

~~~
GordonS
The first coding I ever did was along the same lines, carefully copying dozens
of lines of BASIC into a Commodore 64 - I still recall the feeling of wonder
that it actually worked!

------
PaulHoule
The worst thing about Python on Unix is that there is always a system Python
you get when you type "python" \-- it might have been up to date once, but it
will be out of date someday, if only because updating it would break other
system dependencies.

Thus when you give a coworker instructions how to run something, they wind up
using the wrong Python and will waste hours of their own time and your time
wondering why it doesn't work. Or maybe they'll get confused about pip vs pip3
or ...

I've found it's a lot easier to get it right on Windows since there is no
system Python for people to get confused about.

Java's xenophobia, its insistence on "100% Pure Java" and the various
squabbles that Sun and Oracle have had with other platform companies has
actually made Java more reliable across different platforms since people
expect to have to manage their Java version and don't have a sense of
entitlement that they should just type "python" and have it work.

~~~
jkaplowitz
Red Hat ditched the user-accessible default system Python in RHEL 8, but
offers ways to have several versions of Python available and ways for
sysadmins to configure the target of /usr/bin/python.

Anyway, we're finally near the end of supported environments caring about
Python 2, so the difference between pip and pip3 will stop causing most of us
problems soon... (Yeah, I know some people will use Python 2 beyond EOL, but
at this point that's their task and the task of whomever they pay for
assistance, not everyone else's.)

~~~
vorg
> I know some people will use Python 2 beyond EOL, but at this point that's
> their task and the task of whomever they pay for assistance, not everyone
> else's

Virtually every common OS (i.e. Windows, iOS, and Linux) provides Python 2.7
by calling `python`, and Python 3.x by calling `python3` so it's more than
"some people" using Python beyond EOL -- it's two languages being used
simultaneously.

This is what most languages do when they make a breaking upgrade, e.g. Perl
5.x and Perl 6, or Apache Groovy (which ships two compilers in its Groovy 2
download bundle, i.e. the Groovy 1 compliant one used by Gradle and Jenkins
etc, and the later 2012 one with the invoke-dynamic capabilities added. Two
weeks ago, the Groovy project managers announced that Groovy 3 would keep on
doing this, putting the rewritten parser into the compiler which no-one uses,
and keeping the main compiler at Groovy 1 capabilities.)

~~~
jkaplowitz
For all of those common OSes, either Python 2 is no longer installed by
default or a plan to do that in the near future has been announced. Many of
those are preparing no longer to offer Python 2 at all, though few have
already dropped it. I don't think RHEL 9, Debian 11, Ubuntu 20.04 LTS,
Windows's new Python stub after the EOL date passes, or 1-2 major versions of
macOS in the future will offer it.

Yes, OS vendors will temporarily offer some transition past EOL for the
versions they ship. But only temporarily, and only in limited form.

------
wnevets
> every install of Windows will include python and python3 commands that take
> you directly to the Python store page.

Does that mean its not actually pre-installed but just super easy to install?

~~~
teh_klev
That's pretty much what this means.

------
Eli_P
Microsoft also provides CNTK and CNTK-GPU[1], which can be used as a backend
for Keras. That could make life easier to kick off with machine learning by
providing correct libraries for GPU. If you ever tried to install not-the-
latest Tensorflow for the oldster graphics card you may know what I'm talking
about, all that wading through a variety of lib versions. Nah, good news
anyways.

[1] [https://docs.microsoft.com/en-us/cognitive-toolkit/setup-
win...](https://docs.microsoft.com/en-us/cognitive-toolkit/setup-windows-
python?tabs=cntkpy26)

------
prirun
If they wanted Python on Windows, why didn't they just include it like they
include every other command? It's miniscule in size to have Python stored on
every Windows computer compared to the size of Windows. Why go through the
"Windows Store" to get it?

I hate all these stores. They are the ultimate gatekeepers and give big
companies huge amounts of power and control.

------
tmaly
I am still waking up but when I read the title, I thought it was about Python
self updating itself.

Glad to see some love from Microsoft for Python

------
teekert
Oh lord dat Terminal, it makes my retina bleed. Please hurry with that new
shiny goodness [0].

[0] [https://www.theverge.com/2019/5/6/18527870/microsoft-
windows...](https://www.theverge.com/2019/5/6/18527870/microsoft-windows-
terminal-command-line-tool)

------
rileymat2
There are a lot of comments talking about how you should not rely on the built
in version of python or whatever instead installing it yourself, but it is
really nice being able to pass people scripts that you know will work with the
stock operating system with no additional installs.

------
apacheCamel
As a side note: I really enjoy how the imagery at the top shows the rating for
Python is E (for everybody). Do all apps receive this type of rating? Who got
to test this and decide it was E? I always assumed the ESRB rating system was
only attached to video games.

~~~
buildzr
Quick, someone grep the standard library code, we can at least get some mild
profanity and improve that rating!

------
growlist
Oh god, here we go. So now there's yet another way for multiple Python
installs to clash.

------
amnesiac_200
Why is there windows python Team and what do they do. Python is 1 of N slow
scripting languages that has sod all to do with Windows. This is not a
language that should be treated differently to a dozen others.

------
jarjoura
I like that Microsoft is moving more of its stuff to their store in a way that
encourages people to use it. The desktop is becoming a powerful tool for
getting work done, and I think this is a great move.

------
catchmeifyoucan
Figured this out by accident yesterday - a pleasant surprise. Didn't realize
it was a result of the new feature. Nice work.

------
fnord123
Is this going to freeze everyone at Python 3.7 in the same way that CPython
had been stuck on C89 basically forever because Microsoft refuses to fully
support C99:

[https://www.mail-archive.com/python-
dev@python.org/msg92514....](https://www.mail-archive.com/python-
dev@python.org/msg92514.html)

~~~
sametmax
Not only Python is not installed (the command is a stub), but linux
distributions have been shipping Python forever, and it never froze anybody.
It's a matter of how you support upgrading, now what you provide out of the
box.

~~~
fnord123
>It's a matter of how you support upgrading, now what you provide out of the
box.

Absolutely!

------
AlexeyBrin
The title is inaccurate, if you write "python" in a Terminal and you don't
have Python installed, the Windows Store will launch and show you the Python
app/installer from the store.

There will be no Python already installed or included with Windows 10.

~~~
kuu
It seems they made it for newbies:

 _Once you discover that you need to get Python, you are quickly faced with
many choices. Will you download an installer from python.org? Or perhaps a
distribution such as Anaconda? The Visual Studio installer is also an option.
And which version? How will you access it after it’s been installed? You
quickly find more answers than you need, and depending on your situation, any
of them might be correct._

 _We spent time figuring out why someone would hit the error above and what
help they need. If you’re already a Python expert with complex needs, you
probably know how to install and use it. It’s much more likely that someone
will hit this problem the first time they are trying to use Python. Many of
the teachers we spoke to confirmed this hypothesis – students encounter this
far more often than experienced developers._

 _So we made things easier._

 _First, we helped the community release their distribution of Python to the
Microsoft Store. This version of Python is fully maintained by the community,
installs easily on Windows 10, and automatically makes common commands such as
python, pip and idle available (as well as equivalents with version numbers
python3 and python3.7, for all the commands, just like on Linux)._

~~~
asveikau
This is weird because "making it easier" seems a bit like screwing over people
who want more control and specifics. MS is relatively new at packaging open
source and doesn't seem to have much experience in the phenomenon of official
packages being not what you want.

~~~
asdfman123
I think this is wonderful for people who are interested in learning
programming. Right now one of the biggest hurdles to learning programming is
just getting the damn environment set up. Why does it have to be so hard? How
many people never learn to program because they can't get "hello world" to
print out?

This could make it extremely easy. "What programming language should I use?"
"Learn Python." "How do I install it?" "Through the Windows installer." Boom,
done. They're off to the races.

People who want control and specifics are advanced enough to figure out how to
get that themselves.

~~~
triMichael
I very much agree and love how the programming language AutoIt does it. When I
was starting out, both C and Java took several frustrating hours to set up
(don't get me started on requiring environment variables to be manually
changed). However, after a basic installation, AutoIt gives its au3 files a
right-click context menu option to compile to an exe. It also gives you a
shortcut to a help file that contains basic examples, a complete list of
language concepts, and a complete list of all first party functions and a page
on every single one complete with an example of how to use it.

------
kuu
Maybe it's better to link to the original Microsoft blog announcement?

[https://devblogs.microsoft.com/python/python-in-the-
windows-...](https://devblogs.microsoft.com/python/python-in-the-
windows-10-may-2019-update/)

~~~
ChrisSD
Indeed. The blog link gives much more detail and context then the guide.

------
zer0faith
Deceptive title.

------
tracker1
But, how dare Microsoft know people go looking for Python... those damned
metrics are all evil, evil I say!

~~~
romwell
My favorite part about people raging about telemetrics is that for many of
them, their primary computer usage is using Facebook and Google services.

Somehow, MS missed out on spreading a PSA that _any website and web app is
100% telemetrics_ because that's literally what a web app is (telemetrics with
feedback!).

------
nevi-me
Can we please have "Stability in the Windows 10 May Update". It's nice that
Microsoft's giving us free updates, but Python support, a new terminal, and
all the other things would be more appreciated if our machines remained
reliable while before the features.

------
floki999
Based on experience, I’d rather install my own Python environment than rely on
Microsoft’s suggestion of what I should install. This is Microsoft folks -
there is >always< a catch.

------
floki999
Microsoft wants to spoon-feed beginner Python programmers their way, via their
‘community’. It really is unnecessary. In time, this will lead to classic
Microsoft lock-in or dependency. I’ve seen this happen time and time again. As
much as I’ve been a big fan of Microsoft dev tooling since the mid 90’s, I
think Microsoft and other vendor’s newly-found open-source and Linux
evangelism will, in the long-run, be a disservice to those communities.

------
ngcc_hk
Surprise they do. Other than basic (and no longer after bill gate is gone) the
only programming language is dos command :-(.

Well seem they did not. Otherwise python will be universal. Anyway need pip
etc. And also better to use conda. And easier integration with os. As none,
probably not that useful. But better than none.

~~~
asveikau
Cscript.exe lets you run js from the command line.

