Migrated VPS

black server racks on a room

When I started hosting this website on DigitalOcean about 9 years ago, the version of Ubuntu that was all the rage was 14.04 LTS. So I started my hosting journey with that. Pretty soon though, 16.04 came along and since I was ever active on my server, I upgraded to that using nothing more than a few apt update commands. Since then, other than a few forced efforts to secure the OS and install what I needed for experimentation, I didn’t do much to upgrade the underlying software.

So it happened that, when at the beginning of the year I tried to upgrade from PHP 7.3 to 7.4 (a process which failed), I was made aware of the fact that the chasm between where my software stack is and where it ought to be is rather large. I tried running a straightforward upgrade from 16.04 to 20.04. The blocker was mysql. Apparently, no matter what third party repos I tried, the upgrade from what I was running to whatever’s the current just wasn’t possible. Well, it may be possible, but it would not be easy. The recommended path, on multiple websites, forums, and blogs, was to just fire up a new VPS and migrate my websites and services manually. Daunting.

When I learnt of this, I realized that the amount of time and effort it would take was too much for me to give at that moment. Family needs and other projects held precedence. Right now, I wouldn’t say those needs have abated, just that I’ve adjusted to both those asks, and I’ve given myself enough time and another factor for this migration – money. DigitalOcean is a nice provider in that they’ll only charge me for what I use through the number of days that I use it. I know this is sort of the norm everywhere now, but it’s a nice-to-have and a nice-to-mention nevertheless. Instead of doing the entire migration within the span of a few hours, tiring myself, and increasing the odds of a failed migration, I spread the entire project over the last few days. I moved my other WordPress install first, the one whose failure wouldn’t affect me directly and personally. It’s a side project that we’ve gotten side-tracked from. I’d be totally fine if it craps out.

Moving WordPress seemed daunting, until I realized that I have a tool that can make it extremely easy. I’ve been backing up this website to Dropbox using UpdraftPlus for the longest time. It’s fast, easy, and totally a background process which has not needed my input since I set it up. I checked it out and sure enough, it’s got a pretty straightforward restore process too, included in the free version of the plugin. Of course, they offer paid tools for much easier migration. But I reckoned the free one has got to work just as well. UpdraftsPlus creates a bunch of separate zip files for the database, uploads, themes, plugins, and “other”. All you have to do to migrate is to create a fresh install of WordPress, install the plugin and drop the files into the interface and then hit restore.

This blog’s backup comes in at about 750 MB, while the other site is about 160 MB. I did the latter first, and since it stayed up just fine over the last few days, while for the first time in my life I ran two VPS in parallel in DigitalOcean, I ported over this blog as well as the other applications and sites which I wanted to keep. It ended up being a good housekeeping too, since most of the active nginx sites were not doing anywhere and thus were liable to be security issues. Plus, it gave me a chance to really start from scratch.

Over the years, I let the older VPS grow organically and get cluttered as all in-use systems do. When I was attacked by a script kiddie trying to get into this site and wreak havoc (at which they partially succeeded), I installed fail2ban and went aggressive with it, to the point where I got locked out of SSH quite a few times and had to recover via console. I installed multiple versions of node to run shortlived telegram bots or expressJS apps. I installed numpy to create a webUI for an experiment my brother wanted to run. I also created a series of scripts to run via cron – to periodically free up space and memory, to pull in data and recycle logs.

All of this had become a sore point for me anyways. The services running on the VPS often went down. The APIs responded only half the time. The downtime was somewhat acceptable till it wasn’t.

So this new VPS, well, I’ll run it as clean as I can for as long as I can. Of course, I’ll get hit by something or the other and I’ll have to respond with better security measures. But I wasn’t running any firewall before and ubuntu 20.04 seems to be running ufw by default, which is nice. I was also able to update PHP from v7.3 all the way to v8.0, which is nice, but came with it’s own set of challenges. One function in WordPress and another in a homegrown bookmarking tool were failing since they don’t work in PHP 8.0, so I had to spend some time figuring that out. But it’s good to have the latest software and to hope I’ll keep things updated better this time around.

All in all, a good experience. My old VPS is now sitting in shutdown mode. I’ll let it sit for a couple weeks, while I test out the new system and see if I forgot to move some settings or such. I know it’ll cost me almost twice as much for the month to run both machines in parallel, but it’s worth the peace of mind I’m getting.

Plus, this migration got me in touch with some projects I’d forgotten! I regularly use my liveblog, but completely forgot about “SomeDay”, a bookmark/linkblog of articles I didn’t finish reading and hope to, some day. It’s got an RSS feed and all, so maybe you can find something in there that you might want to read, today.

