Subscribe to Personal Log via RSS and find other blogs to read in my blogroll.

Aioe.org public news server

I was talking about Gemini here some time ago, and the official website. As part of the “official” resources there was a mailing list to discuss the protocol, make announcements, meet other users, trolling, and things like that; but something happened to it –there are some comments of being dead and not coming back–.

Some people immediately recovered a copy of the archive and put it online, and even there were some attempts of adding a “public inbox” to replace the mailing list, but it doesn’t look like they went too far.

And then seems like things moved to comp.infosystems.gemini –I don’t know the full story, looks like the newsgroup was already available–.

Of course that the Usenet newsgroups still exist and they are used –even if is not as much as in its golden days–, and you need access to an NNTP server to read and post messages.

Those services used to be provided by your Internet service provider when you got Internet access, and Google has a gateway via a web interface via Google Groups –that’s a Wikipedia link because Google requires account–. Anyway, I’m not going to do a history lesson here.

So, how do I access the Gemini group?

Turns out it is easier than it used to be, thanks to this public news server:

Aioe.org hosts a public news server, a USENET site that is intentionally kept open for all IP addresses without requiring any kind of authentication both for reading and for posting. In order to avoid mass abuses, every IP address is authorized to post no more than 40 messages per day.

So basically I added a newsgroup account to Thunderbird and it 2 minutes I was checking the groups available, which is all of them.

What a time-travel experience! You don’t get all the archives, but it was fun checking that the es.comp.os.linux.* groups were still there – “ecol” is a big Spanish community of Linux enthusiasts that wasn’t that different of today’s tildeverse, established on 1996–.

The Gemini group is active, but like Gemini itself, things are slow-moving and it doesn’t have a lot of traffic. I have spent some time checking groups, and there are some that look active, but to me it feels more like the echoes from the past, like the “ecol” groups.

I'm on Mastodon

So there has been a lot of stir on Twitter after Elon Musk made an offer to acquire Twitter and take it private, and then he said he would fight censorship and protect free speech –in reference to Twitter’s moderation policies–.

Musk is a very divisive character, to put it mildly. So obviously, some users are unhappy with the situation and decided to move to Mastodon, which is an open source software for federated micro-blogging.

I’m not one of those, suddenly unhappy, because I could say honestly that I am always unhappy. I used identi.ca back in 2008, as it better aligned with my personal philosophy regarding software and freedom, but also because back then Twitter was a dumpster fire technically speaking –does anybody remember the fail whale?–.

The good thing about all this is that I decided to try Mastodon again. I tried it by the time I started this blog, but at that point I decided I didn’t want a replacement for Twitter. It was more that I didn’t want Twitter, or micro-blogging at all. So I went back to blogging and reduced my use of Twitter, acknowledging that it was still useful to promote my games.

Are things different now? Perhaps not that much, but I see Mastodon like a gateway to a community aspect that gets diluted on Twitter with big brands, outrage and news, all trying to get your attention and into the doom-scrolling that I’ve been avoiding since I reduced my Twitter usage.

Yes, the user interface is different. Some bits are still not there –the official Android app can’t take pictures, only upload them!–, and the federation makes other parts awkward –can’t see a user’s followers because they are on a different instance, or following a user from other instance if you are in your instance is one click but much more complicated if it happens in their instance–. But all that is fine, because it is open source, an that’s something Twitter can’t compete with.

I know that most of the angry people leaving Twitter don’t care about the same things I do. I don’t expect that the average user will suddenly understand why open source is good; those are the ones that complain about the user interface being different, and it is likely they won’t stay around. I have the feeling that it is always the same: rants and moans –on Twitter!–, for things to always stay the same.

Anyway, let’s see how this goes for me.

One of the trickiest things about a federated service, like in the case of XMPP –aka Jabber–, is that you need to choose an instance. I have an account on the SDF instance. I decided to go there for two reasons: I got a shell account with them –and also in ctrl-c.club; which is a story for a different post!–, and they started hosting StatusNet (aka identi.ca) back in 2010 before moving to Mastodon in 2017; so looks like they are trustworthy and likely to stick around for a while.

In case you want to connect on Mastodon, you can find my mastodon address in my about page.

Playing Pokémon Ruby

After we quit playing Breath of Fire IV, we went back to Lenna’s Inception –which is an interesting game, written in Scala! we are in the final-ish boss, will talk about it soon–. But is not ideal to play with the kids, because they still don’t have the skills for such an action game –some bosses took me a good number of attempts–.

So we were looking for a new RPG to play, and because we have watched a few seasons of Pokémon on Amazon Prime, it seemed a good franchise to try. One of the first seasons we watched was “Pokémon: Advanced” –first aired on Japan 20 years ago–, and that season is apparently paired with Pokémon Ruby on the Game Boy Advance.

