lwm2pdf v0.1.3 Has Been Released

As a result of some other (believe it or not, work-related) research and learning, I got my hands on Poetry and finally got around to making the Lightweight Markup to PDF Builder tool I wrote for myself into an actual, pip-installable Python package. Like, it’s on PyPI and everything. This feels like a reasonably fine accomplishment for a hobbyist coder.

I’ve also started writing tests for it (what I am actually trying to learn more about: testing), and we’re at ~82% coverage at the time of writing. It may very well stay what way, too, because some of the stuff I don’t know how to test yet, and if and when I figure that out I probably won’t remember to update the tests here (at least until it comes time to add new features, e.g., I need to spend some time on the smart quotes — hm, it occurs to me that BeautifulSoup probably will help…​). But then, per my aside, I might just add more tests.

Anyway, the tl;dr is that if you’re writing in, say, markdown, to get a Submittable-ready PDF, all you need to do is run:

$ lwm2pdf -i mygreatstory.md

And it’ll spit out a mygreatstory.pdf file for you to send. I mean, there’s a bit more to it, but that’s the idea.

If you do happen to fiddlefuck with it and find bugs and/or have ideas and things, I’d like to try using the issues feature, so send in some issues.

To the Lady Who Told Me To "Get in the Bike Lane You Fucking Idiot"

You see, there was this pedestrian.

First, let’s take a look at that intersection: it’s garbage. It’s a spread-out five-points with the going-straight bike lane to the right of the double right-turn lane from which you informed me I was in the wrong. There isn’t a full bike box on that intersection but rather a kind of "V" shaped thing and, as I’m sure you saw, cyclists spread all the way out over it. Because I know I want to go straight, too, I tend to merge soon after crossing the intersection left into the straight lanes, leaving you all to happily turn right from your lanes. In part this is (I admit) because I don’t want to get stopped at the light (because your right turn lane, of course, must take priority over the cyclists going straight), and in part because I feel safer there riding with traffic, since, you know, people in that particular right turn lane tend to be pretty stressed out at that point in the morning commute, and I’d rather avoid confrontation.

So like I said, usually it’s just a matter of getting a bit ahead of you all in the turn lane (no problem) and signaling my merge left into the straight lanes, no big deal. And it wouldn’t have been a problem, save that there was a sweet (one must assume sweet) undergraduate left in Boston probably for some really special internship who was still crossing the street, preventing me from moving forward and making my merge, because, you know, pedestrians always have the right of way in a cross walk. It’s the law, even! Even when they shouldn’t be there, you still really shouldn’t hit them with your vehicle!

And so yes, I admit I was in your lane nearly stopped to let this sweet (one must assume sweet) young person finish crossing the road, but after which I merged into the straight-going lane as usual, at which point you decided to honk and inform me that I ought to get in the bike lane. But the thing is, I’m allowed to be in the road, even if there is a bike lane. In fact, it’s safer for me and for the other bike lane users at the speed I tend to go down that road. It allows me to not get right-hooked by one of the trucks or buses who are constantly pulling over to the side of the road to let folks out or turn into the BU campus, to not get caught up in bike traffic, and generally to feel more comfortable knowing I have road to work with should someone swerve in my way.

But of course, I know it’s inconvenient for you. And while you did still have to wait at the red light for a few seconds before turning onto Carlton St even with the delay I caused, I’m sure it would have been nicer had you gotten there sooner. I’m sure it’s annoying to feel that if you’re going to give up precious road space for a bike lane, it should be used. And frankly I’m a little sleepy and could very well imagine a world in which I was cranky on this Wednesday morning, too!

Nevertheless, I don’t feel that I did anything wrong, or unsafe, or indecorous, and I hope that you won’t take your frustration about my actions out on other cyclists. And who knows, maybe I am wrong, but I’ve been riding bikes in this city a long time and do think I know how to keep myself and pedestrians safe. I even stop at stoplights! Still, I hope you have a better rest of the day. I also hope that in the future you can come up with something better than a "fucking idiot," because really I think that’s a bit tired, really, and I’d love to be called something new.