Links to everything currently hosted on my new VPS –

this blog

tempdeals.net

scratch.nikhco.in – a minimal writing tool with local browser storage and ability to start a TogetherJS session to collaborate with others in real time.

liveblog.nitinkhanna.com

someday.nitinkhanna.com – I haven’t read these articles yet. Maybe you should try?

Some quality of life improvements on my iPhone

When iOS 15 dropped, I noticed that it added a feature that Shortcuts could run on their own, without user approval every time. This is a pretty major change to the way they were working before, and allows for some truly good automation.

A few months ago, I created a folder in my Photos app called Wallpapers and added subfolders called Morning and Evening. I created automation that runs at Sunrise and Sunset and sets a random wallpaper from the folders as the lockscreen wallpaper. It’s a nice way to update my lockscreen frequently.

Over time though, I got bored of the same few wallpapers, so I’ve created two more automations – these go out to source.unsplash.com and pull wallpapers using simple search terms.

Unsplash has run their free Source endpoint for a long time and even though it’s technically deprecated, they don’t prevent it’s use if you know what you’re doing. The search terms I use are –

https://source.unsplash.com/1080×1920/?Morning and

https://source.unsplash.com/1080×1920/?Sunset

Note that if you put the search term as “Evening”, it leads to some particularly Non-Family Friendly results.

So now, I’ve got 4 automations – on Mondays, Wednesdays, and Fridays, I set Morning and Evening wallpapers from my local folder. On the rest of the days, I let Unsplash send me some nice wallpapers for my phone twice a day.

The best part of this is that the wallpapers from Unsplash don’t get downloaded to my phone and clutter my photos. They directly get used as wallpapers.


The other quality of life improvement I’ve made is webapps!

At some point, I found this shortcut which lets you create a fullpage standalone browser app icon on your iOS homescreen for any URL or website you pass to it.

I had just installed Amazon Luna and rocketcrab as webapps using Safari’s Add to Homescreen feature some time before that, and really like how they come off almost as proper apps (as good an app as Amazon can make, and they make some spectacularly terrible apps).

When you try to turn a website into a webapp but it doesn’t support this feature, it opens in a new tab in Safari, which takes away from the feeling of a standalone app. But the shortcut above solves that problem!

It creates a webapp using a configuration profile, which you then have to go into the settings app to accept. It’s an unsigned profile, so the risk is all yours. But you can look at what the Shortcut is doing and let me know if there are any security concerns.

One caveat – the shortcut asks for an icon image. You better have one ready when you’re using the shortcut and it has to be more than 128×128 pixel. I tried an image that was 64×64 and the icon just turned out blank.

Since I discovered this, I’ve gone on somewhat of a binge. I made webapps (or Web Clips, as iOS calls them) of three webbooks I’m reading on and off (these aren’t available as ebooks in any way). I also often have to check up on my GitHub Actions runs of a particular secret project, so I made a webapp of that direct URL. I made one of my blog, so I can easily go into the admin section and make edits to my posts in the Gutenberg editor (which still doesn’t have proper support in WordPress iOS apps). The only one I haven’t made (and thus opens in Safari) is solitaired.com and that’s basically because I got lazy. I’ll make it one of these days.


From the time I started writing this post, I made another improvement.

I don’t really like Wallpapers cluttering my photos app. Over time, they make a mess, the good ones used to get lost when I moved phones, and overall, it’s a lot of pain to manage them in the Photos app, which needs a long overdue overhaul, Apple.

I figured out that I can make a shortcut that actually picks a random file from a folder in the Files app. So I moved both the Morning and Evening folders to the iCloud Drive and now I can add any good wallpapers I find on my desktop to my phone too! 🙂

I like when things fall into place nicely like this 😀

Cover art is from emoji.supply, which is a ridiculously awesome source of emoji based wallpapers!

Ev gives up. Yay!

black text on gray background

Ev Williams Gives up

No schadenfreude, but I’ve always thought that Ev Williams and the other twitter ilk were never too good at execution. Someone, somewhere along the story of twitter helped make it what it is, but neither Jack, nor Ev have been amazing at the business side of things.

But a former employee of Medium says it much better than I ever could –

I don’t know what’s in store for Medium, but it could have been a lot more than what it is today. Yes, the blogosphere is overcrowded. Yes, the true spiritual successor of WordPress is Ghost (or it’s Gutenberg, if you ask automattic). Yes, blogging is such an essential activity to the web that if every free and open source and well made CMS were to disappear tomorrow, someone would start making another one from scratch almost instantly. (heck, I made two for my personal use!) So where does that leave Medium? I don’t know.

