Live data from Hacker News

Microsoft is bringing Python to Excel

theverge.com

331–340 of 455 posts

Re: Microsoft is bringing Python to Excel

#331

> Python calculations run in the Microsoft Cloud A colleague was joking, "I guess even Microsoft itself isn't able to manage local Python installations on Windows…" But imagine if Microsoft actually managed to finally solve the "setup a local Python environment" situation once and for all and Excel became the standard Python package manager across operating systems! $ excelpip install fastapi==9.11.23 Searching for f…

> A colleague was joking, "I guess even Microsoft itself isn't able to manage local Python installations on Windows…" I've been waiting for Microsoft to solve package management on Windows since I played around with debian's apt 20 years. That's not snark, it seemed like Microsoft's product complexity and dedication to backwards compatibility of software would make them the ones to move software management forward. R…

> It seemed like Microsoft's product complexity and dedication to backwards compatibility of software would make them the ones to move software management forward.

That's precisely why they _didn't_ go with the package manager model of software distribution.

Package managers in most distros assume that everything you download via apt/dnf is a part of the operating system and integrates with whatever dependencies the OS ships with. It's a great system if you're an operating system maintainer, but terrible if you're a third-party software developer who has no interest in dealing with 5-6 different OS's repo formats and dependency versions. On Windows and macOS, you vendor most everything, provide runtime installers for the rest, and that's usually enough to be resilient to bitrot.

Package formats like Flatpak, Snap and AppImage are the only projects who seem to be taking the problem of software distribution on Linux seriously, and of those only Flatpak seems to have the mature tooling and lack of myopia necessary to pull it off. For the times that I do miss apt on Windows, chocolatey is pretty good at installing software and vcpkg works great for linkable libraries.

Re: Microsoft is bringing Python to Excel

#332

Earlier quoted context omitted.

I think it's similar to the current generative A.I. trend. The companies I work for while consulting (mainly financial and health organizations) have been very cautious about any company or PII data going to these A.I. programs, and the cloud in general, and are looking to make their own local run generative A.I. LLMs for their employees to use. By it's very nature these Excel documents will be filled with company da…

> By it's very nature these Excel documents will be filled with company data, so I can imagine these companies would also be a bit cautious sending those calculations to the cloud, especially if they can't control the flow of data from their I.T. departments via web applications. This is exactly what I see when talking to users about xlwings: it needs to run on their end, behind their firewall, in exactly the cloud t…

I do a lot of work with US state governments, it's the same story mostly. It's possible to get the approvals required for data to be shipped off to some "cloud" but it has to be FedRAMP certified and no data can move outside the contiguous 48 states.

Re: Microsoft is bringing Python to Excel

#333

Meh, as an advanced user on a trading floor we don't need Python for Excel to run on the cloud, we need it to run locally so we can tap into our in-house C++ library and KDB databases. Third-party solutions have so much overhead.

Sounds like you're doing something too sophisticated for Excel.

We are essentially using it as a UI for the traders.

Re: Microsoft is bringing Python to Excel

#334
post #49

Earlier quoted context omitted.

Hi I work on Excel, can you write a summary of why that's important to you and send it to bgruenbaum@microsoft.com ? I'll get it in front of a PM. Alternatively PMs read all the feedback sent via the feedback UI on Excel web and desktop so you can use that instead if you prefer.

>> Hi I work on Excel, can you write a summary of why that's important to you and send it to How out of touch with the real world is the Excel team?

Customer verbatims are like, an incredibly valuable currency. It's all fine to say "I know the product in and out and I think this is important". But it's another thing entirely to say "I know this is important because _this customer right here asked for literally this_".

Re: Microsoft is bringing Python to Excel

#335

I wish Libreoffice would have smelled the coffee long time ago. In principle scripting using Python is possible but exceedingly cumbersome/ugly and there seems to be no roadmap to improve on this. The same warning applies to the linux desktop and all its apps more generally. Increasingly proprietary platforms will be rolling out advanced "AI" functionality extensions to classic apps that are cloud based, many of them…

