littlelogs

Keep a social journal of your work progress as you make and learn things.

March 2017

larouxn
larouxn

👋 Hey littlelogs, it’s been a while. Almost two months actually! Well, all that #MidnightMurderParty talk of automated deploys and such that @rhitakorrr and I have taken part in over the past many months… year now even… well, deploys are gone. Automated deploys that is. It took me about a year to realize that this project is small enough that I could simply write a 5 line bash script to accomplish everything a humongous, frustrating Capistrano process was doing.

Automated deploys are dead and the repo and servers have been subsequently cleaned up quite a bit. Furthermore, now we’re able to update! Ruby 2.4.1 was released yesterday… we’re running it in both staging and production. Also, we upgraded to Puma 3.7.1 which provides some nice DDOS protection-esque functionality. We’re lean, not mean, up to date, and moving forward once again. 😅

Other stuff, I wrote a short six song EP in about a day and a half earlier this month. If you’re interested, you can check it out here: http://bit.ly/ottawa-ost

rhitakorrr
rhitakorrr

I started scheduling my todos in a calendar (inspired by @Kraahkan) to stop myself from putting them off for “productive” things I didn’t mean to be doing. I added a recurring “Writing” entry every morning before work to encourage both daily writing and getting up earlier. This means that staying up all night and waking up late don’t cut into work time; they cut into my writing time. So far, it’s kept me from staying up too late for no reason, and all my todos have been getting done.

Since my last log, I’ve:

February 2017

rhitakorrr
rhitakorrr

2 for 2 on #MidnightMurderParty development tonight! Both issues I tried to fix last night are now resolved. Turns out there was an issue with deploys, and the code wasn’t actually going live (I only noticed this tonight because an obvious behavior change worked locally but not on the live server). One of the fixes from last night didn’t need any adjustment; the other I completely rethought and came up with a better solution overall.

rhitakorrr
rhitakorrr

0 for 2 on #MidnightMurderParty development last night. I’m down to browser-specific fixes at this point, and solutions are (a) dependent on other people deploying and testing things for me and (b) mostly guesswork. This slows down my ability to dev tremendously. Out of the two fixes I coded up last night, neither worked, which is kind of a bummer. Using some alerts, we managed to figure out the error message thrown by one of the issues (getting error messages from mobile browsers is a pain). My guess about the error was right, but somehow my solution didn’t fix it. Still not sure why.

On a brighter note, I once again submitted a #shortstory I’ve been trying to get published to a contest and expect to hear back about another one within the next couple days. I never really have high hopes for publication, but I definitely won’t get published if I don’t keep trying, right?

rhitakorrr
rhitakorrr

As of yesterday, the #Elm game engine started to look like an actual engine instead of a mess of #ECS code mixed with half a game implementation. I plan to use this for later optimizations. It originally started as an extension of #MidnightMurderParty, but I think at this point it’s just become its own project. I should think of a name for it.

Changes I made on the engine tonight:

  • When initializing a game, the user can now issue a Cmd before providing the engine with the game data. This allows for basing the game data on HTTP requests and such, which I intend to use for MMP to retrieve JSON from a database as content is released.
  • With a bit of extra type magic (there’s already plenty going on), I got the engine tracking which system (as in Entity-Component-System) is currently running, along with some extra data about the system. I also added a function that will allow running one system from within another and restore the original context when the nested system finishes.
rhitakorrr
rhitakorrr

I’ve spent the last few days working on an engine for text-based games in #Elm, the goal being to use this engine to code the #MidnightMurderParty interactive segments. Turns out, modeling a game engine in a purely functional, strictly typed language is tricky. Since game objects have different properties and behaviors, modeling them as the same type (so they can be stored in a List or Dict) isn’t really straightforward.

After some research, I decided to go with an Entity-Component-System (ECS) approach, which has been a challenge as the first time I’d heard about such a pattern was on Friday. Since then, I’ve written some terrible code, refactored many times, and only now have something that looks promising enough to move forward with. There’s still a lot to figure out (cross-entity/component messaging, for example), but at least now I have an idea of how this might work.

rhitakorrr
rhitakorrr

I might have called the #MidnightMurderParty countdown page complete a little early as I spent tonight editing it and adding stuff to it. Changed styles, added social media buttons, added Google Analytics, etc. But now I think it’s safe to actually say it’s done.

