This may have been reported already but all of the Colab links after chapter 5 say "Click here to run Chapter 5 on Colab", though the url linked to appear to be correct and not to chapter 5.
Interesting! I wasn't familiar with Du Bois' work. I guess this highlights how much easier it is today to create and verify that visualizations are more accessible or even to just be aware of differences in visual perception.
As of today, PieFed includes a ‘theme engine’ which makes it easier for people with low or no Python skills to change how PieFed looks and behaves.
Let’s start with the app/templates/themes directory in the PieFed codebase. In this directory there will be a sub-directory for each theme that is available. As of this writing there is only one, called ‘high_contrast’. If you want to make a new theme, copy the high_contrast directory and rename the copy to something 20 characters or less. Let’s pretend your theme is called ‘my_theme’.
Inside ‘high_contrast’ is high_contrast.json. This file contains a bit of information about the theme, to improve the user experience of choosing which theme to enable. Currently the only information in there is a user-friendly name for our theme but I might add more in future. In our new theme we to rename high_contrast.json to be the same as the directory containing it, or ‘my_theme.json’ in this case. Also change the user friendly name in the JSON to something like “My Theme”. Take care not to change the double quotes.
Also in the theme directory are two files: styles.css and scripts.js. You can remove the high_contrast CSS and put your own. high_contrast’s scripts.js is empty and is just a placeholder to encourage you to add your own JavaScript.
In PieFed on the main menu, go to Account -> Settings and check if your new theme is shown as an option in the Theme field. If not then you messed up the naming of the theme directory or theme.json file. The theme setting here will change the theme you use while browsing PieFed – to change it for everyone go to Admin -> Misc Settings and set the ‘Default theme’ option.
Editing styles.css and scripts.js will probably be enough for most people. But in addition to that you can copy any .html file from app/templates into your theme and that copy will be used instead of the default one. For example, the home page template is app/templates/index.html so if you copied it to app/templates/themes/my_theme/index.html then any edits you make to the copy will be used to render the home page in a different way than the stock PieFed theme would!
If you want to theme a template in a sub-directory, like app/templates/post/post.html then the correct place for your copy will be app/templates/themes/my_theme/post/post.html.
The .html templates are a mixture of HTML and a language similar to Python called Jinja2.
I very much look forward to seeing what people come up with!
Licensing
PieFed is licensed under the open source AGPL license and themes are considered derivative works. As a result, themes need to be licensed under the AGPL as well.
This means that anyone who distributes or shares their PieFed themes must do so under the terms of the AGPL, ensuring that the source code of the theme remains open and accessible to others. If you do not distribute or share the theme with others then you do not need to share the source code with the public.
Using the theme to serve a publicly-accessible PieFed instance is “distribution” so you need to be able to make the theme source code available to everyone, either as a downloadable file or a git repository. If you choose to send PieFed a PR of your theme it will be gratefully accepted.
My hot take on the Vision Pro is the same as my hot take on every AR/VR/Mixed Reality headset produced in the past checks notes 20 years: "If most women can't use your product for 4 hours straight without throwing up, don't try to tell me that it's the future of anything." I said what I said.
Women can use a smartphone indefinitely without nausea. They can use a laptop indefinitely. A gaming console and TV indefinitely. But XR headsets cause motion sickness in most women in under an hour. 🤷🏿♂️
I’m putting together a workflow to add my favourited toots to my week in review with a #python script.
Anyone interested in the approach?
I’m thinking about writing a post about it. You’ll be able to read it in my newsletter: https://buttondown.email/natera
Make sure to subscribe!
Neovim is awesome! But it's not really like VScode at all.
It's mostly vim with support for Lua (a gross simplification but gets you into a usable mental model). That Lua scripting has seeded what is now a great ecosystem. Many active developers have made Neovim highly customizable for creating workflows and development environments that work the way you think. You can use a pre built distribution or build out your own configuration as you see fit.
is that Apple deserves a cut of third party App Store developer revenues
Reasonable people can disagree on how much, and Apple HAS harmed itself through greed
But distribution infrastructure has value. Creating and maintaining runtimes has value. Building developer tools has value. Calling it “payment processing” totally misses the mark on what they built
There has never been a universe where you got distribution for your product for free.
I may not enjoy analyzing data with #Python, but I like the workflow of creating a dedicated development environment per project that is encouraged by using pyenv or conda.
Something like that should exist for #RStats, for example a script that uses both RIG and {renv} to provide a project-specific R+packages installation
I think Nix is great for addressing both concerns. But people seem intimidated by it.
Also, there's never going to be a great answer for people that build things for their own purposes and only later think to share them. Especially if those people are not software engineers, but people that are just answering questions using programming languages as a tool fir discovery.
You seem to be arguing that heavy equipment shouldn't be used to dig a foundation of a house because people can use shovels as if the foundation of the house was the entire point of the construction project. Ultimately, someone wants to live in the house and the cost increases and time delays that digging by hand would entail are not going to be welcomed by those who would like to live in the house even if someone claims that using the heavy equipment is somehow doing it wrong.