I finished the #larder #api #docs today! It’s so fiddly to include all the code samples and stuff, but now it’s done. My next steps are to build the UI for developers to create and manage their client apps in Larder, and make sure the oauth “authorise” page is all styled nicely, then that’ll be done.
In other news, I added the #changemap search field autocomplete suggestions to the “add a new suggestion” form last week, so you have to click “no, my suggestion isn’t any of these” if there are matches. And since then we’ve had zero new suggestions. It definitely works, I tried it, but I guess nobody has a new idea that isn’t a duplicate. Success? 🤔
Not a lot was done today. I slept badly so gave myself permission to have an easy day. However, in the evening I managed to get some more done on the #larder #api docs I’m writing. Thankfully some of it can be copied from the Exist docs. There’s still a lot to do though. Literally a thankless task, but I want to write high quality docs so the barrier to people making a thing with the API is as low as it can be.
My work on upgrading #exist continues. I’ve got the #api working and fixed a bunch of minor things that have changed. So many various dependencies had to be upgraded all at once to work with a much more recent #django version that it has touched many disparate things. Still, no showstoppers so far. Just a lot of fiddly work.
Over the last 3 days of #client work I’ve learnt the following:
- The #Flickr #API is pretty awesome.
- Masonry is a great JS framework for styling content nicely.
- Masonry is a terrible framework for styling dynamic content that’s retrieved from another website (such as a photo feed from Flickr). I had to apply so many hacks to make it work the way I needed it to.
- A 5 hour job will always take at least twice as long, especially if you haven’t coded JS or jQuery for a while.
Spent most of today catching up combined business and life #admin - form filling and printouts.
Also did some work on an interesting client project that’s using the #Flickr #API. Flickr’s API must be one of the best ones around, especially because they have an API explorer so you can try out every call you need to make to see the response formats.
Realising that doing the API first would have made retrieving challenge data so much more easier than how I actually wrote it. When I was building the MVP it didn’t really matter how the code looked, as long as it worked.
Looking forward to rebuilding API-first once I finish getting all my user survey results back and can consolidate a new functionality list.
Set up some more of the #larder #API today, including the all-important ability to create a new bookmark. Made myself some OAuth2 credentials and started the scaffolding of a new #android app! Think I’ll use the “navigation drawer” pattern to hold the list of folders, which makes the most sense to me for this app’s structure, but is new to me (I prefer tabs). Reagardless, with a hardcoded access token in place, I managed to get a list of folders displaying, so I think that’ll do for tonight.
Also sent out the feedback survey to the second group of people who got invites, but none has responded yet. It may just be bad timing but it really bruises my banana that people can’t be bothered. I guess it’s a lot of effort if you don’t care about the app at all, which is fair enough (but then why did they bother signing up? Curious). Thinking of culling everyone across both groups who hasn’t responded in a week.
I’m back from a few days off to get to know people on the island, which was lovely. Yesterday and today I’ve done some stuff on #kiomo:
Last night I played with #swift a bit more. I’m slowly porting my #littlelogs #ios app from #objectivec to #swift. It feels good to actually write some swift code, because the ideas really aren’t sticking in my brain just from reading about them. I’m really enjoying the syntax so far, but I’m a bit frustrated at the extra coercion needed to get swift to play nicely with #json, since I deal with #API results a lot. #laterlog
Oh #littlelogs, so much in the last few days! Let me catch you up:
- selected and applied new not-embarassing skin to #kiomo
- implemented a grid-edit view for estimate line items
- got the #dotNet #API patch action working on estimate line items, which was an unexpected challenge (and great learning opportunity). I think it could make a good #blog post - it took me a long time to find the answer I needed, and there were an awful lot of wrong answers for what should be a fairly common verb to implement.
- got patch-on-cell-blur working in the grid
- spent two awesome days with my 10yo nephew doing fun things like learning about circuits and making Christmas cards, making our own rice paper (and painting it with food colouring before eating it), learning chemistry by making sherbet, and watching BattleBots.
Well! I now have all of #kiomo’s basic #data structures and actions working in the #API, along with an ugly front end. Enough to be coherent, but not detailed. I think it’s time to implement a #frontend which is a bit less… embarrassing, before adding any more complexity. This will be my task for tomorrow.
preview endpoint to the #littlelogs #api, so clients can preview the parsed HTML of a log before posting it. Handy for emulating the web’s preview/post flow. Also updated the #docs to mention this endpoint, and clarified the params needed to post and preview a log, and post a comment. They’re still pretty sparse though 😐
Yesterday I was pretty interrupted, so not as productive as I’d hoped. Lots of #learning about things like action filters in Web #API and how they can be used for parameter injection (which makes things oh-so-much easier to mock during #testing), better practices with mocking, and fleshing out some more unit tests. #laterlog
Today I’m spending the day with my nephew!
Yesterday I decided I’d learnt just enough #mongo to be happy to move forward for now. So I did the proper thing: tidied up what I’d done, #refactoring fun times, adjusted for IoC, and started to put unit tests in place for repositories and controllers. I’m about half way through - I’ll continue with that today. I want to take care and lay a good foundation for the #API, before I start building the really meaty stuff. #laterlog
This morning I set up a bunch of DTOs and hooked in object mapping. The rest of today was all about #mongoDB. I implemented #API support for line items inside #estimate documents, and learnt about how to work with nested arrays and nested documents in mongo. There’s an ugly front end there for those actions now too - I’m itching to rebuild it already.
Today I started hooked up #AngularJS states and resources in #kiomo’s front end (yay, states!) and did a bit of cleanup. I got the #mongo data store created and hooked up with the back end #DotNet #API, with a simple #estimate entity and CRUD actions. I also nailed down the last niggly part of auth, left over from last week (user ids are now being populated properly in the user context).
Tonight I’m learning more about #SignalR to prep for implementation maybe late this week.
Big chat with @belle tonight about the viability of Exist (we seem to have these pretty regularly) but fortunately after initially having differing opinions we both came to the same conclusion. We'll next focus on #mood pretty much exclusively, hiding a lot of other functionality, and see how that goes for a while.
Did a little bit of #client work this afternoon and followed up with some more work on the #exist #oauth2 client management views. Nearly ready to go. I'm under no illusions that this will make a big change to our pretty terrible #api adoption, but taking away any barriers I can will surely help.
Can't find a logical reason for this, given that the #littlelogs api handles it fine with or without (hence, testing with curl was working fine), but if it weren't for this StackOverflow answer, I likely would have gone completely insane.
I deployed my #littlelogs #api changes! You can see some new pages for managing your apps (both as a user and a dev) on your account page, and read the (very sparse) developer docs I've just added. I'll flesh those out over the coming week.
The most exciting part of this is that the littlelogs API is open for business! Anyone can create an OAuth2 API client application and make a native iOS app, or a Slack bot, or a terminal client, or do some cool visualisation with tags or something, I don't know. Go forth and create!
Today I've been working on the #exist #oauth2 client management interface allowing any user to create a new read/write client for our #api. I feel like I've got barely anything done this week, including this task — I won't get it done today, and I don't know if I can be bothered finishing it over the weekend.
Oh well. There's always next week.
The PHP Oauth2 libraries for Fitbit that I could find are full of issues and/or require multiple dependencies (and rely on Composer to install them).
I get that frameworks and libraries have their place, but they need to be easy to install, understand, and use.