Closed a bug report from the beta as well since we can’t seem to reproduce it anymore and can’t test my fix. We’re merging the fix anyway (after a cross-browser test to make sure it doesn’t break anything else) as an extra layer of security. Will have to keep an eye out for that bug, though.

rhitakorrr
rhitakorrr

I added a short blurb as well as some testimonials by the characters in the story to the #MidnightMurderParty countdown page. I’m hoping that between that and the animation which will be included on the page, it will give potential readers a pretty good idea of what MMP actually is and attract the right following. I’m still waiting for some feedback on the design, but for now, I’m calling it and saying the countdown page is complete.

rhitakorrr
rhitakorrr

Did some more work on the #MidnightMurderParty release countdown page. Added a #MailChimp form for people who want to be notified upon release and fixed a lot of styles on the page to be more responsive.

I still want to include something that makes it really clear what MMP actually is. Last time I released this project, a lot of people thought it was a family-friendly murder mystery and shared it as such. It’s not, and that did nothing good for reader retention. I’m thinking of coming up with a concise blurb like on the back of a book; the trick will be making it lighthearted and fun while also being clear about the content. But that’s an issue for the morning.

rhitakorrr
rhitakorrr

Over the weekend I did a lot of work on #MidnightMurderParty.

  • Saturday. Got together with my cousin who recorded the voice line for the promo animation with me. Did a lot of audio editing to combine the best takes (unfortunately, the best take of one part had some room echo in it—my fault for changing the mic position without thinking—so that made the editing take forever, and I’m not even sure it’s done). Sent that off to the animator. Also had a meeting with @larouxn to go over bugs brought up in the beta and lay out a plan from here to 1.0.
  • Sunday. I was supposed to go to my cousin’s Sweet Sixteen today, but I unexpectedly got snowed in—should have checked the weather yesterday, I guess. I spent the last 8 hours fixing beta issues, reviewing the animation, and developing a “Coming Soon” page complete with countdown. All in all, MMP is coming along nicely.
rhitakorrr
rhitakorrr

I’m putting aside my goal of finishing the #hakyll_portfolio_blog by Saturday as a couple things just came up that I didn’t expect:

1) The #MidnightMurderParty animation timeframe suddenly got accelerated, so the animation needs to be completed within the next 4 days. This means, among other things, that I have to dedicate more of my time to being available for quick feedback and have to orchestrate getting the voice line recorded.

2) The For Honor beta just came out, and, frankly, I just really want to play it while it’s still free.

That said, I still plan to work on the blog, just not as much as I initially intended.

Tonight, I also got feedback on the current animation, scheduled a time to record that voice line so I can get it to the animator by the end of Saturday, and wrote a #shortstory (flash fiction).

rhitakorrr
rhitakorrr

Somehow I managed to waste most of the day and still get a lot done.

  • Spoke with my cousin about voicing a character for the #MidnightMurderParty promo animation. We’re meeting sometime this week to record the line, which is really exciting.
  • Made a bunch of commits to the #hakyll_portfolio_blog:
    • Changed the way URL fixing is handled to not rely on post-processing the page.
    • Added an RSS feed to the site.
    • Restructured the Config record to better handle reading in multiple config files.
    • Refactored the Contexts module to more easily handle all the various parameters needed to generate a Context. For example, to generate the Context for a post, I used to have to write something like postCtx tags categories <> configCtx config <> defaultCtx, but after doing some mconcats and introducing a new record, I can do something like postCtx contextParams and it does all of the above. Pretty neat!
rhitakorrr
rhitakorrr

Spent the whole night playing with different comment system widgets because I’m getting tired of Disqus (guests can never figure out how to leave a comment, and I don’t blame them; Disqus makes it so hard to find the submit button for a guest). I couldn’t find anything to suit the needs of #MidnightMurderParty any better, though, since I need the AJAX thread loading Disqus has. While Widget Pack has that too, its admin interface seems weaker than Disqus’s, and it bundles a star-rating system in with the comment stream, which I don’t want. Couldn’t find a way to disable it, but maybe I’m missing something.

On the bright side, my #hakyll_portfolio_blog does not need AJAX thread loading, so tonight I installed IntenseDebate on there. For the functionality it does have, it’s behaving faster and more reliably than Disqus, which is nice.