I like the insight this write up by Casey Newton gives into what Ev thought he was doing with Medium.

To think that he can “fix the internet” and “increase depth of understanding” are grandiose plans if what you’re going to do is start a blogging platform that’s half-baked on day one of launch. Medium is often like LinkedIn now – it’ll throw up a soft paywall and you can just wander away and get your information fix elsewhere.

I do hope better things are in store.

Reposting with WordPress

I wish WordPress had an easier way to repost things
— cdevroe.com/2022/04/06/11083/

WordPress does, sort of, have an excellent reposting feature. But it’s wrapped up in a Quote Repost feature. After all, what’s the point of linking to something without commentary or context?

Also, WordPress.com seems to have a much better reposting feature. But to me, that’s a social network and while we bloggers may be social, we’re solitary creatures too.

The Open Web can learn comment moderation from Instagram

Instagram

Starting today, you can protect your account from unwanted interactions with a new feature called Restrict. Bullying is a complex issue, and we know that young people face a disproportionate amount…

Source: Empowering Our Community to Stand up to Bullying – Instagram

 

Bullying is about power and perception. When someone cyberbullies you, the idea that other people can see the comments and choose to ignore them, which makes bullying banal, or even someone else’s comedy, that idea is sometimes more hurtful than the comments themselves.

What’s interesting to me is that Restrict is a rehashing of a system that has existed since forever on the Open Web – comment moderation. The ability for a blog to not show a person’s comments has existed forever, and due to the lack of transparency and user-feedback in companies like Facebook and Google, has largely been ignored until they get to it.

However, Restrict is an improvement, depending on how they’ve implemented it. In blog comment moderation, the bully/poster sees and knows that their comment is under moderation. This gives them cause to go and continue their bullying on some other platform.

Restrict seems to make it so that the bully will not find out they are under review. This is a powerful tool, because the perception for the bully will be that other people saw their comment and ignored it, thereby removing the feedback loop that pushes them to bully more. Simultaneously, for the bullied, it will tell their subconscious that their community has not abandoned them in favor of the bully, because the community can’t even see the bully’s comments.

If this is how it’s implemented, and if it is successful, I’d say this is a good thing for the Open Web and for comment systems like Disqus and WordPress to also implement. Taking power from the bully means letting them think that their ‘hot takes’ have been ignored by bystanders. In this case, perception is power, and the bullied should be able to wield it.

Giving up on WordPress embeds

Back in 2012, I wrote a post called Conversations as a future of blogging. Well, I say I wrote, but actually I must have had a conversation on this up-and-coming platform called branch.com with a few people I invited to it from twitter. Using their tools, I embedded the conversation to my blog on the link above. I thought the embed would last forever, because a) where is branch going to go, and b) WordPress usually gracefully downgrades embeds, right?

Nope. branch.com died three years after launch. They gave us a period of time to request backups of our conversations. I remember doing that, but I never received one in my email. Perhaps they expected me to come back to their site to download the files? I asked all the other people involved in the conversation and none of them cared to request a backup of the copy. This goes back to my posts here about the futility of exporting your data from online services, even though in this case, a full backup was exactly what I needed to recover my blog post.

I was further wrong in that WordPress does no such thing with embeds. In the case of officially supported embeds, I’ve seen the system do this once before and I thought that was standard behavior, but in the case of link embeds, there’s no clear way for it to be possible.

Recently, I introduced a random post finder to my blog. With it, I’ve been discovering a lot of great and terrible posts I’ve written over time. It’s my way of getting closer to my blog.

But it has also left me reeling from all the broken links and embeds that I trusted to work forever. The branch.com embed, images and links I’ve linked to, PDF files I thought would never go away. Heck, even Facebook CDN stuff has disappeared and that company doesn’t let go of any data!

Recently, Automattic introduced inline GIFs from giphy through Jetpack. The model they’re following is pretty neat – they shipped the Gutenberg editor within WordPress 5, and have been extending it using Jetpack with blocks that allow various kinds of content, including GIFs. It shows the scope that Gutenberg has in the future.

Coming back to embeds, Giphy, the company Automattic is leaning on, came into existence in 2013, and I suspect will be out the door before its 10 year mark. Such is the way of life on the Internet. All of these are fads and fads can raise millions, but they eventually all die. Automattic will simply pull out the block from Jetpack and replace it with something else, but we users will be left with broken links and missing context on our blogs.

When the block was introduced some time ago, I played with it and added some GIFs to a blog post. It’s a lot of fun to express ourselves visually. But if branch.com is any indication, embeds come back to bite us later on.

