Recurse Center, 2014-07-15

  • Micheal demo-ed paredit mode in the emacs-club meetup, and I learnt a bunch of things I didn't know about it.
  • I added simpler tests (just one test, really) for cinspect using a dummy module, and Tom started reviewing the code. I wrapped up the code (for now), until there is further interest in the project (in the form of issues/feature requests). I haven't yet announced it anywhere, but I probably should.
  • I helped Teja (a friend of mine, not in HS) with a simple function to use bisection to solve an equation. He's just starting off with Python, and am looking forward to see where he goes with it!
  • I learned a few things about the V8 code base, thanks to sitting next to Marcus, who is poking around with it.
  • I started looking for other things to do, and went through a little bit of the Audio programming book, but didn't do it for too long, until I stumbled on Think Complexity and started reading it. I read the introduction, and got through a few of the exercises on Graphs.
  • I also played around Flask-Sockets to help figure out answers to some questions on Zulip, and was able to get a Hello World working.
  • In the process, I discovered the awesomeness of the gist-mode in emacs. I had always wanted gist plugins to let me list and update my previous gists, but most of the plugins didn't seem to have it, or the feature wasn't very discoverable. I had tried writing something like that for Canopy, one or two years ago. Discovering that gist mode has this feature, was awesome!

Recurse Center, 2014-07-14

  • Monday morning checkins for our group had only two people. That was strange! Very strange!

Work on cinspect

  • I wrote up a README since David (an alum at Hacker School) showed interest in the project. But, he probably isn't that interested anymore since the code base is Python2.x only.
  • I got rid of assumptions that method names would start with the module name or the type name, and actually look up references to the names in the definitions of types or objects.
  • I also improved the test-suite to actually download sources of CPython and index them. They take very very long!!
  • I tried to get it working with Numpy, but getting all the headers to include wasn't as easy as I assumed it would be!

Recurse Center, 2014-07-11

  • I didn't spend much time at Hacker School on Friday. I reached a bit late for the start of "Recursion day", and did a few problems. The problems were simple, but interesting. After lunch, I headed home to start to Philly.
  • Later in the day, I did some refactoring of the code to have the index reader and writer split out.
  • I also added a to be able to install the package using the standard tools instead of PYTHONPATH hacks and stuff.
  • During the refactoring, I again hit this bug. I found out from Pankaj that he has from __future__ import print_function, absolute_imports at the start of his files these days. I think I'm going to do it, too.