Yours sincerely, A "Fucking Idiot"

Please note: I didn’t engage with this person after they yelled and they drove off and didn’t bother me anymore and I biked off and tried not to bother anyone else and everything was fine. Except those fucking cyclists who kept pulling ahead of me at stoplights but whom I would then have to pass again on the road…​

Ride #3: NER Woburn to Portland 400k

Ride notes from the third ride, written a little farther out because though they say "strike while the iron is hot" I saw that Seinfeld episode where George was a hand model recently and thought I’d let the iron cool a little. Also I was busy yesterday watching Mean Girls with my in-laws for Father’s Day. Anyway, a continuation of parts one and two. And I did actually take like three pictures during the ride this time. One or two of which may make it into this post.

Man, Boston to Portland, ME, and back is a long day in the saddle. Granted it was overall a very good day. But Jesus, looking back. They talk about something called "randonesia," a play on the amnesia you get a little bit after a long ride such that you forget how long it was and sign up for another (often longer) one, and I know for a fact I’ll get there, but it occurs to me just now two days later that I’m not there yet, maybe. Or just typing that feels long and makes me tired thinking about it. And I got a good 8-9 hours of sleep last night!

So the numbers part, according to my GPS: 251.03 miles in 19h36m with 9,518ft of elevation. Significantly less climbing than the shorter 300k ride and only a little more than the rather hilly 200k. So that helped. (The 600k I’m planning to attempt in July, by contrast, will have much more climbing.) My friend Adam came along cutting it half-way at 200k in Portland and taking the train back and that was super nice, especially since I managed to leave the house with only one water bottle and he lent me a second when I picked him up on the way to the start in Woburn. And the start was early, i.e., 4am, 04:00, four-in-the-fucking-morning, etc. I’d spent all last week progressively trying to push my bedtime earlier and wake up earlier so I’d be able to get more than a few hours' sleep (assuming I’d go down around midnight as usual). This was successful: I think I ended up managing about 5.5 hours of sleep which was pretty much the realistic target (after having slept a solid 8+ the night before). But I was still apparently groggy enough in the morning to forget the water bottles I’d stashed in the fridge, so, lesson learned: better to keep those on the counter with my keys. In any case —

That could be the theme for this ride, maybe: "preparedness." My mom was a great cub scout leader and did drill into us the whole "be ready for anything" ethos, and though it means that my wife often makes fun of me for always bringing an extra layer, sometimes it does pan out. E.g., though I left two bottles at home I’d still brought what was supposed to be the third to drink as pre-hydration on the drive over. If Adam wouldn’t have been able to lend me one I did have another bottle — albeit one of those stainless steel coffee mugs — that would have worked in a pinch. Also, this ride was — dare I say — chilly. It was in the low-mid 60s most of the day and we were riding along the coast most of the morning and there were pretty nontrivial headwinds the whole ride. Seeing the forecast on Friday morning I thought to myself I might get a little cold, maybe, would be good to be prepared just in case. So I went to the bike shop across the street[1] and bought some knee warmers. I’ve never bought knee warmers nor worn them and you’re really not supposed to try new "kit" on a long/target ride but I am so fucking glad I did. Like, we made it to Hampton Beach and its Sand Castle Competition and my knees were cold. So I put on the knee warmers, and they were toasty and warm. And it ended up drizzling/lightly raining on me during the tail end of the ride, and so I was glad to have brought my long sleeve wind jacket thing (which more or less works well enough in (warmish) rain), and was wearing all the layers I’d brought by the end. This made me feel prepared. Like I (almost) knew what I was doing. I even stopped to fix a fender rattle in the middle of the ride.

