Restore missing blobs from blob cache

I had a curious case of missing-but-present blobs in an old Plone service, configured with a Zeo server and 2 Zope instances. The root of the problem (I think) was that the blob folder configuration was broken: the Zope client instances were configured with shared blobs to “off”, but they were really sharing the same caching folder. In the end, the blobs were loaded by the Zope services and everything appeared to be working, but when I’ve tried to move the blobstorage folder to a new machine, I ended up with missing blobs. [...]

Restart docker after archlinux upgrade

My main reason for avoiding ArchLinux upgrades (sudo pacman -Syu) was because I always needed to reboot my computer, to allow starting docker services after the upgrade. Today, I found the solution is a simple: systemctl daemon-reload systemctl restart docker [...]

How I broke my archlinux and fixed it

Today, new lesson learnt. I needed to test something with Internet Explorer and Edge, so I’ve downloaded the test images from the Microsoft website, then proceeded to install virtualbox, in my current KDE based ArchLinux desktop (which I love a lot). A simple pacman -S virtualbox perhaps? Yes, except… After installing virtualbox, it complained about some missing libssl2.0.0 lib… so I thought maybe I don’t have that installed? I didn’t really research it, just installed openssl. [...]

Hello world with Plone and Riot (Javascript frontent library)

I’m working on a somewhat weird experiment. My end goal is to have a user friendly (and mobile friendly) faceted search interface over the items of a collection. Seen through the eyes of my recent experience with VueJS, the classic Plone frontend APIs, such as JQuery and Patternslib/Mockup seem outdated and hard to digest. Any dedicated frontend UI library will seem much friendlier. My self-imposed requirements were: easy to work with, easily integrated. [...]

When did tmux get plugins?

Well, this is new to me. Apparently tmux now supports plugins. I don’t really know if I need any plugin, I enjoy tmux as it is right now (after some customizations) but it’s good to know that plugins finally exist for tmux. So, what do we have: First, the Tmux Plugin Manager: Next, the tmux Facebook PathPicker plugin (which is a marvelous thing I didn’t knew existed): and https://github. [...]

Analyse and optimize a webpack vuejs bundle

At around 450 kb of javascript code, a Quasar distribution bundle seems a bit too big. The following short recipe applies to an app generated from the Quasar Framework default template, but it probably applies to any vuejs project that uses vue-loader, and even any project using webpack. First, we want to analyse what’s inside the bundle. A good utility is webpack-bundle-analyzer, but how to use it? Configure the webpack to write the stats to a json file. [...]

Loading packages without z3c.autoinclude in Plone 5.1

The new Plone 5.1 development buildout doesn’t include a zcml property in its [instance] section. It is no longer needed, with all eggs already providing a z3c.autoinclude entrypoint. This, unless you want to load an older package which doesn’t have such an entry point. That’s when the trouble starts. Adding a, for example: [instance] ... zcml += cs.auth.facebook doesn’t work. There is really no zcml property in any of the extended cfg file, so Zope will try to load this package first, which will result in a “permission not defined” zcml error. [...]

Using pyramid_jwt with pyramid_multiauth

pyramid_jwt has its own convenience method of registering as an authentication policy, through config.set_jwt_authentication_policy. It does so because the constructor of its policy takes a lot of arguments, so it’s best to trust the package to do its own setup. But this makes it a bit harder to use with pyramid_multiauth, as you can’t easily pass the JWTAuthenticationPolicy policy to the multiauth.policies setting. Turns out that is not hard at all. [...]

Installing node with NVM

This is more of a recipe for myself, as I always have problems with npm. I’m usually stuborn and refuse to use a globally installed nodejs, and can’t be really bothered to properly install a nodejs tarball distribution, with setting up PATH and all. They’re usually throw-away and not portable between my machines. So, a simple recipe to install nodejs on my own setup, an ArchLinux machine using fish as default shell. [...]

Test for an interface provided by object in plone action condition

Quick tip: how to test if the context provides an interface, with an expression set as the condition: python:object.restrictedTraverse("@@plone_interface_info").provides('') [...]