Monday, March 18, 2024

Visual Studio Code Jupyter Python Extension line wrap in output cell - how to set notebook.output.wordWrap

My Visual Studio Code (Mac) Jupyter extension (plug-in) output was not line wrapped. It was a single unreadable output string. I had to either copy and paste into a markdown cell (where VSC line wrap config is followed) or I had to come up with Python output formatting solutions.

Then I saw a video in which the developer's cell block output was wrapping. So I went looking again. This turned out to be a lot harder than it was, say, 10 years ago. I spent at least 40 minutes, and probably more, digging through obscure corners of the internet

At last I got a hint. There is something called "notebook.output.wordWrap" that defaults to false but can be set true. If you can figure out how to set it.

I couldn't figure out how to set this value for the Jupyter Notebook extension on my Mac however. I got some hints from Microsoft's documentation on editing settings.json even though it's not correct about how to navigate to preferences. I used the ⌘, shortcut. From there I searched for "wordwrap"

You can see the result below. I needed to set Notebook > Output > Word Wrap to true. The copied JSON version of this is "notebook.output.wordWrap": true. You can see the setting in the screen shot below (click for full size).

I set this value for User and Workspace both, I assume Workspace wins but I don't know. Now my output wraps so I can read it.

There's also supposed be a metadata tag that causes a Jupyter notebook cell to scroll output but I couldn't get I too work and it felt too obscure to rely on.

Wednesday, March 06, 2024

Aperture will launch on an M2 Air running Ventura 13.6.3 and will browse an old Aperture Library - but nothing else

This was a bit of a shock. Aperture won't run on Intel Monterey without an OS hack (Retroactive). I was cleaning up an M1 Air that had a copy of Aperture on it and on a whim I clicked it. Aperture was there via Migration Assistant. No Retroactive needed.

Aperture launched. No complaints. I could browse my old 600GB Library.

So I copied just the app from my Application folder to an external drive and then launched it on a different M2 Air. Same. Just launched. I could browse and search. Much faster than on my old Air running Mojave.

I have not tried doing anything with it other than search and browse. I'm basically stunned and I figure it could mess up my old Library.

I'm still healing from my years long slog to migrate the Library to Photos.app/iCloud. Being able to browse the old Library is very helpful for understanding what migrated and what didn't. (Yes, Photos.app is mostly a huge regression.)

See also: I shared this on Apple Discussions. I'm curious if Apple will remove the post; they are pretty aggressive about removing posts these days.

Update 3/28/2024: I recently got an older M1 which I updated to Sonoma. Aperture launches and quits on this machine. So now I need to test on an M2 running Sonoma.

Update 3/30/2024: And ... it crashes on an M2 running Sonoma. So this is only a weird curiosity and not very useful.