The only thing (aside from forgetting the water bottle) that I felt like I still needed a better solution for, preparedness-wise (aside from, you know, better fitness and a higher FTP), was my navigation setup. My GPS tracks were fucked for some reason; I had the route but no waypoints for turns or things, and the route itself did not track particularly well to the roads. Fine. I honestly like checking my turns and so on against the cue sheet anyway. Unfortunately this breaks down after the sun sets. I brought a little camping headlamp in case I had a flat after dark but, see, with a helmet, it’s really not helpful for seeing the cue sheet. So next time I think I’m going to try and find one of those little pen lights and stash that in a side pocket so it’s easy to grab and check. I’m also going to try and figure out how to get a better route into the GPS (my thinking is that information gets lost going from RWGPS to Garmin Connect, so probably I should just try to put the route on my phone manually?). Anyway.

The ride itself was really pretty good. My knees started bothering me around mile 150 but I’m not sure if it was a temperature thing from earlier or a fit thing and I don’t have any money for a bike fit anyway so we’ll call it a temperature thing. Adam and I rode much of the beginning of the ride with Joshua, whom I’d ridden with a fair bit during the 300k, and the most notable thing (aside from the sandcastles) about the first ~70mi or so was these crullers from Lil’s Cafe in Kittery because holy fucking shit I’ve never had anything like them. I wasn’t even going to get one, thinking I’d be all cool and just get a double espresso, but then both Adam and Joshua said I needed to and I’m glad I did. Like, I’m going to be dreaming about that donut for a while. Anyway. The sandcastles were cool:

ner 400k 1

Although that was around when the headwinds really picked up and started taking the toll on our little group(s). I don’t remember what exactly happened when but the "tl;dr" was that it was hard to keep a good paceline together in the wind and at the speed whomever was pulling was going so we splintered apart and brought in new folks then splintered off again and this was all fine and good. Adam’s knee started bothering him again so not too long after the first control at the pretty lighthouse we went our separate ways because he was planning on cutting the ride at Portland and I was trying to finish in 20 hours. This worked out OK though because as I was leaving the Portland control he was biking on towards it so we had a nice wave and shout from across the road and that brought my spirits up considerably.

My spirits weren’t bad, I don’t think, at any point on the ride, though I would say occasionally low. My pacing wasn’t really what I wanted it to be and I probably got caught out a few times a little dehydrated (only once) and under-fed (maybe a few times). I mean, I still managed to come in well within my goal time, but I didn’t feel "strong" after a certain point. I think part of this had to do with some yo-yoing and maybe I should chalk some of it up to having had a stomach bug the weekend before and not having really had a chance to get a properly long ride in since the 300k. Still, I had another excellent coffee in Portland, chatted with some folks, called Alia, and set off for the last 200k feeling pretty good, I dare say.

Speaking of folks — I’ve done enough of these rides now that I recognize and am recognized by a fair few of the "regulars" and this feels nice. Like community, almost. I’m still terrible with names (and it doesn’t help that it only occurred to me yesterday that there are at least two different "Jeff"s that I get confused), but it’s nice to be able to pick up conversations from past rides here and there. For example (jumping ahead; I don’t care; this is going to be nonlinear and that’s fine), I ended up riding the last ten miles or so in with Scott, whom I’d ridden the last part of March’s 100k with, and that was super nice. He’s about as new (and frankly probably even newer) to the long distance thing than I am and he had a lot to say about all the things he’s learned across all these rides and I just love that kind of shit, love hearing about it, borrowing and sharing ideas and so on. The nice thing about bike people is that you can always talk bikes with them, and often times other things too, but you always at least have that. So it was nice to ride out with Adam, play leap-frog with Joshua, nice to ride in with Scott, nice to see the Jeffs and all the other folks whose names I (sorry!) can’t keep straight on the road. The community bit is nice, is all I’m trying to say.

