Notes
2025
-
Markets
08:03AM
It is amazing to see how a single resource like deepseek was able to rip apart the markets. Looking at the cheap $NVDA stock is making me think about dumping into the 1k mark really quick? 1000 shares would really be good a solid investment right about now.
-
WoW
06:25PM
Some quick hardcore runs on my new hunter and then going to switch over to the shaman after that.
-
Godot
09:37PM
The UI patch for the extension is a bit more annoying than what I would have thought. Ugh, I think I will have to get the computer back online asap because the speed and delay is getting to me! Having WSL open with wow is already killing my setup, ughhh.
2024
-
11:30am -
Schema
Schema
Starting off the weekend with more schema changes! Finalize the message table and then expand out the host table, but before doing those two tables, I need to make sure the global keys are added. It seems that during the
dbmodels.rs
generation under theerust
folder, the struct derives seem to fail, thus I need to see why it fails. The original shell uses sed to replace(Queryable, Debug, Identifiable)
but since we shifted the primarykey back to serial / big int instead of binary, we no longer need theIdentfiable
! Thus going to remove that aspect of the schema generation.In addition, there would be the zod that we need to expand.
export const registerUserSchema = z.object({ username: z.string(), email: z.string(), password: z.string(), confirmPassword: z.string(), }); export function registerUserSchemaValidation(schema: ZodRawShape) { return registerUserSchema .extend(schema) .refine((data) => data.password === data.confirmPassword, { message: "Passwords do not match", path: ["confirmPassword"], }) .refine((data) => /^[a-zA-Z0-9]+$/.test(data.username) && data.username.length >= 3 && data.username.length <= 20, { message: "Username must be 3-20 characters long and only contain alphanumeric characters", path: ["username"], }); }
This is an example of the zod expansion, which is through the
extend
andrefine
functions of the zod’sZodRawShape
object. -
3:40pm -
Refactor
Refactor
The worst feeling about refactoring is knowning that you have to do it a couple times over and over. Even this current refactor that I am doing right now, sadly will be done again using SQLX instead of Diesel, which is a pain to think about down the line. The main reason we would be doing the refactor again, even if we are refactoring it right now is because of the C library that Diesel depends on for MySQL.
-
11:40pm -
Drizzle
Drizzle
When updating Drizzle within the monorepo, we run three commands. The first command, aka
./kbve.sh -atomic drizzle kit upgrade
, would be to create a new branch for the upgrade, just to make sure that nothing breaks! The second command ispnpm add drizzle-kit@latest -D
and finally the third command is./kbve.sh -reset
. Finally, let us test case the studio by running./kbve.sh -studio
.Inside of the studio, we want to add the seven global keys that we wiped earlier, which I placed under notes as keys.