The graphics are super-cute, the GBA is easy to emulate –I have a GBA, but I don’t have this game, and the screen isn’t great by today’s standards–, and the kids are very familiar with the Pokémon of that series, so on a lazy Saturday morning, we decided to give it a go.

Recharging

Recharging Pokémon after a battle

I don’t know how far we will get, but we are around 10 hours into the game –after a few short sessions–, with two gym badges, and a good set of Pokémon over level 15. Which is definitely more than I was expecting!

I’m not going to make a full review of the game here, but I’m surprised how deep the mechanics are. It is all simple on the surface: you can walk in tall grass to find Pokémon, battle other trainers, and move from town to town fighting the gym leaders to get badges; but that simplicity is perfect to pickup and play. There are some quests, but looking on your inventory you get clues on what to do next. And all very family friendly –you don’t kill Pokémon, they faint–.

Battling

Each Pokémon has its own strategy

And the combat is what I’m finding the most interesting. I have listened to some podcasts talking about the game, and most refer to it as “rock-paper-scissors” mechanics, but that is probably simplifying too much.

Yes, there is a lot of that. For example: a water Pokémon with water moves is strong against a fire Pokémon. Early on things aren’t too fun because the low level Pokémon have only two moves, but when you start to have move options and you need an strategy to win a battle where your opponent is stronger than you, it is clear that the mechanics are deeper than that.

Is not only fun finding those strategies, it is also very satisfying when you make a difficult battle easy by combining some moves in a way it wasn’t obvious when you first met that opponent.

So far I think we have barely scratched the surface –the main story is about 35 hours–, and it is possible we will get bored, but so far we are enjoying it. And I’m learning a lot of game design!

The IndieWeb

According to the IndieWeb website:

The IndieWeb is a people-focused alternative to the “corporate web”.

Which doesn’t explain too much, only that this is against big corporations providing the platforms where we do the social web of web 2.0.

Thankfully, they provide a list of three points:

  • Your content is yours.
  • You are better connected.
  • You are in control.

And I thought initially “OK, so the IndieWeb is what we used to call the web”, but that’s not exactly true. What I knew as the web initially depended on someone hosting your content, in the likes of GeoCities, Angelfire or Xoom –that are the ones I knew most back in the day, all of them free–.

Initially I thought the IndieWeb places us perhaps a bit later than that, when hosting started to be cheaper, and reading the getting started page, in order to join the community you need your own personal domain, a place to host your content, and setting your own home page and other “indieweb essentials”.

Which is more or less that I did in 2002 when I got the usebox.net domain, trying to establish a stable presence on the Internet for myself and a small group of friends. It was not only about a website, email was also important –although that may be out of scope for Indie Web I guess; hopefully doesn’t mean they are happy with Google owning their email, for example–.

But that was a misunderstanding, because the IndieWeb is not about self-hosting –although is not excluded–.

“A place to host your content” could mean Blogger or WordPress.com, which I don’t know how it goes with “your content is yours”, but it makes sense if you want to move away from the corporate web. The message really is: don’t get your content to Facebook, instead own your blog with your own domain.

There is a lot more to explore, like for example webmentions. Although I suspect a lot of these things may not be easy now that this blog is a static site!

A patch for a 14 years old project

So today I received a heart-warming email that ticks all the boxes for me:

  • First of all, they thank me for publishing the software on the Internet under the GPL license.
  • The author is user of one of my projects.
  • They are happy, bogom and the bogofilter are useful for us, I used it more than 10 years (sic).
  • And they are sending me a patch!

Bogom is a milter, which is a type of plugin for some MTAs –originally Sendmail, but later Postfix at least added support–, that is used to filter email.

My milter was an way of using bogofilter, a bayesian filter –yes, all this is about filtering– that can be used to filter spam. When I wrote the milter there were a few ways of using bogofilter with Sendmail, but all of them were filtering email after it was delivered. Bogom was able to filter and give a response to the MTA trying to deliver the email, so the sender knew that the email was rejected. I thought it was neat.

You didn’t have to use it to reject spam, because it could just add a header with the result of the classification, but that was the main idea. It had a few limitations, like only supporting a database for the whole system, but looks like by being simple, it has been functional for 14 years after I stopped working on it.

In fact, I have checked, and it still exist in the FreeBSD ports under mail/milter-bogom; and it doesn’t include any patches, so it is being used as I released it last time in 2008. Amazing!

The patch adds a flag to select the logging facility. Bogom uses daemon, and the idea is that you can use syslog to redirect the logs to any file you want, so the patch is not really that useful; but on the other hand, why not?

The only problem is that making a new release of a 14 years old unmaintained project would require testing of something that, honestly, I haven’t used for quite some time –not 14 years, but almost–. So we will see.

For now, this email has made my day!

An E/N blog