Therefore, I’m getting off embeds. I’d rather download the GIF and upload it to my media. I’d rather take a screenshot of a webpage than to iframe it and hope it sticks around a few years from now. Jetpack already has a massive CDN operation behind them, so you’re never really serving your content directly from your site if they can help it. So there’s no need to worry about storage and bandwidth issues.

As I go through my site, rediscovering old posts, I’ll keep coming across these embeds. Whenever I have context, I’ll try to replace it with relevant information. But, as in the case of branch.com, I will just put a note that explains what happened there, some general thoughts on the topic, and move on. Once bitten by embeds, twice shy now.

Don’t Moleskine your blog

Have you ever seen people using a Moleskine notebook in public? You can see them using a fancy pen or pencil, writing in beautiful cursive, making excellent sketches, drawing straight lines without scales, right into their beautiful overpriced notebooks. It’s a gorgeous and truly scary sight.

I’ve never been able to buy a Moleskine notebook. I’ve often come across them in shops and stores, but every time I flip through the well weighted, elegant pages, which can give you paper cuts all day, I realize that I’m not worthy of a Moleskine. My handwriting is terrible. My ability to sketch wouldn’t save my life! Besides, the most important thing I want out of any notebook is the ability to scribble random ideas, or write small notes into. I want to just dump chicken scratch and small paragraphs in, without having to worry about elongating, or writing perfectly. Do I furiously scratch out words as I’m writing? All the time.

Would I ever want to use a Moleskine for that? No.

I recently came across this post by Jeff Perry –

It got me thinking – do we sometimes treat out blogs as Moleskine notebooks? Do we worry that we must only present our best writing on them, instead of just putting our ideas out there, perfection be damned? Yes, we do. We write entire posts and then save them in drafts, only to forget them forever. Either we’re not proud of our writing, or we’re not sure if it’s the right time to publish them, or we’re unnecessarily being perfectionists. Whatever the reason, what happens when you open your blog the next time? You come to the homepage, or the admin dashboard, and what do you see? The drafts? No. That’s a hidden page somewhere, totally ignored. So we move on to the next idea, and then the next, until our creativity is stifled and our spirits dampened by the lack of publishing. Why do we do this? Because the home page of our blog, at least in our minds, is a public space, and on it, only our best work should be displayed. But this is not true. CMSes allow two states – logged in and logged out. When you’re logged in, your blog’s home page is, in fact, not a public space, but a private one. Most of us do not realize or understand this, let alone capitalize on this simple idea.

I learnt about this problem in 2017 and solved it for myself. I want to share the idea with you, dear reader, so you can also stop moleskinning your blog. I’ve alluded to me writing this post before, specifically mentioning a key aspect of my solution – that when you see my blog’s 2018 archive, you see 25 posts, while I see 59. Yes, that’s thirty four posts that are not sitting tucked away in a drafts folder, but active and alive on my blog, albeit only for me.

Here’s how – this plugin on WordPress can set the default visibility of every new post you create on the web to Private. If you’ve never done this before (and I had not, till I discovered this solution), go ahead and manually try it now. When you change the visibility of a post to Private, WordPress immediately changes the save prompt from “save as draft” to Publish. You can finally get it – you can hit that Publish button and get that sweet, sweet rush of publishing something, but you can also get the freedom to read your post after some time, catch a few errors, a sentence you don’t like and such, and finally, when you’re happy with it, you can publish it publicly, which, by then would be a much smaller cognitive step than publishing it for the first time.

Side note – I’ve long recognized that seeing your blog posts on the front page of your blog, with theme and all, is a much different experience than writing and editing inside a text area and then publishing it. The feel is different, your eyes move differently to that beautifully set font, but most importantly – your mind responds differently.

I’ve tried hard to capture this feeling. A few years ago, when I found out about front end editors, I tried every single one I could get my hands on. One of my favorite ones was Barley. It was very well built, and a charm to work with. But front end editors come and go. Besides, the mind’s response to an editor is still that it is just that – a workspace. Even in the look and feel of my blog’s theme, the words seemed to flow differently when they were in edit mode.

I’ve been excited about Gutenberg since it was announced. But when I installed it in beta, it was horrible. However, the first release was actually quite good for me. For some reason, when I turned on SSL on my blog, one of the Gutenberg JS files crapped out (probably something to do with bad caching) and I can’t use it any more for post creation. I’ve gone back to the Classic Editor for now.

Just as well, because I noticed that when I was using Gutenberg, my willingness to quickly pound out an idea to the blog actually went down. Maybe it has something to do with the fact that the Private Posts by Default plugin only works on the blog when using the Classic Editor. That’s because it uses JavaScript to change the visibility setting on the fly. It’s a little silly, but it’s a better solution than the other hacks I’ve found, including a database script that’s changes the visibility setting as soon as you actually publish a post to public <shudders>.