So what else? I saw a fox, a kitty cat, an opossum, a number of different birds, squirrels, chipmunks, roadkill, and some fancy-looking cattle on the ride. I also saw a guy in rural NH shouting with his shirt off in front of a cross perched atop a stone wall lined with lit candles at sunset and it was…​ odd. I am not sure if it was a satanic thing or a Christian thing or an amphetamines thing but it was something, that’s for sure. I will say I didn’t love riding in rural NH after dark, but I think that was mostly due to an unfortunately timed close-pass from a pickup truck after a row of very "Fuck You"-postured Trump-flag houses right as the sun was going down. But again preparedness: I have great lights on my bike, lots of good body-reflectivity stuff, and so it was ultimately fine, maybe just not comfortable. I’m sure it’s lovely during the day, and now that I’ve got (I don’t know, say 60?) miles in the dark at the end of a long day in the saddle, I won’t be so spooked next time. And really it was fine. (And also really I was happy when I was back in Massachusetts, which is stupid, given that the part of the state I’d crossed into was just as red, but hey: fear isn’t rational!)

The one maybe odd thing about this particular route was the dearth of controls: there were literally only five. Maybe this makes sense for an out-and-back, but it also meant that services were, on occasion, a challenge. A good one though, since it meant I finally had opportunity to try the "bottle in the jersey (OK vest) pocket" trick, which was nice. No services for the last ~70mi (though I was early enough to possibly hit the gas station in Exeter, but had enough shit so didn’t) meant that I had to do some planning. This was good! More practice and learning and all of that.

It occurs to me that this has mostly become an inventory, less a ride report. Oh well.

Let’s see, saw the Wedding Cake house, which was cool though not as cool as the house with all the toys and shit all over it from the 300k (which I didn’t get a picture of):

ner 400k 2

(And that truck blocking the shot finally did move just as I was heading out myself.)

Riding along the coast in the early morning was really special and lovely. Some really great views and empty or at least very quiet roads. There was a fair bit of unpaved/gravel on this route which was nice but not particularly notable since it was all pretty flat rail-trail type things, though might have been interesting had it rained earlier in the day. The rain itself was fine though I’m glad it wasn’t any colder. I’d love to someday get a power meter so I can see if I’m just wasted by the end of the ride or if I can just blame the headwinds that never really stopped. I’m glad I adjusted my front derailleur before the ride (it was still setup for a 48T outer chainring while I’m currently running at 46T), but I do need to fiddlefuck with it a little more (I think an extra 1mm up will help with a small but annoying noise issue in my lower cogs), and in general the bike continued to work beautifully. I think I’ve finally more or less got that saddle broken in, too.

There was a moment during the 300k where I felt truly done and like I would have happily gotten off the bike, and I’m happy to say that didn’t happen on this ride. And I’m sure were there more climbing it could have, but it didn’t, and that feels great. (Also, my overall pacing was much better which I think makes a huge difference.) I did think, though, that 400k is a long ride. Some small part of me wonders if I wouldn’t have more fun next summer doing just 200k rides, given that I’m not planning on trying to get across the pond for PBP, but then, I’ll probably forget I ever thought this and try to do a series again. We’ll see. But I did feel at some point that the ride was too long. I also counted down to the 200 mile mark and cheered when I hit it (then laughing that I still had about 50 miles to go). I mean, it’s kind of crazy how long that ride was. But also not crazy.

Adam and I were talking a little bit before the first control about how even a year ago the 70 miles to the lighthouse would have been it, the whole day. Now we were considering doing the ~110 round trip back up to Kittery sometime just for those crullers like it was nothing. Just a day out. And I think — when I can get over myself and not worry so much about the time or my speed or pacing — that’s what all of this kind of amounts to for me: just a really nice day out on the bike. And it was.

So we’ll see how the 600k goes in a few weeks. That’ll be two days out on the bike, so —

1. Not my usual or preferred bike shop; they’re a good shop but I am too poor to be their target customer, and as a buddy whom I used to work with at a different shop said once, "they always follow you around like they think you’re going to steal something."

"The Mathematical Experience"