So I was having a chat with my friend Oscar when he mentioned an old post on his blog linking to one of my posts in my old Spanish blog, that doesn’t exist any more. That led us to discuss broken links, and how things have changed in the blogosphere.

I took down my old blog last year after 18 years online, because I thought it was irrelevant and its old archive was kind of holding me back to write other things. So long story short, I started this blog and that’s where we are now. Besides there were some technical reasons for the change, because the old blog was running on an old and somewhat unmaintained stack –all my fault: a hand crafted blogging engine built on top of Tornado, with Python 2, and using Redis as storage; don’t ask me why!–.

Anyway, Oscar has also moved from his hand crafted blog engine (with Django, if I’m not mistaken), to an static site generator. But he has decided to port his old posts to the new blog, despite being a considerable amount of work.

It is an interesting problem, but we both concluded that, in reality, nobody cares about what we write or not in our blogs. And perhaps it is a thought for a different post, considering if anybody ever cared about our blogs –even if we had a different perception back in 2003 when we started writing–.

That conversation reminded me of this quote from E/N:

The website’s content means everything to the publisher, but it could mean nothing to the rest of the world.

Which basically sums up what is this blog, and perhaps any personal blog.

I write about things that I find interesting, useful, or are important to me. That might be useful to anyone visiting the blog, but is not essential!

Changing hosts

Recently I upgraded my VPS to Debian Buster, that is not the latest version, but it’s OK as long as is long time support and it still has support time. It doesn’t take long –around 30 minutes–, but there are some tricky bits to it because between releases the software I use will change and I may need to adjust my configuration files –some of them come from my first install around 2010!–. That’s the main reason why I don’t do these upgrades ASAP.

I thought everything was good, until I noticed some weird behaviour, and turns out I had missed some kernel oops after the upgrade of one of them: iptables wasn’t working. That hosting provider injects a kernel they control, and it looks like there was a mismatch between it and my new Debian system. So I opened a support ticket, because the kernel is from 2019 and it looks like it was pinned, so I thought I was not getting newer versions.

I know how things work on this hosting provider because I worked there for 6 years, and I wrote a big chunk of the code moving their cloud. I know it is changing a field in the admin console, and that takes less than 30 seconds.

Unfortunately my ex-employer was acquired by a larger hosting company, they let go all the dev team, and no further changes are planned for the old platform; and that explains why my server was running an old kernel. Although I understand the policy, I don’t think it is a good one. If that kernel doesn’t work with Buster, I’m sure other customers are experiencing other problems.

There is a path to migrate the services to a current platform, and it will be forced to everyone at some point; but it is unclear when I can migrate my server. Not sure why is that, but it is possible is not a fully automated process.

Anyway, as an ex-employee, my server was completely free, so I think it is fair to move to some other provider and leave them alone. I’m very happy and grateful for having that free service, I wouldn’t mind paying for it –after all, I know we built a good platform–; but I’m not sure about this new hosting company.

Yesterday I finally migrated all the services I had left on that box, and I’m ready to switch it off. And it is a bit sad. In a way it is my last ties with a company I enjoyed working for, and doesn’t exist any more. And that includes all the code I worked on during those 6 years.

That’s OK. Software becomes legacy eventually, and it gets replaced. It is a cycle.

Getting distracted

Making a game isn’t easy. Focusing on a game until it is finished and released, is very hard. It looks like I have been successful at doing it for the last 8 years or so, releasing at least one new game every year –sometimes two!–. And, honestly, I don’t know for how long I will be able to keep it up.

I tweeted this two days ago, and it seems to have resonated with people:

What if the real happiness was starting projects, work on them as much as you feel like, and then never finish them?

There are those times in my life that I feel very productive, like I would like to work on so many projects, including a few that I know are not going anywhere. Early signs of that is when I started to work in a CRPG –this time for the CPC, and I’ve got further than ever before!–, or my latest work with Go and Ebiten.

And a lot of other projects I shouldn’t start because it is likely I won’t finish them ever –a compiler for a toy language? sure!–, and it all makes me lose energy, momentum, and focus on the projects that I could finish.

Hyperdrive started back in November 2021. It is a difficult one, that needed a few rewrites of the engine before I got it where I wanted, but we are almost in April 2022 and there is still a lot of work to do.

I guess it really sucks feeling productive, because I get easily distracted; even if that may be the real happiness.

A wiki and Tagless Final

I’m still refreshing my Go, and my friend Oscar is meeting Go for first time. Having a chat, I proposed him a possible project that could be interesting to have something to work on as he learns. Because learning to program a new language requires programming on that language, and for that, you most likely need a project.

I guess it could have been a blog as well –and I know it because I wrote my own blog engine in PHP, Perl and Python–, but I contributed a spec and Oscar is working on wikingo now based on that.

Looking at Oscar’s code, last weekend I thought: why not give it a go using Scala and some of the tools I work with at my day job but I never have time to do other things with?