Coming back from that long winding side note, when you’ve published a post to private, go your blog’s front page and just read. Be a consumer. Be a reader. The first time I did that, I found two spelling mistakes I’d made towards the end of my post. It’s so much easier to do that when your mind is just casually glancing at words instead of trying hard to be creative and write. The second time I did it, I was able to find a few sentences I hated reading and edited. Immediately after I made the edits in both the cases, I changed the settings to set the visibility to Public and published my posts. I’ve even used this process to sit on a post for a few days, slowly edited it every day, till I was ready to hit publish. Of course, you need to be careful to set the time and date of publishing to the current time and date instead of the value it’ll actually be – the time when you first hit Publish.

You don’t have to use the plugin. Whenever I’m on the WordPress iOS apps, I just head to the Post Settings section and quickly set the visibility to Private.

As I said before, stop moleskinning your blog. It’s not a perfect, pristine place which must always reflect the best work you’ve ever done. It’s alive. It’s a creative space where your ideas should stare you in the face so you can always work on them, and when they’re presentable, you can show them to the world. If you don’t ever want to, that’s fine too.

p.s. I let this post marinate on my blog in private mode for one night. According to WordPress, I have edited it twelve times after the initial publish. ?

A year with Facebook

A year ago, I decided to change my relationship with Facebook. I decided to be more active on the network, but not in the way Facebook would want me to be – commenting, liking, browsing, and clicking more.

I wanted to use Facebook to put out my thoughts more. So I actively started blogging more and putting it all on Facebook, a practice I had stopped for a while because I wasn’t getting anything out of it. I did another thing – something I’ve often been told off for, but I just wanted to experiment with – I connected my twitter account with Facebook. The benefit? All my tweets (and quote tweets, which is a little silly) started getting posted to Facebook. This meant that each passing, silly thought, which we often toss into the void, became instantly visible to my real life friends.

In a way, I did do all the things that would be considered an increase in Facebook activity – I have spent the past year listening to a podcast called Philosophize This! The podcast has an accompanying community on Facebook. Though I didn’t interact with the community much, I did become a part of it. I also found a community relating to an app I use a lot – Day One. The community also chugs along, though I’ve not derived as much value from it as I would like.

I also started using Facebook a lot more. There was a time when I would gleefully count the stupid notification counter on the Facebook website approach 99. I call it stupid not because I have prejudice against it. I like notifications. They’re an excellent approach to garnering attention. But somewhere along the way, Facebook decided that I am not a worthy enough user of their service and they downgraded my experience. They made the counter stupid by pushing every little activity to it. Things which belong in the newsfeed – someone posted something, someone liked someone else’s post, someone had a birthday – were suddenly in my notifications. But at the beginning of the year, I decided to be more proactive, hoping that the algorithm would notice this and rid me of the stupid notifications and only give me the smart ones. I’ll let you know that the algorithm is not smart. It never did recognize my contribution and that portion of the experiment quickly bombed. Now I don’t care what the notification counter says. Whenever it irks me, I click it to reset it and ignore the notifications. (They’ve added even more notifications now – friend suggestions, community posts; heck they’ve even added Facebook notifications to the Instagram app, because why ruin just one social network when you can ruin two?)

I even went ahead and actively started using Instagram. I thought, maybe one Facebook property will feed into the algorithm of the other? See above regarding algorithm smartness.

But the last thing, that of posting more, I did religiously. After my initial December 20th, 2017 post, I’ve posted 25 public posts on my blog, a marked increase over the 13 posts I made in 2017. The plan was that all of the posts would be posted to Facebook and the ensuing conversations, controversy, and opinion would all happen in Facebook. After all, only if I contribute more to the platform, will I reap the rewards of the happiness that are supposed to come from it.

I also definitely did not delete any (well, most) of the tweets that got pushed from twitter to Facebook. I don’t like posting about political stuff openly. It’s like religion, everyone has one, and it’s best kept personal. But some tweets do get out once in a while. I believe I deleted those from Facebook. About 70 tweets made it to Facebook before disaster struck.

In the words of Hillary Clinton,

What Happened?

Well, the year started off nicely. Posting to Facebook is certainly a good way to garner attention. Friends who often forget that I have a blog were reading my posts and sometimes even clicking through to come to my actual website to check it out. The fact that Facebook discards in-text HTML, thus removing all URL references from a post both helps and hinders. It removes all context, but it also means that astute readers realized they had to click through.