rhitakorrr
rhitakorrr

I’ll make this a quick post since it’s late. Since the #MidnightMurderParty beta is now in progress, I’ve shifted gears a bit and started working on my #hakyll_portfolio_blog again. Really, I restarted it from scratch since the first version was a mess. Maybe I’ll be able to launch a minimal version before the MMP beta ends–that’s my hope, anyway. Other than that, I started reading my third book of the year and got some #writing done on a #shortstory.

January 2017

rhitakorrr
rhitakorrr

Fixed both of the remaining #MidnightMurderParty front-end bugs with one tiny commit!

My suspicions were correct: when I had to mess around with the renderer after Chromium broke itself, I accidentally regressed some code. The bugs didn’t become apparent until I zoomed the page to 175% in Chrome (or did anything in the mess that is Firefox), so it took a while to notice, but the fix was simple once I guessed the problem.

The column-width property doesn’t support percentage values, so to make it dynamic, I manually alter a stylesheet with #regex. Prior to the Chromium fix, the width and height were set this way as well, but then I changed them to 100% since that seemed less sketchy than live-editing more of a stylesheet. Apparently, that was even sketchier and caused the bug. Changing it back to the way it was fixed the offset pages bug (which I was trying to fix) and somehow magically fixed a different bug in Firefox (not complaining).

I also added some stuff to the testing doc.

larouxn
larouxn

In the never ending story that is the development of #MidnightMurderParty, not really, it’s getting close, @rhitakorrr pinged me yesterday afternoon with a double request. Firstly, he wanted an end point at which he could receive the release date of the next unreleased segment of the story. Thirty minutes later, give or take, /api/next was born. Simple enough.

Unfortunately, the second request was to figure out why the hell unreleased segments (release date falls after today) were appearing in the reader. That was a fun little bug to figure out. Turns out I was only checking the release dates for chapters, not every entry within a chapter. Woops. 😛 The release bug was somewhat simple to fix but the resulting refactoring took quite a bit more time and brainpower.

Also, I locked down the Gemfile after witnessing Puma bump to 3.7.0 and break deploys… no thank you. 😅 🔒 Locked down. 🔒

rhitakorrr
rhitakorrr

Yesterday was a mess. What was supposed to be two quick commits for #MidnightMurderParty and the rest of the day off became a 5-6 hour dev session where I discovered some pretty nasty bugs, at least 3 of them fairly serious front-end issues. @larouxn had to create a new endpoint on the back-end for one of the features I was working on, and while I was testing that, I found out that our release scheduling wasn’t working properly either (it was releasing content that wasn’t yet scheduled to be released; I’ll leave that log to Nick).

Long story short, I did close the last two #GitHub issues, but now I have to spend tonight fixing bugs in the most volatile part of the application and hopefully not introducing new ones in the process. So much for not fiddling with it until after the beta test!

rhitakorrr
rhitakorrr

Tonight, I continued working on the documentation for the #MidnightMurderParty beta test. I filled in a lot of the functionality details from an earlier version of the testing documentation, but a lot has changed since that version. I’ll probably finish the draft of the new doc tomorrow.

Also, between @wearing2raincoats and me, we’ve picked up 3 or 4 more beta testers. Still looking for a couple more before the beta rolls around next week.

rhitakorrr
rhitakorrr

I’ve gotten back to #MidnightMurderParty over the past two days.

  • Yesterday I did most of the research needed to write Episode 4.
  • Tonight I started working on the documentation for beta testers. I wrote up a broad checklist of the functionality testers will need to verify and reviewed it with @larouxn. Tomorrow, I plan to add a larger section detailing each item on the list.
  • Also tonight, I:
    • Set up the domain for the beta test.
    • Compiled a list of pre-beta todos (all small things that I can do this week)
    • Integrated some stuff into the MMP Slack for fun.
rhitakorrr
rhitakorrr

#MidnightMurderParty development is finished!

Okay, maybe not entirely, but @larouxn and I just closed and merged in the last remaining development issues tonight. There’s still the beta test, which I’m sure will reveal some bugs, but until then, I have no reason to open up Sublime Text or fiddle with code. It feels like finishing that first draft of a story: yes, there is editing ahead, but right now I’m just really excited to have completed a first draft!

