Live data from Hacker News

Getting too absorbed in side projects

bennettnotes.com

71–80 of 113 posts

Re: Getting too absorbed in side projects

#71
post #40

I've got the same issue, but only for the first 80% of the project. At that point, the project becomes a burden I have to finish, otherwise I would have wasted my time. The initial burst of inspiration is always exciting: you've got a novel idea, there are no restrictions, no deadlines, no requirements. You don't care about bugs or beauty, just about making things happen. You could even abandon the project and it wou…

I'm at 81% :) The fun part is over now with my e-commerce project. I have to integrate with payment provider, design a checkout form, create a shipping API, write legal text, subscribe to callbacks, etc :)

I will push it though, it's just boring stuff that must be done, but luckily I have the chi inside me thanks to the 80% fun part and positive feedback that I received during it.

Re: Getting too absorbed in side projects

#73

Earlier quoted context omitted.

Enjoy the time with your children too. The memories you build with them today will last a lifetime, and will be much more valuable than any side project you're dreaming of

I've learnt side-projects are possible you only just have... sleep less :) I'm a father of 2 (4yrs old + 6mo old) and I start doing side-projects when kids and wife go to sleep (we spent time together as well, she doesn't go to sleep at the same time as kiddos). So around 22:30 I've work on something for myself for 2 - 3hours. Then repeat :) But I'm blessed that my kids are sleep through 99% of the night time.

I did the same thing when my kids were born (similar age difference), and it took approximately 4-5 years for me to burnout. I took for granted that my time was a limited resource, and left very little for myself (for rest, relaxation, and just plain enjoyment).

I got to a point that I couldn't bring myself to even open a computer after I got home from work ... and while I recovered to an extent (I've had a number of successful (IMO) side projects, and even did some startups since), I haven't quite felt that drive to spend my off-time doing more work. My daughter just turned 18 yesterday, and I'm looking forward to when my son is off to college in ~4 years; side-projects, here I come!

Re: Getting too absorbed in side projects

#74
post #40

I've got the same issue, but only for the first 80% of the project. At that point, the project becomes a burden I have to finish, otherwise I would have wasted my time. The initial burst of inspiration is always exciting: you've got a novel idea, there are no restrictions, no deadlines, no requirements. You don't care about bugs or beauty, just about making things happen. You could even abandon the project and it wou…

Procrastinating here at 95% completion of my side project. Can't wait enough for it to get over at the same time dreading the fact that the end result will be never as good as it was in my mind.

Re: Getting too absorbed in side projects

#75

I'm too absorbed by parenting that I dream about side projects I will never do. Enjoy the free time

I feel like this is an excuse (sorry to be blunt). I’m a new parent and managed to build and release a side project in the first few weeks, as well as keep up with a bunch of other side projects. I’ve just had to adapt the way I work on them. Eg I’m spending significantly more time planning than before, I’m using tools that have been consistently applied to solve similar problems, I’m ruthlessly prioritising features…

> I feel like this is an excuse

Yes. It is an excuse. That's literally what it is. Its not an invalid excuse or a fake excuse just because it's an excuse. This person has real material daily struggles and constraints. They have logical reasons they can't do more. They are excused from judgement for not doing their side projects. That's how excuses work.

Re: Getting too absorbed in side projects

#76
My perspective on side projects has evolved over time. When I was younger I would generally devote time to implementing project ideas. This was fine for smaller projects, but larger projects were cumbersome (the "finishing" problem). The birth of my first child threw another huge wrench into my free time and ability to do "work after work" (even the mental energy after a day of work and child-rearing was lacking).

Somewhat organically, my side-development has shifted into a more meditative exercise. While the day job necessarily forces consideration of prioritization, deadlines, and other concerns - my side development is free to be "pure" with respect to some goal.

These days I take small problem spaces and implement them _again_ and _again_, from scratch, trying to get a finer understanding of the problem each time. The code is not on github or publically shared - it's not really meant for outside consumption.

For example, I did several re-implementations (from scratch) of a tokenizer for a toy programming language with some typical syntax, with the goal of optimizing the core tokenizer loop while still handling a full unicode input. Just to illustrate why I find these sorts of exercise to be valuable, I'll expand on this example in detail.

Over the various implementations I gained a few key insights that I carry forward in my future implementation work:

1. State machines with O(1) dispatch using arrays-of-edges for transitions seems appealing at first, but is in fact a poor optimization choice. The approach assumes an even distribution of probabilities between all states, and the distribution is in fact highly skewed. A hand-rolled approach that is able to carry the current tokenizer context implicitly in the code-location performs far better. The final design was a parser that has a top-level `nextToken()` routine which checks the first character and then uses a series of conditionals to branch into subroutines for parsing individual token kinds.

2. Rediscovered the well-known trick of using sentinel characters in the text to eliminate the "test-for-eof" branch in the inner `nextChar()` function which is the main workhorse of any tokenizer.

3. Pushing the parsing of full unicode entirely out of the fastpath by leveraging the fact that the first byte of a multi-byte unicode character will fail any test for an ascii character or range. This led to a design where instead of `nextChar() -> Unichar` as the interface, we split the methods. The fast-path method is `nextAsciiChar() -> MaybeAscii`, which blindly returns a type-wrapped `u8` value. The value is then sent through the series of fast-path checks in the main control flow. If the fast-path checks fail, there are two methods that help handle the slowpath: `unreadAsciiChar(MaybeAscii)`, which can implicitly do a blind decrement on the current text cursor, and `nextFullChar(AsciiChar) -> Unichar`, which reads the full unicode character without unreading the first byte.