I don’t have a lot of unknowns on my Facebook account. I do have a bunch of acquaintances, and people I haven’t met in years. I’m not a particularly social person irl. But everyone on there is someone I know or knew once. So it’s not like I was able to appeal to the masses and drive ‘traffic’ to my blogs. What I did achieve is a meager amount of conversation – a few likes and comments per post.

This extended to both types of posts. Folks who had never heard me express things about the random topics I post about on twitter and other microblogs, suddenly had access to my thoughts. Some reacted like idiots, some had positive or negative comments, and some just hit like and moved on.

All this stopped on August 1st. The declaration came in the form of a blog post by Facebook on their developer portal on April 24th. It was hidden between a bunch of other deprecated APIs, which I’m sure broke a lot of other things for other people. At the time, a huge noise rose, specially in the WordPress world about this. A lot of blogs depended on this API to post to Facebook using either the Jetpack plugin or the dlvr.it service (or other, similar services). Matt Mullenweg commented on the change, hoping that Facebook will reverse their decision and re-embrace the open web, to which this decision shuts the doors. But that’s not Facebook’s way. I reckon they heard him once in 2017, so they’re done listening to him for a decade.

I didn’t bother with finding workarounds to this problem. Smarter and more dedicated people than me would have found ways if there were any. Regardless, I wrote a blogpost on August 2nd and manually posted it to my Facebook profile on August 11th. This was my last cross-post from twitter or my blog to Facebook. It did not get any likes or comments.

According to some people, removing this API is important in helping fight the corruption that was revealed in the Cambridge Analytica scandal. But from what I can see, removing the ability for content to come in through legitimate sources is certainly not the way to go if you want to increase trust in your system. This was just a random move by Facebook, which is running around in headless chicken mode right now. It would be better if it were actually headless right now though, because the current head is part of the pattern of problems that Facebook manifests in this world.

Regardless, my year-long experiment ended mid-year.

The outcome of this experiment was this – I fell in love with the written word again. I also fell in love with my blog again. Though I now have newfound respect for a few things – first of all, I’m glad that my twitter is no longer connected to Facebook. The stream of consciousness that goes into twitter is not at all suited to Facebook, even though it should be, and for a majority of the world this has been a learning curve. Rants and raves belong to the place where outrage is common. You put it on Facebook and you alienate friends and get fired from jobs. While none of that happened to me, the effect was clear – people who I’ve never bothered to talk to my every day thoughts about were suddenly talking to me about them whenever I met them. This was… awkward. So I’m glad it’s no longer happening.

The second thing I’m glad of is discovering a rather important aspect of WordPress – private blog posts. While I’d like to talk about this more in another post, the overview is this – when you see 24 published posts for the year of 2018, I see 58. My process used to be that I would write a post and just leave it in drafts if it didn’t feel ‘complete’. This was wholly unsatisfying. Now, I privately publish my posts, giving them a timestamp that helps me date my thoughts. I also believe deeply in the concept of the blog as an Outboard brain as once proposed by Cory Doctorow. Though not as vibrant and well published as his blog, Boing Boing, my blog is my space, and having things published and showing up on the home page of my site when I’m logged in means I get to think about those things more.

What happened on the Facebook end of things? I noticed that the folks who interacted most with my posts were the same over and over – friends in the US who share my time zone, and some in India who I frequently interact with on Facebook. But what happened when the posts stopped? Nothing.

No one noticed. No one pinged me and asked me what was wrong with my blog and my tweets. Part of this is just the way the internet operates. Even with the extensive RSS setup I have, where I follow a lot of amazing blogs, if one slows down, I don’t have an easy way to figure it out. Time spent on the internet gets filled up by whatever is available.

The other half of this, I blame on Facebook. Their algorithm has become too smart for themselves. A willing user such as I should be able to push my posts to my friends without acting like an SMB and paying them money. In the same breath that they turned off the wall feeds, they promoted creating a separate page for one’s blog. This is a bad approach. For Facebook, it makes perfect sense – they can easily show hundreds of thousands new pages being created within the year, with all that untapped potential for paid promotions. That money will never come. A blogger such as I would rather trust the open web as a source of feedback and views than Facebook, whose track record for respecting ad spend is poor if not terrible. Facebook is a hungry beast, always looking for its next fix.

I’m tired of being Facebook’s fix. I don’t care for it any more. I have had an intense love for it as a platform at one time. I’ve been in awe of the leadership at one point. But now the spells are broken. 2018 was a journey, both public and private, in trying to see where Facebook goes. For me, it’s led itself to a dead end.

