
Why Write Python in Visual Studio? - numo16
http://blogs.msdn.com/b/visualstudio/archive/2015/08/03/why-write-python-in-visual-studio.aspx
======
mvid
I write Python professionally, and it will be pretty hard to get me away from
PyCharm. I don't see anything in the blog post that indicates a feature
PyCharm doesn't already have.

~~~
TillE
> a feature PyCharm doesn't already have

It's free.

I'm sure there are a lot of Python developers who already have a full-featured
IDE they love, but then there are also people (like me) who sometimes write
Python and just use Sublime Text or Vim. Or even Eclipse.

~~~
compostor42
JetBrains released a free community version:

[https://www.jetbrains.com/pycharm/download/](https://www.jetbrains.com/pycharm/download/)

~~~
Cyph0n
They also provide a free 1 year educational license for all of their products
to students.

~~~
zer01
As well as discounts if you're a student. IIRC I paid like 25$/year when I was
still a student. Easy money to pay with such an awesome product!

------
saboot
I've been using PTVS for about two weeks now. Previously I just used Spyder
which shipped with the Anaconda distribution.

Some things that annoy me:

\- Reading intellisense python documentation in the mouse over window is
really tedious. There is an object window that can display documentation for
your classes, but not from libraries.

\- Rendered docs are much easier to read. Spyder did this very well. With PTVS
I'm looking at the docs online for numpy and matplotlib. With spyder I just
ctrl+I and it displays using sphinx very nicely.

\- I was not able to get IPython to cooperate with displaying plots in
separate windows in executing scripts as easy in PTVS compared to Spyder.

\- Being able to commit and push to github is a great feature.

\- Spyder had superior debugging features in terms of examining array data
throughout the debug process. Make plots just by right clicking the object in
the variables window. Very useful for making sure a step for a scientific
algorithm is doing what I intended.

I'm hoping more features like the above will be added over time. However I'm
looking at going back to Spyder + some git plugin or tool, or switching to
PyCharm.

~~~
chupapuma
I am Chris Wilcox, one of the developers on Python Tools for Visual Studio. I
am happy you have tried the product and glad you took the time to provide some
feedback. We have some pretty decent GitHub support built in to Visual Studio
and our tooling. With Visual Studio 2015 we also have a nifty 'Open in Visual
Studio' button added to all GitHub pages.

As for the other things they aren't complete yet but they are definitely very
valid suggestions. If you would file issues on
[http://github.com/Microsoft/PTVS](http://github.com/Microsoft/PTVS) we can
track them and hopefully keep you posted on the progress to getting them into
the product.

~~~
RA_Fisher
Any chance to change the license over to GPL?

~~~
chupapuma
Short Answer: No. Longer Answer: We are currently licensed as Apache 2.0 and
are satisfied with the constraints of that license. Virtually all products
released at Microsoft as OSS are released under MIT or Apache 2.0. We haven't
had issues with the license we are using and have no plans to change it.

Thanks for your feedback! Also, I hope you enjoyed PyData Seattle! (just came
across your Twitter handle and noticed a few photos)

------
drglitch
I've met Steve and his team mates at the last PyCon - the team is very
knowledgeable, approachable, and most of all enthusiastic about their project.

Having been using Python professionally for about 8 years now, i've been
playing with PTVS and finally think its ready for public consumption - if
you've tried it more than 9 months ago, be sure to try again - it is
lightyears better, especially when it comes to things like remote debugging
and managing venvs.

Documentation is still a bit lacking here and there when it comes to getting
PTVS to play nicely with other debuggers like pdb and werzkeug, but overall, i
cant wait to see the project and the team continue on this effort.

------
ohitsdom
I'm a .NET developer so to me this is a slam dunk. How does the Python crowd
feel though? I'd guess the majority tend to be Microsoft-adverse. Why wouldn't
you use VS when it seems to be so ahead of the competition?

~~~
na85
IntelliSense is pretty good, sure, but emacs is a superior development
environment in nearly every other aspect.

~~~
ohitsdom
I've never used emacs so am completely ignorant. What makes emacs superior?
All I know is the speed that can come with keyboard shortcuts.

~~~
S4M
That, and the fact that it's very easy to extend it with Emacs Lisp. I know
that it's possible to write extensions for most of the IDEs or text editors
out there, but the degree of customization is higher with emacs, mainly
because emacs is basically couple of primitive functions written in C + a lisp
interpreter (also written in C) and the rest is written in lisp, so you have
access to everything emacs has to offer if you want to customize it.

~~~
collyw
Its way easier to extend Eclipse by adding one of the plugins.

~~~
S4M
Emacs has also plugins, and I would argue that it's way easier to write your
own plugins for emacs than for eclipse.

------
bliti
For those who have used this:

\- Does it perform better than PyCharm?

\- How is Windows working for you as an OS (to develop Python on)?

~~~
czardoz
I've not used this, but about the second bit:

I've developed a few pieces of software on Windows and by far, the most
painful thing I had to do install Visual Studio Express to compile some of the
C extensions. I used Pycharm on Windows, so it pretty much abstracted away
tasks like making virtualenvs, setting up environment variables, etc.

~~~
odonnellryan
You're definitely right, sometimes you do need to install odd stuff on Windows
to get certain Python packages to work.

It has seemed to get better lately. I usually use Windows, and I've been
getting along great lately with Python dev work.

------
stillsut
I work at a .Net shop and wanted to build a developer tool with python for my
colleagues. None of them have a python interpreter so it needs to compile to
an .exe I've googled for hours on how to do this with IronPython but the
information is incredibly sparse and outdated. Is there any way to do this
currently?

~~~
numo16
Perhaps this will point you in the right direction:
[http://www.decalage.info/en/python/py2exe](http://www.decalage.info/en/python/py2exe)

~~~
stillsut
Thanks, I'd like to integrate with .net though, maybe with WPF. That's why I'd
like to use IronPython.

Any MS / Python people?

------
smortaz
If you want to get a feel for what PTVS is like, you can watch these short
videos:

[https://www.youtube.com/playlist?list=PLReL099Y5nRdLgGAdrb_Y...](https://www.youtube.com/playlist?list=PLReL099Y5nRdLgGAdrb_YeTdEnd23s6Ff)

10k foot view web page: [https://www.visualstudio.com/en-us/features/python-
vs](https://www.visualstudio.com/en-us/features/python-vs)

if you want to get a feel for an advanced feature, try:

[https://www.youtube.com/watch?v=wvJaKQ94lBY](https://www.youtube.com/watch?v=wvJaKQ94lBY)

------
dimino
I was going to write a little client library for a REST API my city's
transport system exposes, and I think I'll try this out on my gaming PC,
rather than my intended plan of writing it on my Macbook.

My worry is it's going to create VS-specific files, which I'm adamantly
opposed to (or any IDE-specific files, for that matter). We'll see, though. I
guess I tolerate the .idea directory already, I just don't want to _depend_ on
the VS files, similarly to how I have a .gitignore line for .idea currently.

I can't be sure if it's because I already had cygwin installed on my PC prior
to my upgrade to 10, but I'm very pleased with the updated cmd.exe. I _think_
I recall ctrl C/P working as expected too!

Right now I'm dealing with a weird encoding issue when I SSH to my Ubuntu box
from CMD.exe, but I'm sure it's just a setting somewhere I've got to tweak.

~~~
chupapuma
I am a developer on PTVS.

TL;DR - We do have project files but are working to remove that necessity.

First, we do have some VS specific files, namely SLN and PYPROJ files. These
are unfortunately needed for us to manage your project. We do hope to not need
these in the future but we currently need them due to the project system we
use in Visual Studio. We do hope to replace this with a different solution
eventually.

The good news is these files are easily generated and do not need to be saved.
If you go to File>New>Project>Python>From Existing Python Code you can
generate these by giving a folder.

Second, As for the SSH troubles, CMD has been given an overhaul for Win10 and
I suspect you are seeing the effect of that. I know they handle encodings
differently now so that is probably the issue. I know I have seen some things
render a bit strange since my transition to Win10 last week.

------
bernardvds
Prior to Python I used to work with Visual Studio (C# and VB) and loved it -
especially the ease of designing great-looking GUIs and ease of access to API
documentation.

But the half-baked integration of VS with Python or IronPython, and the
slow/clunky evolution of PTVS has put me off Microsoft tooling for good.
Python is a great language for nimble development - locking yourself in to
Microsoft's whim messes up with that, unfortunately.

------
zwieback
I like VS but is this fundamentally better than PyDev? I've become accustomed
to Eclipse so I get auto-complete and full interactive debugging already.

~~~
ohitsdom
In my experience (C# & Java), Eclipse's autocomplete doesn't even come close
to Intellisense. Not sure if that gap is any different with Python.

------
uptownJimmy
Fantastic. I was on the fence about lookng at Python in my spare time. Now I'm
bound to do it at some point. VS is amazing.

------
kelvin0
Last time I tested PTVS, running any simple script was 100x slower than
running it within Wing IDE (professional) which I was I used 99% of the time.
This pretty much killed the idea of using Python in VS, unfortunately (for me
anyways).

~~~
smortaz
hi smortaz, project lead for PTVS. i'd love to get a pointer to the script (or
repro). this should definitely not be the case! sorry about your experience.

------
Rapzid
I have two questions in my head:

1.) Is the foundational work that has gone into this going to be used to help
support intellisense in other languages in the future?

2.) Will any of this make it into Visual Studio Code?

~~~
dogma1138
Python had intellisense support both officially (through MSFT) and non-
officially through community addins since VS2003, MSFT has support since 2005
with working examples.

VS Code doesn't really have "intellisense" it's a nice fork of ATOM but
considering just how much of an amazing development environment VS is i feel
like having Code under the same brand devalues it quite a bit.

Visual Studio also has support for Ruby, Node and virtually every other
language out there from LoLCode to Scala the only real downside of VS is that
it's not multi-platform, but outside of Silicon Valley you won't find that
many software houses that develop on Mac's or Linux machines that often
either.

~~~
sandGorgon
>but outside of Silicon Valley you won't find that many software houses that
develop on Mac's or Linux machines that often either.

That's patently untrue - Linux is extremely, extremely popular all over India.
All major laptop manufacturers (Dell, Lenovo, Asus, Acer) sell laptops with
pre-installed Linux.

Unfortunately, Macs are getting pretty popular here - even though they are
double in cost.

------
RA_Fisher
And one really great reason not to use it, the license. At any point they can
yank it away from you, why invest time into learning something like that?

~~~
blackbeard
They have made at least two attempts to do that in the past as well with
dropping the cheap versions of visual c# 2003 and then trying to yank the
desktop version of visual studio 2013 express so a fair observation.

Plus I think you have to sign in now to maintain your license in community
edition and the SDK is no longer standalone.

------
vegabook
Indeed - Why??

IronPython. Might trick me once... won' let u trick me twice.

~~~
engi_nerd
I hadn't really gotten into Python in the heyday of IronPython. Can you
explain why you don't like it?

~~~
vegabook
No bumpy, version lag, win only. Basically incomplete.

~~~
vegabook
sorry meant "Numpy" there. don't know why it came out "bumpy". Probably my
mobile keyboard.

------
JoshMnem
I don't want to be forced to login to software before I use it. Also,
Microsoft can't be trusted. Look at the keylogger in Windows 10, for example.

PyCharm is a good Python IDE. You can get a lot of these features in Emacs (or
try Spacemacs), or Vim, or Sublime (with plugins).

~~~
partiallypro
You mean the "keylogger" than only tracks search queries & auto-correct to
better optimize algorithms, which Google and Apple both do. Sure.

You also don't -have- to sign in. So your post is just nonsense.

~~~
JoshMnem
You don't have to sign in to use Visual Studio? I've downloaded it twice and
didn't see a way to use it without signing in. If it's there, it's hidden.

Windows 10 sends your typed text to remote servers. That's a keylogger. You
can opt out, but most users won't. Other companies do it and I criticize them
too.

~~~
mryan
If I'm using Windows 10 and I type my credit card number in to a text input
field, is that sent to MS?

Or, as partiallypro says, are they only sending the contents of e.g. browser
search fields?

If the answer to the first question is yes, then this is a keylogger. If
partiallypro is correct, then calling it a keylogger is disingenuous. By that
logic you could call my mail client a keylogger, because it saves drafts to a
folder on an IMAP server.

~~~
JoshMnem
If I type something into my computer, and I do not explicitly opt-in for that
data to be sent to a remote server, it is keylogging.

If a company records my keystrokes (even if just in part of the software,
excluding credit card numbers) and sends my input to a remote server in order
"to help serve you better, show you ads, and share with our trusted partners",
words like keylogger and spyware are appropriate.

~~~
mryan
I think this approach dilutes the meaning of the term keylogger.

For example, Google sends your keystrokes as soon as you start typing in the
search box, and uses this for autocomplete. Presumably you didn't read the
full T&Cs before you started typing your search query, so by your logic this
is a keylogger. But I think most people would make a distinction between this
and a "traditional" keylogger.

Just for the record - I'm not condoning this behaviour or arguing that it is
desirable.

