This impacts Chrome, Edge, and Brave. A fix is in the works, but will take time to make it through the Chrome/Edge/Brave build trains. Up to then, most websites that rely on PyScript crash randomly with an "Aw, Snap!" message.
HN user
laffra
Also, check out PySheets (https://pysheets.app), which leverages PyScript to run Python logic in a spreadsheet UI, which is written entirely in Python. The PySheets UI uses LTK (https://github.com/pyscript/ltk), a fully client-side UI rendering library for PyScript.
I tried that exactly with PySheets by implementing the sheet in Python itself, rethinking how Jupyter Notebook would look if it treated the data science problem as a dependency graph rather than a linear storytelling document. See https://pysheets.app
Your second proposal looks like https://pysheets.app
Felix's upcoming work is intriguing and would enable a much nicer integration of Python into the Excel ecosystem. The use of PyOdide and WASM enables execution of the Python logic on-device. The same tactic is used by PySheets and taken a bit more to the extreme by implementing the cell functions, but also the entire sheet UI and logic in Python. Check it out if you are approaching the space from the perspective of a Python programmer, rather than an Excel user. See https://pysheets.app
You can load spreadsheets into Jupyter today. With Pandas or Polars, you can import CSV or Excel sheets quite easily. PySheets is reimagining what Jupyter Notebooks would look like if you use a DAG, not a linear execution flow.
Just like CoPilot or Sourcegraph's Cody is used in VS Code, PySheets uses OpenAI to suggest the Python code to write when the sheet contains a Pandas data frame of a certain shape. The AI accelerates figuring out what APIs to call and when. I myself find Matplotlib and Pyplot highly confusing, and a coding assistant that writes my code in this niche, makes me a lot more productive. It is cool to say, "Take the dataframe in E13 and generate an orange bar graph for it," and see the code generated.
And it all runs in your own browser without needing any cloud kernels.
Anaconda is also a heavy sponsor of PyScript. The https://pyscript.com website is an online IDE for quickly trying out PyScript and building a website. If you like PythonAnywhere, you will love pyscript.com as well.
That's nice. I will do the same for PySheets, once the dust settles on the original launch.
PySheets is not based on Rust. It is 100% Python.
I am feeling pretty Okay now, indeed. I played golf today. It was on a Par3 course, so it only tested my short game. However, I scored -1, with almost a hole-in-one. I blame it on the success of PySheets :-)
Thanks!
If you sign up for PySheets, we give you 7 tutorials. Two explain how to use AI to import data, convert it to Dataframes, and visualize them using Matplotlib. The generated code is impressive and can help novice data scientists explore the Pandas and Pyplot APIs.
The AI is used to generate Python code, not to analyze or generate data in the sheet. I will clarify that on the landing page. Hopefully, that will inspire you to try it out.
This is a different Kurt Vile :-)
PySheets has been designed to run on-prem and on GCP as well. The beta version you are looking at is just offered as a zero-install experimentation platform. We are actively talking with financial institutions, and both co-founders on the team, https://pysheets.app/#Team, have a long history in Finance, so we are very sensitive to all the (correct) points you make. We will look in more detail at your very helpful suggestions!
You can do that today with PySheets. On the PySheets landing page, you can find a live example. The data comes directly out of a sheet that uses a service to convert metrics into charts. For example, one of the three charts shown on https://pysheets.app/#Traction is directly embedded as an iframe from https://pysheets.app/embed?U=uXNuCGO2JU1E5aL7zcOh&k=C12. If I rerun the sheet that produces the charts, the PySheets landing page updates automatically with the latest data.
Most people will import external sheets using Pandas. It has numerous conversion methods for table-structured data sources, such as https://pandas.pydata.org/docs/reference/api/pandas.read_exc....
Lots of blood, sweat, and tears. And MicroPython!
Any PySheets sheet runs in the PyScript context and can access the JavaScript window and DOM. Therefore, you can use the browser to access the file system: https://developer.mozilla.org/en-US/docs/Web/API/FileSystem.
Alternatively, you could create a form to "upload" a specific file, but instead of uploading it, read the bytes from the PySheet's cell function.
Try cut-and-pasting a sheet from Google Sheets to PySheets. It works quite well. At the moment, PySheets does not handle Excel functions. This is on our possible roadmaps, but we just did not get to it yet. I really only worked on PySheets for about 3 months, since resigning from my last job in February.
Thanks, much appreciated.
:-)
Yes, I will do some videos in the coming week. I did an extended demo for the weekly PyScript FUN meeting, but it turned out it was not recorded <facepalm>.
A major part is, in the form of Pyscript-LTK. I keep moving more of PySheets to LTK as I find reusable parts. I truly love open-source, but I am also trying to get some revenue for the months of work I spent on developing PySheets.
Yes, my total development bill for EVERYTHING, including DigitalOcean, Google, and OpenAI is about $15.
Rowzero is a better spreadsheet, while PySheets is a better Jupyter Notebook. Although they converge in certain aspects, their distinct target audiences set them apart. This divergence may create some overlap, but it also leaves ample room for user preference.
PySheets currently runs inside the browser, on top of WebAsm, and the limitations there are bigger than just Python's slowness. You have only 4G addressable memory, including the interpreter and libraries. Network bandwidth is also a limiting factor for client-side computation.
That said, PySheets can render a sheet based on a 50,000-row Excel sheet in 0.5s and needs about 20s to do a full end-to-end recompute run. There are limits to what you can do in the browser without using an external kernel that can run Polars on large datasets. But, I think most people will be fine with what PySheets can let them do.
Finally, as the author of PySheets I am honored that a "competitor" sees us as a threat. I am quite impressed by Rowzero myself. Nice work :-)
The PySheets server runs anywhere, for example: my laptop, Google AppEngine, and DigitalOcean. I designed it with on-prem in mind, so that PySheets could be deployed at companies that do not want to share data with external services.
That said, only the data stored in the sheet itself is stored in PySheets. Most use cases will load data from another place, filter and convert it, and then render a result. Still, self-hosting would be an interesting use case.
LTK, a Python library to create browser UIs, is part of the open-source PyScript project. See https://github.com/pyscript/ltk. Anyone planning to visit PyCon US in Pittsburgh, I will be in the Anaconda booth most of the time. See you there.
I envisioned many of the use cases not to store data in the sheet, but to use PySheets as a better Jupyter Notebook: Import data, convert to Dataframes, massage, analyze, learn, and export. A good example is how I have a sheet that loads PySheets usage metrics, converts to dataframes, plots in graphs and then renders as live charts on the pysheets.app landing page.
Thanks! - the author of PySheets
Browser > JS > WebAsm > PyOdide/MicroPython > PyScript > LTK > PySheets > Your Python.