postscript – I opened Facebook recently, after perhaps a month, and a few things jumped at me. First of all, Facebook wished me for being with them since ten years. I think that’s serendipity. No social network online has a good life of more than a decade. Facebook should be no exception. While the company has morphed and plundered and established itself as the place to go to steal access user data, it should know that its main platform is tired and done for. I will slowly stop visiting and interacting with it. I know a lot of people have done this in 2018, but I still have derived some utility from it, so I’m sure it’ll feel somewhat bad to do so. On a new device I setup recently, I specifically made it a point to uninstall Facebook (it came preinstalled for some reason), while I did install Instagram. I know this is counter intuitive, but this is a signal from me to the company that it’s time to retire your aging platform or at least break it up instead of amalgamating into it. Facebook’s ugly attempts at driving people back towards their main property are so transparent that they should accept that it’s time.

The second thing I noticed was that Facebook had killed off an ugly experiment it has forced me to be a part of since two years – the Facebook marketplace and Video tabs. The main app has had these tabs since the beginning of 2017 for me (ymmv) and I never used them. I’ve looked forward to the day Facebook does *one* smart thing and recognizes that users would like an experience that’s suited to their needs instead of Facebook’s. By the way, for a brief time last year, when I discovered the Facebook groups app, my daily activity on Facebook actually increased, because I was able to get an ad-free, clean, groups-only experience of Facebook. Then FB killed off that app. So it goes. I’m glad that Facebook has removed its craigslist clone from my Facebook experience, but I didn’t celebrate it the day I saw it. Too little, too late.

Some thoughts on WordPress 5 and Gutenberg

Ok, this is me trying out Gutenberg after it’s full GA release. Let’s see how well it works. This entire post has been written on Gutenberg on Firefox on Windows, saved, privately published, and then edited on Gutenberg on Firefox on Mac, and published publicly. Yay.

Hmmm. There are some interesting quirks. The private publishing thing is available, so potentially there’s scope for the private posts plugin to be updated for Gutenberg. I like this plugin because every post is private by default and that gives me the freedom to publish immediately and edit later.

On a rock, undecided.

There’s an oddity here that might be useful to most people – when you start editing, the menu on the right shifts from Document to Block, so you can quickly change the Block settings if you want. That’s nice and all, but the switch is irritating to me. Maybe in a while I won’t even notice.

Other than that, it’s definitely performing better than it was last time I played with it, when it was in beta. That time, it just completely soured my experience because it kept crapping out on me. But this time, it seems stable and I can actually type a sentence without being constantly kicked out of the editor.

This is a title. Yeah, I know.

LOL. I just noticed that Gutenberg has support for drop capping. I don’t think I’ve ever had it before in my blogs. Interesting!

Is Gutenberg supposed to be useful for longform writing too? I don’t think longformers care about inline images. Also, the whole moving text up or down thing doesn’t make much sense to me. It’s just a weird concept. Maybe it’s useful to speech writers or essay writers – they need to present ideas in coherent ways, with each paragraph a complete idea. So technically, they could massively benefit from being able to move ideas around quickly for the overall coherence and flow of the thing they’re writing.

Wait, does Gutenberg not have autosave? The Classic editor does. It does it every time you stop writing for a significant and noticeable amount of time. But Gutenberg just seems to sit there.

I hit the gear icon and the right side menu disappeared. That’s good. More screen space to focus on writing, even though all the writing is happening within this one central column.

I wonder if Gutenberg would be useful to Instagram poets. Does this allow you to place text anywhere on the page? That might make a very pretty ‘flow’ thing that would work beautifully! If it doesn’t exist, someone should make it!

I really like Unsplash for pictures now. It’s not always on point, but there are some gorgeous pics out there! The Instant Images plugin is also nice – it doesn’t play with Gutenberg, but it sits outside and so it’s easy to add an image and then come to Gutenberg on an already open post and just click on the image block to pull the latest images. That seems to work well. My main problem with the plugin is that it’s got a max image size. They’re just trying to foster consistency, I think. But for an image that’s 5000×4000, to bring it down to 1600×1200 max size is a little irritating. But it does the sizing well actually. No graininess there! (Except maybe the graininess introduced by my theme)

Inline images in Gutenberg aren’t perfect. They don’t do everything as advertised, which will put more pressure on theme devs, I think. For example, the three images in my post till now don’t quite align the way I see them inside the editor. Weird. I wonder how they’ll look if I exit the editor and come back?