So I wrote a toy wiki with Scala, http4s, doobie, ScalaTags and CommonMark (to render the Markdown), and using Tagless Final pattern –some context in the Expression Problem, and I haven’t found a “good” resource to link–.

Tagless Final is a pattern in functional programming, and is just an abstraction to build software, in which you define a Domain Specific Language (DSL) using Algebraic Data Types (or ADT, for example: a generic trait with abstract methods), and then provide an implementation (also called interpreter).

// my DSL
trait Wiki[F[_]] {
  type R = TypedTag[String]

  def init: F[Unit]
  def getPage(id: String): F[Option[R]]
  def editPage(id: String): F[Option[R]]
  def savePage(id: String, body: String): F[Int]
  def searchPage(query: String): F[R]
}

And this is relevant because http4s is built on top of Cats, which is a library for functional programming in Scala borrowing ideas from the Haskell programming language, and supports Tagless Final nicely.

Anyway, if what I have written so far doesn’t transmit the idea that is complicated, let me tell you: it is!

My expectations was to put together something quick and easy, but I got myself stuck in the same problems I have often encountered in my day job.

Some notes:

  • Missing documentation and examples –if you are trying to do something not in the docs, it isn’t easy to discover things yourself–. This was specially painful when trying to decode the form data: I was missing an implicit, and even looking at the examples, I didn’t see that my type F was asking for Sync but I really needed Asyncfacepalm–.
  • Because I decided to use H2 as database, I got stuck a couple of times with doobie –always my fault, if you use H2 as an in memory database, remember to set DB_CLOSE_DELAY=-1 in your connection properties, or your DB will be wiped mysteriously–.
  • I got stuck finding a mapping for Java’s LocalDateTime in doobie, even if I knew there has an implicit somewhere. The answer is deep down in the FAQ, instead of being included in the part of the docs that deals with mappings.
  • Turns out there aren’t many current Markdown to HTML libraries, CommonMark works fine –although it is a Java one–.

The end result looks very nice. Is not that different from a Model View Controller pattern: Wiki provides a description of the controller, with implementation in impl. It calls the models –implemented with SQL in WikiSql–, and maps to the views in WikiTemplates. WikiServer has the router that calls the controller. Concise yet very readable.

So I didn’t dislike the result, but oh it was hard to get there!

Re-learning Go

As I mentioned in you learn by doing it wrong, I was thinking that perhaps it would be a good idea to work on a CRPG targeting a modern platform, because it would be easier to fail faster than with my current approach with the Amstrad CPC.

I had started all the infrastructure to start writing code in C using SDL2, with the latest version compiled from source, and I was almost convinced that I wanted to use C. I even had researched some libraries that I would need to work comfortably. Being a modern platform, there’s no point on suffering the same struggles of making software for an 8-bit.

But then I remembered that, no so long ago, I was looking for a language that was higher level than C, compiled to native code, and ideally supported cross-compilation –at least let me build Windows binaries on Linux–.

I started looking at Haskell –because it would be also useful in the context of my day job, where I write functional code in Scala using ideas borrowed from Haskell–, but I got bored pretty quickly by the book I was reading. Then there’s that Rust language that the new kids are always talking about, but I have the feeling that it would be unlikely that I could use it professionally.

Then I remembered that I wrote a good amount of Go before moving to Scala –professionally–. Back then I thought Go was alright, with a few things I didn’t like, but it was mostly down to some tooling or the way the Go community handled releases that I found it wasn’t my cup of tea. At the end I was writing C at home, with a lot of Python for my tools, so I kind of left Go behind.

I’m sure I learned about Ebiten at some point. “A dead simple 2D game library for Go”, and after looking at it I thought it was neat. But I wasn’t doing Go any more, so I didn’t dig too much.

The language has changed since then, and it looks like some of the things I didn’t like are better now. So I have decided to revisit Go, and give Ebiten a go –the Go jokes never end–.

I have a plan and I’ve been streaming on my twitch what I have been doing so far. With the new shiny toys for vim –for example: LSP–, the experience is quite nice and I have enjoyed it so far –mostly, the interface bingo is still tricky if you don’t know the packages–. We will see how far I will get, because I didn’t do anything after refreshing my Javascript.

I’ve been asked if the code will be open source, to follow along as I stream my sessions. That has been a bit distracting, to be honest, because doing things in the open as open source requires some effort. I’m not sure how to do it, if making the engine open and then make a game with it –very ambitious–, or just keep things simple and make a game –which may be a feat on itself!–.

As I say: distracting. In reality I don’t think I will write anything too exciting.

Meanwhile, my progress on Hyperdrive is steady. The engine is solid, I have one stage –complete with final boss!–, and I’m working on graphics and enemy designs for the second stage. I will stream more sessions working on it, but only when the graphics are ready.