4. Realizing that it's better to use a temporary copy of the current cursor during the invocation of a single `nextToken()`. That memory write at every `nextChar()` can be eliminated and replaced with a single write when a token has been successfully parsed (or error). Updating the cursor pointer in place can potentially be eliminated by a smart compiler, but given that we're hand-rolling our tokenizer due to reason 1, the tokenizer code gets large enough (and contains enough loops at various points - e.g. to parse numbers, identifiers) - we cannot expect the compiler to both inline everything as well as eliminate every spurious write-back of the current cursor position. This prompted a modification of the design to have the methods not be implemented directly on the tokenizer, but a temporary `TokenParser` value-type that is effectively a `(&Tokenizer, *u8)` that is moved around by value through the control flow, and is written back and destroyed when a token is parsed (or error).

5. Optimizing the parsing of keywords (which show up as identifiers) was interesting. The trick I used here was to keep track of the cumulative `xor` of the low 4 bits of each identifier byte. At the end of parsing an identifier, this cumulative value is fed to an explicitly coded state machine which switches directly to the most appropriate subset of identifiers for that (admittedly terrible) 4-bit hash value. A better hasher did not justify its own computation cost.

6. Reordering all of the sequences-of-conditionals using a statistical analysis of the probability distribution of characters at every step in typical source.

That whole process took about a year of casual work. I didn't drive myself to complete it - but simply let the problem sit in my mind and percolate - trying new ideas and implementation strategies as time allowed. The final set of insights I derived from the exercise are something I consider very valuable.

A tokenizer is a simple thing, conceptually. It's something a sufficiently intelligent first-year CS student should be able to whip up. It's something I myself have done for various pragmatic reasons several times. But the meditative exercise: "take a small thing, make it faster, then make it faster, then make it more faster, then faster yet", has provided me with a real insight into all nooks and crannies of the problem space. Something that seemed trivial at first yielded more and more depth the more seriously I analyzed it.

This approach to spending your "side-time" is not appropriate for everyone. If you want to ship stuff, and that's your motivation (a perfectly reasonable and fine motivation), this does nothing for you. If you have a lot of extra time and the energy to complete large projects independently of your employment, that might well be a better choice.

But for those of you who are finding yourself in the same position as I am: not enough time for big projects, not enough interest for small toy projects.. perhaps treating your side-development as a meditative exercise on a focused problem is something that works for you.

For me personally, it gives me a lot of gratification because I appreciate the gained understanding far more than I appreciate the litter of toy projects I've produced in my younger days.

Re: Getting too absorbed in side projects

#77
We need to make an internet pact to kill floating "navigation" bars.

Especially when they don't do anything other than display your name, face, and a hamburger menu. If you want the hamburger to follow me down the page just have that float...

Re: Getting too absorbed in side projects

#78
post #69

I'm too absorbed by parenting that I dream about side projects I will never do. Enjoy the free time

Ha-ha, been there, done that. It takes a lot of effort, energy, support from the spouse, ... I often say - if I could go back in time, I would go visit younger me, single, with 9-5 job being only obligation. I would go there, and slap him (myself) across the face for complaining about not having enough time. I mean, seriously? And a note to those parents with one kid - enjoy your spring break. That's what it feels li…

Parent of three here: one amazing thing that’s happened is the two oldest ones (both under five) self-organized a morning playtime routine when the new baby arrived. So, rather than coming straight to my bed, I hear them laughing and playing, and working out their problems in their room for a solid hour.

Given that the third baby is very, very likely our last I’m definitely trying to appreciate every moment. The upside is that by the third baby you’re able to just enjoy things because you’ve got some experience and aren’t overly anxious all the time.

I’ve learned the value of slow and steady progress on hobby projects. In some ways it’s more effective. I spend weeks without any real time to sit down and code, but by the time I do I’ve either worked it out in my head during spare moments, or on pencil and paper.

Re: Getting too absorbed in side projects

#79

I'm too absorbed by parenting that I dream about side projects I will never do. Enjoy the free time

I feel like this is an excuse (sorry to be blunt). I’m a new parent and managed to build and release a side project in the first few weeks, as well as keep up with a bunch of other side projects. I’ve just had to adapt the way I work on them. Eg I’m spending significantly more time planning than before, I’m using tools that have been consistently applied to solve similar problems, I’m ruthlessly prioritising features…

The adrenaline of being a new parent eventually wears off, just saying :) Gotta pace yourself, it’s definitely more a marathon than a sprint.

Re: Getting too absorbed in side projects

#80
post #40

I've got the same issue, but only for the first 80% of the project. At that point, the project becomes a burden I have to finish, otherwise I would have wasted my time. The initial burst of inspiration is always exciting: you've got a novel idea, there are no restrictions, no deadlines, no requirements. You don't care about bugs or beauty, just about making things happen. You could even abandon the project and it wou…

Completing the remaining 20% is a learnable skill in itself. Like everything else, the more you do it, the better you get at it.
Post reply on HN