Embeds are separately supported now, as a block for each one of them. Nice. Good exposure to functionality. Earlier it used to be – use this shortcut and put the url in there in this format, and then do this incantation to call upon that demon to embed stuff on your blog. Now, it’s just there. Might actually cause an increase in link embedding across WordPresslandia. Maybe. Let’s see. I noticed after publishing that the embed doesn’t look the same inside and outside. Jeez. I think the embeds are a feature of Jetpack and that needs to be further updated to work properly with Gutenberg?

Instagram embedding did not work. Maybe because my blog isn’t https? I dunno. It’s fine.

I wonder if Automattic is tracking Gutenberg installs and usage? They should. It’s pretty good to highlight usage in the first week, first month etc.

edit: When Gutenberg opens in edit view (or maybe this is only on Mac), the currently being edited block is highlighted while others are faded out. That’s nice for focus, but weird for reading and revising

edit to that edit: I realized this is called Spotlight mode. Now, why is Spotlight mode active on my Mac and not on Windows? Don’t tell me there’s small JS differences which the devs have not reconciled yet.

edit: Gutenberg is NOT a happy camper on the Mac. I can move the central edit column horizontally in a not-so-good way. Separately, the dropcap paragraph, when it moves into edit mode, removes the dropcap in a very ugly way.

Verdict: I’m keeping Gutenberg on for a while. A few more posts it in. Let’s see. I already have the Classic Editor installed and I might just go back to that if I don’t see a lot of value in Gutenberg, or if I see a lot of noise in it.

That’s all folks!


Fixing Jetpack’s Stats module

Despite the hate that Jetpack gets for being a bloatware plugin, it is one of my favorite and the first step whenever I setup a new WordPress install. However, Jetpack does have a few irritating habits that I cannot overlook. One of these is the stats module. The module actually does pretty well, posting data to the wordpress.com dashboard and making it easy for me to quickly glance at the number of visitors I’ve had for the day.

However, every so often the module craps out and logs a large number of visits from crawlers, bots and spiders as legitimate hits, since those are not in the official list of crawlers, bot and spiders to look out for. To fix this, I went out to look for the list and to add to it. One quick GitHub code search later, I found that the file class-jetpack-user-agent.php is responsible for hosting the list of non-humans to look out for. What I found inside was actually a pretty comprehensive list of software, but one that definitely needed extending.

If you want to do what I did, find the file in your WP installation at –
/wp-content/plugins/jetpack/class.jetpack-user-agent.php

Inside the file, look for the following array variable –
$bot_agents

You’ll see that the array already contains common bots like alexa, googlebot, baiduspider and so on. However, I deepdived (meaning did a sublime text search) into my access.log files and found some more. To extend the array, simply look for the last element (which should be yammybot) and extend it as follows –
'yammybot', 'ahrefsbot', 'pingdom.com_bot', 'kraken', 'yandexbot', 'twitterbot', 'tweetmemebot', 'openhosebot', 'queryseekerspider', 'linkdexbot', 'grokkit-crawler', 'livelapbot', 'germcrawler', 'domaintunocrawler', 'grapeshotcrawler', 'cloudflare-alwaysonline',

Note that you want to leave in the last comma, and you want all the entries in lower case. This doesn’t actually matter, because the PHP function that does the string compare is case-insensitive, but it just looks neater. You’ll also notice that I’ve added the precise names of the bots, like â€˜grokkit-crawler’ and â€˜clousflare-alwaysonline’ but you can be less specific and save yourself some pain. This will, however, affect your final stats outcome.

Notes –

  1. Some of the bots are pretty interesting. I saw tweetmemebot, which is from a company called datasift, which seems to be in the business of trawling all social networks for interesting links and providing meaningful insights into them. Another was twitterbot. Why the heck does twitter need to send out a bot? We submit our links to it willingly! Also interesting were livelapbot, germcrawler and kraken. I have no idea why they’re looking at my site.
  2. Although Jetpack does not have a comprehensive list of bots, it still does a pretty good job. I found the main culprit of the stats mess in my case. Turns out, CloudFlare, in an effort to provide their AlwaysOnline service (which is enabled for my site), looks at all our pages frequently and this doesn’t sit well with Jetpack. I hope this tweak will fix this now.
  3. Although this fix is currently in place, every time the Jetpack plugin gets updated, all these entries will disappear. That’s why this blog post is both a tutorial for you all and a reminder and diary entry for me to make this change every time I run a Jetpack update. However, if someone can tell me a way to permanently extend Jetpack, or if someone can reach out to the Jetpack team (hey Nitin, why don’t you file a GitHub issue against this?) it’ll be awesome and I’ll be super thankful!

Update – I was trying to be hip and did a fork of Jetpack and GitHub, made the changes and then tried to make a pull request. Turns out, I don’t know how to do that, so I opened an issue instead. It sits here.