There’s still non-development stuff to be done for MMP (#writing, editing, configuring services like #Mailchimp, etc.), so I’ll still be logging about that, but for now, I think I’ll take the rest of the night off… maybe read a book, or just try to sleep off this cold.

rhitakorrr
rhitakorrr

Between being up early for a work class and the sudden cold weather over here, I’ve managed to get sick. Trying to rest up, but I’m bad at resting, so instead I worked some more on #MidnightMurderParty. Finally seem to have gotten the Safari bug fix right, and I’ve cleaned up a lot of the URL hash navigation code. After regressing some of it, I even added some comments so I wouldn’t repeat that mistake.

Earlier in the week, I joined a 24-hour #shortstory contest, so I wrote the first draft of that tonight as well. I might do a little more editing tomorrow before I submit, but for now I need to think of a title and get some sleep.

larouxn
larouxn

Just a quick little update regarding some fun #midnightmurderparty stuff I’ve been up to this past week. Chronologically, I suppose I worked on some cross-browser testing first and my god… there are a lot of browsers these days. https://goo.gl/xXJ35W

I also learned a tad about image optimization and compression. The main difference between JPEG and PNG compression is lossiness. JPEG, a lossy format, compresses images into chunky, huge pixel mosaics in order to reduce file size. Whereas PNG, since it’s lossless, instead chooses to retain visual fidelity and simply reduce the number of colours to reduce file size. Pretty neat, different approaches.

Lastly, one rather unique thing happened during our (@rhitakorrr and I) weekly meeting this week. All of a sudden the redirect to our staging server started returning a 403 error. I was home, where the staging server is, so I checked it via the internal IP. Server was up and fine. Apparently, my public IP changed mid-meeting. Thank you Bell Canada. 😂

rhitakorrr
rhitakorrr

Added a pretty big feature (code-wise) to #MidnightMurderParty tonight: URL navigation. Now, when the user gets to a new segment, the URL hash will change to reflect the selected segment. Readers can share these URLs to send someone to that part of the book (much like the share links inside the book). When the the user changes the URL hash (think forward and back navigation), it will navigate the user to the relevant segment as if they selected that segment in the table of contents. There was briefly a recursive navigation issue, but I think I fixed it. Still needs more testing and cleanup, though.

Still got that Safari flexbox bug, it seems. The CSS autoprefixer did something pretty janky and converted flex: 1 1 0 to -webkit-box-flex: 1. The fix for Safari was supposed to be using -webkit-flex: 1 1 0 instead of -webkit-flex: 1, so tossing in -webkit-box-flex: 1 did nothing to solve the problem. I might just have to add -webkit-flex manually.

rhitakorrr
rhitakorrr

Tonight I:

  • (hopefully) fixed a Safari flexbox bug in the #MidnightMurderParty Reader. Since I don’t have any Apple devices handy, I’m waiting on @larouxn to confirm.
  • Moved midnightmurderparty.com over to Google Domains
  • Edited the #shortstory I wrote the other day
  • Printed out a QR code which I now need to scan to turn of my alarm. I put it in the kitchen next to the coffee maker.
  • Started reading another book (2/25 for my 2017 #GoodreadsChallenge)

I also wanted to set up my new phone tonight, but I’m waiting on a case for it before I switch over. Amazon Prime 2-day shipping was due to show up today, but neither item I ordered came. One said in the shipping tracker that it would arrive today before 8pm all the way until nearly midnight. Now both items have an estimated arrival time of 2-3 days from now. Apparently 2-day shipping became 4-5 day shipping somehow.

rhitakorrr
rhitakorrr

A lot’s happened over the past couple days. My graphics card died, rendering my computer unusable, so I had to learn how to install a new one on the fly, which was simple but nerve-racking since I’d never installed hardware before.

I wrote a #shortstory this morning—really a flash fiction piece—starting at 12am when I should have been asleep. I think it came out well.

@larouxn and I closed a couple more #MidnightMurderParty issues tonight. We finished up the load time optimization, so now the site shows low resolution images first while the high resolution images load in the background and are swapped in when ready.

We also began planning out the beta test, which is now slated for the end of January through the beginning of February. We’re looking for more beta testers, so if you’d like to help beta test the Midnight Murder Party Reader, let us know!

rhitakorrr
rhitakorrr

Closed three #MidnightMurderParty issues tonight, one of them being the app-breaking bug introduced in the last few Chromium versions!

I actually hadn’t planned to delve into that nasty Chromium bug until next week, but I was too curious to hold off. I ended up debugging on and off for a few days until I narrowed the bug down to this: if you use CSS columns and an overflow value other than visible (i.e. overflow: hidden|auto|etc) on the same element, all columns after the first few will render but become invisible as if visibility: hidden is applied. The point at which columns become invisible seems arbitrary based on seemingly random things like the height of the container or even the size of the viewport (which should have no effect on the fixed size container).

Tracking that down was a nightmare.

In the end, I fixed it by moving the overflow: hidden to a parent element of the div with columns and then changing all the dependent logic.

larouxn
larouxn

Completing my triumvirate of new year, new #midnightmurderparty dev and subsequent logs, I’m back to claim that though the reader is still completely borked in Chromium based browsers for every page after page 2… we have finally reached “no image curtain fall load” nirvana… with browser cache. First load is still janky, but better! By this I mean, you can’t see the image loading vertically down the page when you access the reader, provided you have some cache. This was primarily achieved by aggressively optimizing our image payload. CloudFlare is probably helping a bit too. 😄

Originally our image payload for the reader was 3.1mb. After my secondary optimization the image payload is down to just over 800kb. A ~75% size reduction! I couldn’t be happier with how well our image optimization went. @rhitakorrr and I also discussed Chromium fixes, merged in his new Google Analytics stack, and performed a bunch of routine maintenance and upgrades. The #RoadToBeta is real.

rhitakorrr
rhitakorrr

Let’s see if I can get back to daily (or at least near daily) logging again. Today, I:

  • Closed two #GitHub issues for #MidnightMurderParty. Both were small aesthetic things related to the user resizing the book, but because of some race conditions that could occur between #Elm and #JavaScript (and did occur last time I tried this), I’d been putting the issues off for a while.
  • Got some #writing done on my current #shortstory—about 700 words on the manual typewriter, which I’m enjoying quite a bit so far.

Now, I’ll probably read for a little bit and maybe play some Osu! or Overwatch. Something that starts with an ‘O’ anyway.

larouxn
larouxn

Last evening @rhitakorrr and I had our weekly Tuesday #midnightmurderparty meeting to plan out the upcoming week as well as our roadmap to beta and launch.

Work wise, I have decided to move past auto deploys, probably forever, and upgrading our Ruby version, for now, to focus on other more feasible tasks. One such task is optimizing our load times, specifically optimizing images. I noticed we were serving up some pretty unnecessarily large and uncompressed image files, multiple megabytes in fact. Subsequently, I ran all the images through this awesome, free compressor: http://optimizilla.com, and was able to cut the image payload in half.

To test this optimization I uploaded the compressed images to just our staging server. The result: our staging server, a Raspberry Pi 2 run out of my apartment (http://imgur.com/a/khE8L), was just as fast or even slightly faster than our DigitalOcean VPS. Incredible. 😲

Lastly, I added CloudFlare to my personal site. Full HTTPS for no reason, woo! 😄

rhitakorrr
rhitakorrr

Hi. It’s been a while.

While I was gone, Chromium went and entirely broke—and I mean broke, as in unusable broke—the #MidnightMurderParty reader. Yeah, one version of Chromium, it works. The next, it doesn’t. Since this breaks every Chromium-based browser (Google Chrome, Opera, Yandex, you name it), Midnight Murder Party is suddenly unreadable in all of them. The elements render, but after page two, they are all invisible as if visibility: hidden is set (which it isn’t). The only thing I’ve managed to figure out is that it’s somehow caused by CSS columns (each page is a column). @larouxn and I were planning to have a beta test next week, but that’s shot until we figure out how to get around all these broken browsers. In the meantime, I’ve added Google Analytics and better error handling/reporting.

Unrelated to MMP, I spent the holidays with my family, set a 2017 #GoodreadsChallenge of 25 books, picked up my manual typewriter from the shop, and have begun #writing a story on it!

larouxn
larouxn

Over the holidays, as I wrote in my last log, I tried to upgrade #midnightmurderparty to Ruby 2.3.2 and then 2.3.3 unsuccessfully. Well, 2.4.0 was released on Christmas and I failed to upgrade to that too.

Unfortunately, it seems the combination of one of our unmaintained gems, rvm/rvm1-capistrano3, which manages installing our gems and selecting our Ruby version during deploy and our one GitHub hosted (not RubyGems) gem, seuros/capistrano-puma, does not want to work with Ruby above version 2.3.1. It seems either I switch off RVM, originally I used ruby-install and chruby but couldn’t get deploys working, or I fork this GitHub gem and push it to RubyGems. Neither are guaranteed to work and both would kinda suck.

Aside from that, I’ve been fine tuning our error emails and finding out firsthand that a lot of random bots on the interwebs crawl your site and request nonexistent, usually PHP, files. Trying to keep from waking up to 10 ERROR 404! emails. 😅

December 2016

larouxn
larouxn

Been diving head first into technical #midnightmurderparty stuff for the past two days. Yesterday I attempted to upgrade our stack to Ruby 2.3.3, from 2.3.1, but ran into some arcane gem errors. Might have to fork a gem or two if this keeps up. For now, we’re staying on 2.3.1

Aside from the Ruby version update shenanigans, I implemented some nice error handling on the backend. Now if an HTTP error code is thrown (server error), I will be emailed. Nice for when we go live as I’ll know if anything breaks, when it broke, and what the error was without having to anymore than check my email. Also, spiced up (improved) our logging so we know everything that goes on from regular functionality to errors and beyond. Getting close to beta time! 🙂

larouxn
larouxn

Since my last log, about a month and a half ago, I’ve

  • completed my two week #song_a_day challenge | listen here
  • written a few more tunes since the challenge | listen here
  • made it through the Black Friday/Cyber Monday hustle here at Shopify
  • read Pyongyang: A Journey in North Korea by Guy Delisle, pretty interesting
  • traveled to and from New Jersey for 🇺🇸 Thanksgiving, heading back Monday for🎄
  • added caching to our NGINX configs to improve load times… should we CDN? Hmmm 🤔 #midnightmurderparty

Tonight I’m going to

  • meet with @rhitakorrr to discuss the Elm 0.18 upgrade, fine tune caching, and plan the coming week of dev
  • clean my apartment, gotta be spotless before I check out for three weeks
  • catch up with On A Sunbeam, one of the best web comics I’ve ever read
rhitakorrr
rhitakorrr

Since my last log, I’ve

  • upgraded the #midnightmurderparty front-end to #Elm 0.18
  • finished the first draft of the MMP Episode 1 rewrite
  • finished rereading Stephen King’s It
  • written the first draft of a flash fiction piece
  • started reading another book
  • dropped off my manual typewriter at the shop for repairs (which turned out to be pretty expensive!)

Tonight I’m going to

  • have an MMP dev planning meeting with @larouxn so we can get everything needed for the 1.0 release done by the end of January
  • edit the flash fiction piece I wrote last night
rhitakorrr
rhitakorrr

I keep forgetting to log here, but I’ve been pretty productive since #NaNoWriMo ended. Over the past five days, I:

  • Have continued nearly daily #writing (though not as much as during NaNo)
  • Edited and submitted a short story manuscript to a magazine (will hear back within ~2 weeks)
  • Began rewriting #midnightmurderparty Episode 1 with a hopefully better hook (if anyone wants to give me some feedback on this, let me know!)
  • Started researching for MMP Episode 4
  • Had an MMP dev meeting with @larouxn and threw together a Github Project board, which we will be reviewing tomorrow. The plan is to finish development by the end of January!
  • Started using #LifeRPG again (and programmed another tool to calculate Exp and RP in a consistent way)
  • Got OCR working for my typewritten text (new ink ribbon = darker text = good OCR)
  • Decorated my apartment for the holidays with my parents (and went to a diner; what’s more productive than diners?)

November 2016

September 2016

rhitakorrr
rhitakorrr

I was right. There was a pretty nasty bug hiding in that #midnightmurderparty refactor, but I fixed it now. Plus, I removed all the dead code paths and cleaned up the #Elm model.

I wrote a short story tonight as well, but it ended up being pretty awful. I think it has some promise, but I’m basically going to have to rewrite it from scratch tomorrow. Oh well, it’s all part of #writing.

Older