Once upon a time in high school I was walking around either before or after my classes for the day (or perhaps it was lunch) and saw a pleasingly large stack of books outside the math department — old textbooks, journals, popular math books, the like — and took a peek. I was, after all, already collecting for my "library," even then. And these were free books! And this must have been during my junior year or so because I’d finally discovered that, despite my best intentions, I sort of liked math, or at least I liked calculus. So I took a few, most of which I still have to this day, e.g., Øystein Ore’s Invitation to Number Theory (out of which I took the prompt for Response 03), Zippin’s Uses of Infinity, as well as one thick gray volume entitled The Mathematical Experience, by messieurs Davis and Hersh (they’re not French). Being the good student I was, thinking I’d want to refer to these later, I duly lugged them to every subsequent room and apartment I lived in during college and after, on to Wisconsin, and then to Boston. I found occasion to poke into them every now and again but I never really got around to reading them per se. While I did admittedly do more math stuff in college, it was all from the philosophy angle and through the lens (comically) of Kant (a memoir for another day: My Misadventures in Historical Philosophy of Math). I think I pulled an essay out of The Mathematical Experience for a class or two, but suffice to say I hadn’t really given it a proper read until opening it up again the other night, thinking I needed a new "interesting but not too interesting" bedtime book. I’d just finished Charles Seife’s Zero: The Biography of a Dangerous Idea after all, and thought I could do with a little more toes-dipping back in.

A brief aside (as I am writing this hastily before work and can’t be bothered to structure this well)

I’ve been thinking more and more about math as I’ve found myself writing more code both personally and professionally. I think I’m not as interested in the math that might be actually applicable to the coding stuff — I’m still too much of a recovering philosophy student for that — but it stirs up the itch and I like to scratch. And there was always a part of me that thought I’d go back and do math again — I’ve had Gootman’s Calculus refresher text on my shelf for at least a decade with this intention. Now is probably not the time, given that I’m focusing mostly on bike shit and am still writing (though admittedly struggling) "the novel," but this stuff is nevertheless fun to read about, especially when it’s a "descriptive" text like the volume in question.

Anyway, this book, The Mathematical Experience is brilliant, and I’m noting it today because as I was reading a bit this morning I quite literally laughed out loud, which is not something one typically does reading math books (or maybe they do and I’ve just been missing out). It may also just be my…​ idiosyncratic sense of humor, but come on, this is funny:

I.M.: No, no. There’s nothing subjective about it! Everybody knows what a proof is. Just read some books, take courses form a competetent mathematician, and you’ll catch on.

Student: Are you sure?

I.M.: Well—it is possible that you won’t, if you don’t have any aptitude for it. That can happen, too.

Student: Then you decide what a proof is, and if I don’t learn to decide in the same way, you decide I don’t have any aptitude.

I.M.: If not me, then who?

Okay, so maybe that wasn’t the best pull quote to provide without more context, but it still makes me giggle. I mean, I’m a sucker for any riff on the old Hillel saying, sure, but also the way that these two professional mathematicians take the piss out of themselves and their "fraternity" cracks me up. Also, I love it when a book just feels Jewish. It makes me happy.[1]

Anyway, all of which is to say that books are great and it makes me happy when I can sneak in some book learnin' even though I’m probably not going to be able to get back into a classroom in the foreseeable future. Since I’m on his Wikipedia page anyway, here’s another good one from Hillel:

Say not, "When I have free time I shall study"; for you may perhaps never have any free time.

1. I’d mean to look up if the authors were Jews but I didn’t. But "Hersh" is usually a good bet, and they use both "Professor Bergstein" and "Professor Steinberg" as examples, soooooooo.

New Piece in Taper

I’ve got a new piece called "Bits" in Taper #8. A not-quite but mostly up-to-date source listing can be found on GitHub (though maybe it’ll have been updated by the time you read this; maybe not). I haven’t yet had a chance to dig into the other stuff in that issue but the contributor list looks good so you should check the other stuff out too. Issue table of contents here.

Computer poems!