5/27/2024 - devlog
Michi finishes the last implementation tasks of the upcoming release and talks about testing its features.
Michi (molp)
With the POL
command implemented (see #435), it was time to clean up. During the development of the parliaments update we touched and changed many systems: user, company, admin center, planet, population etc. Often these changes lead to code that needs removal because it isn't used anymore or sometimes a system needs additional polish to prevent future bugs and problems. Usually, the way I work, I tend to create tickets for these tasks if they cannot be fixed within a couple of minutes. I learned that the hard way: More than once I fell down the rabbit hole of "just fix this now", "let me quickly refactor that", "oh, what is that for?" just to find myself doing work I shouldn't do at that moment and complicating things unnecessarily.
So, this week, was for exactly these tasks! For example, I removed the rule that would only allow five local rules changes per term. I think it was introduced with the Expanse release back in 2019 to prevent a governor from spamming the inhabitants of a planet with frequent local rule changes. It would require a complete rewrite to migrate the rule to the new motion system, so we decided to scrap it and see what happens.
The entities in the game are loosely coupled, meaning that they can only send messages to each other and not call any methods directly. To do so, the id of the recipient is required and the underlying message service will send and route the message. It is even possible to route the message via a registry if the recipient id is unknown. There are many cases in which an entity needs to talk to specific other entity, think planet to admin center, or admin center to population. In these cases it is very handy to have the ids and not go through the respective registry. With the current release a few of these connections were added and I finally had the time to rewrite the discovery process that allows to fetch the id and store it locally for later use.
I then moved on to test the migration to the parliaments release locally on my machine. That means wiping the database, starting a fresh game world with the code that is currently running on production, setting up company, running for office and so on. Once that was set up I ran the new code to see if something would break during the migration process. Once everything was up and running I tested the new features.
The next step is to deploy the release to the test server, as it is much more similar to production than a fresh local server. If you have access to the test server (star tier and above), you might have seen my message in global that I am going to deploy the parliament release to the test server soon.
As always: we'd love to hear what you think: join us on Discord or the forums!
Happy trading!