Saturday & Sunday

  • I didn't do much during the weekend. I ended up adding a TXT record for SPF for this domain, to work around Gmail marking bulk mails for the childrens-park newsletter as spam. I was able to send one newsletter, but not sure if only the SPF is enough or I'll have to setup DKIM, and other stuff. (I don't understand most of these acronyms!)
  • Someone mentioned on Zulip, and I really liked the idea. I have started using it for a couple of projects and also got rid of a couple of my bashrc aliases, and created a new project command with completions of the directories in my project directory. I like this setup, as of now.

Recurse Center, 2014-07-10

  • I was just refactoring bits of the code, and clubbed all the different visitors into a single visitor to speed up the code.
  • We also had a birthday celebration of one of the facilitators.
  • I also gave my first presentation at Hacker School. I thought it was cool. Not sure if everyone thought it was.

Recurse Center, 2014-07-09

  • Unicode issues: it turned out that (atleast) one of the files had a character that wasn't UTF-8 encoded. I got around it by trying 'utf-8', if not falling back to 'iso-8859-1'. Now that I think about it, I should fallback to 'utf-8' with replace, if that doesn't work either.
  • I did a little clean up on the way the indexes were stored, to be able to have a getfile, to mimic inspect's API.
  • I also "improved" the IPython startup script to monkey-patch the source code formatter/colorizer to not break with C modules.
  • The one-on-one with Allison was pretty useful, and I feel a little more relaxed now.
  • I paired with Kyle to get streaming audio working for his OSX app. It doesn't work yet, but we made progress! Hope to get it working today.
  • I spent the late evening trying to refactor some of the code and clean it up.
  • Also, updating the py-clang code to the latest version fixed the issue of unknown cursor kinds.
  • I may present my project in today's presentations!

Recurse Center, 2014-07-08

  • I had gone to the emacs weekly meetup, and Samer demonstrated some of the things he liked, and discovered recently.
  • Stopped worrying too much about what the best way to index the data was, and just went about getting the tests running one by one. There is still a small hack, but I got all the tests running except the source for modules.
  • At the end of the day, I thought I had the code to get all the tests passing, but I hit some unicode issues with json serializing, and don't have all the tests passing, yet.
  • I paired with Kyle to work through a simple example to generate a note of a specified frequency.
  • I spent some time reviewing my first month here, and wrote up some notes in preparation for the one-on-one today with Allison.

Recurse Center, 2014-07-07

  • As preparation for a one-on-one this week with one of the facilitators, I was wondering if I was really getting better as a programmer, by doing what I am doing.
  • I have heard at numerous places that reading and reflection are keys to getting better. I feel like I haven't been giving these things much attention in the past couple of weeks. I don't catch up on reading all the awesome reading material shared on Zulip and I switched from writing this blog post first thing in the morning, to any-time-after-lunch. I don't think this worked out very well. Writing the post worked as a way to reflect on what I had done yesterday, and what I should be doing today. So, I am back to writing the blog post, first thing in the morning!
  • Yesterday, I worked on indexing the Python sources in a way that the inspection code can look up, later. During this process, I found that my code to use libclang's AST wasn't generic enough, and I had to clean it up to be able to extract useful information from any file in the cpython sources.
  • We also got to attend a super-awesome talk by Steve Labnik! He talked about his progression from being an application developer, to writing libraries, to working on languages (as a professional developer). He made a lot of interesting and inspiring points during his talk. Some of those that stuck with me are:
    • None of these is particularly harder than any of the other. Depending on each person's personality, or the way their brain works, they are good at doing one or the other.
    • Getting good at programming is a matter of showing up, more than about the "genes". He repeated quite a few times that he disliked the idea of "baby hacker", and left out the story of his childhood and college programming days! I'm totally stealing his idea of meeting every saturday at 1pm, with a bunch of friends and working until it was 10pm or so, when they could get cheap beer and food! And he did this all through his college! It is interesting that this idea is so similar to Hacker School!

    It was a very enjoyable and inspiring talk on the whole.

  • The plan for today is to actually have the parsed information dumped into some persistent format, and modify the inspect code to actually use it.
  • I will also be pairing with Kyle for a few hours on working through some of

Recurse Center, 2014-07-06

I took it easy during the weekend, and went on a nice camp with my a cousin's family to TobyHanna State Park for a day or so, and spent the remaining (long) weekend at their place in PA. It was a pretty nice break!

Yesterday evening, I talked to Madhu about how ugly my code looked while I was trying to use libclang, and he told me that he found a lot of wrapped C++/C libraries end up being that way, and I also realized that using the Python AST library seemed much cleaner, because it just contained Python objects, but representing C/C++ objects in an AST and interacting with them in Python, isn't that clean.

I cleaned up my code, and removed all the ugly regexes to use libclang to do the parsing of the libs, and get the source code. I basically got all the tests passing, but they were taking an order of magnitude longer to run. So, I guess the next step is to cache things somehow.

I also added support for viewing the sources of built-in types. It was pretty simple, once I had everything working with libclang.

Recurse Center, 2014-07-02

Recurse Center, 2014-07-03

  • I got distracted trying to add a hack to Hacker School's blaggregator, to enable posting to different channels on zulip.
  • I learnt a few things about Django. Commented out references to views that don't exists breaks templating. Formsets didn't seem very convenient to use, for editing data showing the user only partial forms.
  • I played around with Clang for a bit, to try and use libclang to parse the C code for inspection, instead of writing one myself. It sometimes feels like an overkill, but it feels like it'll make the whole code more robust. I'm not sure. I'll need to play around for a bit more to decide.
  • I also finally got around to fix the resolution of my tty shells. I was in a bus, and wanted my laptop's battery to last longer, and decided to use a tty shell with just emacs running. But, the resolution sucked. So, I fixed. Essentially it involved removing a blacklist file that an old version of Nvidia drivers left behind in /usr/share/grub-gfxpayload-lists/blacklist/ and setting GRUB_GFXMODE=1920x1080 in /etc/default/grub.
  • Later in the evening I also bought the domain, given there were a bunch of people buying cat domains, and talking about it on Zulip!

Update [7/7/14]: I forgot to write about the presentations. There were interesting presentations!