that's interesting, i see the opposite. python is so easy to script that imo excel is nailing its own coffin. with an aging and retiring demographic of people that have never used a programming language, anyone who learns to incorporate python into excel will end up preferring python because its both more flexible and scalable. i have no reason to use excel except for basic drawing board math, if someone demands a sp…

> i have no reason to use excel except for basic drawing board math

I think you underestimate the amount of work, globally, done in Excel. If Excel vanished it would be a business/economic extinction level event, It's not going anywhere.

Re: Microsoft is bringing Python to Excel

#336
post #18

Earlier quoted context omitted.

> it will be amazing and very widely adopted. The calculations in the cloud?

Why would the vast majority of Excel users even notice or care about this?

The ones that use python would. It being cloud-based makes it a pretty useless feature for anything that I was using Python & Pandas for.

If it was on the client side, I'd be rolling it out to users the moment it was available.

Re: Microsoft is bringing Python to Excel

#337

Earlier quoted context omitted.

Thanks for your work! The async JS functions are amazing and allowed me to ship rock-solid Custom functions with xlwings and Python. The problem with Office.js is that it’s just simply too hard to get started with all the npm bloat for the average Excel user (even more professional devs struggle). Well, I am pretty happy how I am saving users from having to use Node.js: https://docs.xlwings.org/en/latest/pro/server/o…

> The problem with Office.js is that it’s just simply too hard to get started with all the npm bloat for the average Excel user (even more professional devs struggle) IMO deployment is an even harder problem. The Office team makes it incredibly difficult to deploy web add-ins (presumably for business reasons) and accordingly most companies I'm familiar with are still using the ancient, barely-supported COM+VSTO add-i…

Which part do you find difficult? The web backend or the deployment of the Manifest.xml via the app store / office admin?

Re: Microsoft is bringing Python to Excel

#338
post #100

Back in 2005, some friends and I started a company called Resolver Systems to build a Python-enabled spreadsheet, which we called Resolver One. Sadly, it never took off in the marketplace, and we had to pivot; we would up creating PythonAnywhere, an online coding and hosting environment, which worked out pretty well and was acquired by Anaconda last year. And now, the circle is closed :-) (Just for clarity: the team…

It was a great product - I remember your pitch and indeed we met a few times at the London python for finance meetup (remember the "Enthought Python Distribution"?). The only issue is that Resolver was IronPython-based so there were a bunch of libs that kinda didn't work.

I have to second that, it seemed to be a great tool. I've often wondered why it couldn't get traction¹. I can recall people gushing about it at what may have been the same Python meetup in London, and also people being impressed enough by it at a Haskell meetup that they were lamenting an imagined lost opportunity to shove a "real language" in to a spreadsheet ;)

I'd always kind of assumed that the target audience would have appreciated the IronPython use, as the .net ecosystem would likely have been more valuable to them. Having just looked I see that numpy wasn't available on IronPython until 2010, and I'm sure that would have been useful to have a little earlier.

¹ Pretty sure I've referenced it here a few times too.

Re: Microsoft is bringing Python to Excel

#340
post #38

This sounds like it provides a way for Excel to hand a bunch of data to Python code for processing and get back results, and vice versa. That's probably extremely valuable to many people, but it does not seem to be what I hope for whenever I see something about bringing Python to Excel. What I hope for is something that is like VBA but without the VB. I.e., a Python (or JavaScript) interpreter/JIT/compiler built into…

Install PyWin32 module and `import win32com.client` and you can access "all the internal Excel objects and methods that VBA has access to". C:\>python Python 3.10.1 (tags/v3.10.1:2cd268a, Dec 6 2021, 19:10:37) [MSC v.1929 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> from win32com.client import Dispatch >>> xl = Dispatch("Excel.Application") >>> xl.Visible = True…

The same with xlwings (works on macOS, too):

  >>> import xlwings as xw
  >>> wb = xw.Book()
  >>> sh = wb.sheets[0]
  >>> sh["A1"].value = "Hello World"
Post reply on HN