The Blog

5
Feb

Proofing the App

Posted by | Development | Leave a reply.

Courtesy Boston Public Library, https://www.flickr.com/photos/boston_public_library/8190857925

I wanted to make calzones for dinner last night.  It was getting late, but in my mind I could already see the ricotta and broccoli filling and smell the melted cheese.  I usually buy a blob of dough from one of the local pizza places, but this time I was going to start from scratch.  The yeast, though, gave me pause: would it rise?

In baking, there’s a concept of proofing the yeast.  A baker is never certain that the yeast is still active, and it’s a sad day to anticipate and work on bread only to find a small hard lump of unrisen dough at the bottom of the bowl.  So before kneading in flour, the yeast is mixed with water and sugar.  If bubbles form, it’s working and you carry on; if it stays flat, you toss it out and avoid heartbreak.

My yeast did foam, but so slowly that I would have been eating my calzones somewhere around midnight.  So instead I shifted gears and made soft buttery pretzels, which don’t need to rise for so long, and they were delicious.

What’s the connection to software development?  App ideas need planning and proofing, too.  There’s little worse than spending large amounts of time and money creating a beautifully finished product only to watch it lie unused.  That expenditure might be avoided with development’s form of sugar and water: requirements, design, prototyping, and a minimum viable product. Continue reading


2
Feb

Write Once, Debug Everywhere

Posted by | Development | 1 Reply.

"Write Once, Run Anywhere'? Why does that sound so familiar...

“Write Once, Run Anywhere”? That sounds awfully familiar…

Or Why We Still Have To Test In Every Browser, Web Standards Notwithstanding

It’s pretty seldom that anyone mentions web pages these days, other than in historical reference to days long gone by (yes, a whole few years ago). Web sites, sure, but not if what is really wanted is to replace something that, not so long ago, would have been some native code for a smartphone (or a little further back still, a desktop computer). Generally speaking, the most common term tripping from client’s lips these days is ‘web applications’ – or webapps, because who has time for spaces and proper spelling, amirite?

Of course, the client in question is almost certainly not interested in a webapp because they’re hoping to take advantage of the unique properties and capabilities of any particular browser (unless they’re looking for a line-of-business intranet application in IE8, in which case, you have both my scorn and my pity). Everyone wants their app to have the potential to reach the widest audience possible – and that means supporting all the mainstream browsers.

Oh, and all of the mainstream mobile devices, and their browsers; and maybe smart TVs, consoles, and I hear they’re coming out with, like, iWatches and stuff, can we target those too? Continue reading


29
Jan

Adding Dynamically Named Methods to Python Classes

Posted by | Development | Leave a reply.

Photo by Alex Proimos, https://www.flickr.com/photos/proimos/4529149455

Photo by Alex Proimos, https://www.flickr.com/photos/proimos/4529149455

I recently wanted to dynamically add methods to a Python class based on a list of relationships. The model class, Animal, was related to a number of description classes like Color and Sound. For a given animal, I wanted to be able to easily get the values for its descriptions, such as:

elephant.color_values()
# => ['gray', 'silver', 'taupe']

Although I could have simply written non-dynamic methods like color_values, noise_values, etc. in the Animal class, I had already defined a list of the relevant class names and I prefer not repeating code. So instead I dove into Python’s dynamic pool.

Continue reading


7
Jan

Behold! (JavaScript Views)

Posted by | Development | Leave a reply.

Spaghetti is great. Spaghetti code, not so much. Let's make sure we don't have to untangle our JS code, shall we?

Spaghetti is great. Spaghetti code, not so much.

JavaScript has the propensity to be very untidy – if you let it, it will sprawl all over the place. Hundreds of global variables scattered across dozens of files, messy half-measures towards object-orientation, mixed in seemingly at random with ungrouped functions – anyone who’s had a client bring them a failed project from some other development team knows just how bad it can get.

JavaScript also has the potential to be neat and tidy, and keep private variables and methods truly private – if you know how. Closures and an understanding of prototypical inheritance are the secrets, of course – but these are general purpose tools. For more specific scenarios – say, attaching logic to an existing or dynamically created view – tidy encapsulation is just the beginning of the suite of features we covet.

We’d like to be able to declare and bind to page elements all in one spot, so we never duplicate jQuery selectors unnecessarily, it’s clear what we’ve bound when looking at the view, and we can easily re-use those bindings through a variety of functions. Heck, while we’re at it, we’d like to be able to bind events to these elements using the same mapping we’ve just created (maybe with some nice syntactical sugar to simplify statements), and assign arbitrary functions within our view to handle the events.

All of this should be neatly encapsulated within a JavaScript ‘class’, and instantiable when and where we desire; and as long as we’re dreaming, how about a nice, modular system that keeps private variables and methods from being exposed to other classes, automatically offers us safe, localized references to jQuery, underscore or whatever other libraries we’re using, and offers us the ability to initialize the module under conditions of our choosing.

Pinch yourself, it’s not a dream. After a few projects working with Backbone and Marionette, I was loath to do without those tidy and functional views and all the features above (and more) on future projects, even those that aren’t a good fit for Backbone. Thus, Behold! A view framework was written.

Behold is for those who like the tidy encapsulation and functionality that frameworks like Chaplin and Marionette provide for js views, but don’t need everything that Backbone offers, and can’t justify the extra weight of it.

Sold on the concept already? Go take a look at the Github Repo.

Need more convincing? Carry on, then. Continue reading


31
Dec

2014 Review: Day 10

Posted by | Development | Leave a reply.

Last day of 2014, last day of our look back at the Art & Logic Developer Blog’s year…

"I Saw the Figure 5 in Gold" by Charles Demuth

“I Saw the Figure 5 in Gold” by Charles Demuth

 

My turn again, in which I think about software development, and how important it is that clients understand its actual nature, and how it differs from other kinds of work…

Continue reading


30
Dec

2014 Review: Day 9

Posted by | Development | Leave a reply.

Taking an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time, as the last few days of the year slip by us…

blogpost_ipython_screenshot3

 

In our penultimate look back at 2014’s developer blog, Fran Bull talks about using interactive widgets inside of IPython notebooks:

Continue reading


29
Dec

2014 Review: Day 8

Posted by | Development | Leave a reply.

Taking an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time, as the last few days of the year slip by us…

William Allen White

William Allen White

My turn! Earlier this year I wrote about a little Twitterbot that I wrote to periodically tweet out snippets of lyrics from songs by the band They Might Be Giants…

Continue reading


26
Dec

2014 Review: Day 7

Posted by | Development | 2 Replies.

As 2014 winds down, we’ll take an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time. 

Via JMack on StackOverflow

Via JMack on StackOverflow

Christopher Keefer is back, showing a useful technique for selectively hiding option values from inside of select controls:

Continue reading


25
Dec

2014 Review: Day 6

Posted by | Development | Leave a reply.

As 2014 winds down, we’ll take an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time. 

Photo by Richard Atkinson, http://www.flickr.com/photos/richardatuct/6719197685/

Photo by Richard Atkinson, http://www.flickr.com/photos/richardatuct/6719197685/

 

Noah Miller gives us a useful list of git commands that are handy to have at your fingertips….if you can remember them:

Continue reading


24
Dec

2014 Review: Day 5

Posted by | Development | Leave a reply.

As 2014 winds down, we’ll take an opportunity to look back at some of our most-read posts from this year, in case you missed them the first time. We’re halfway done! 

CGWinPage

Here on day 5 of our year-end blog review, Christopher Keefer shows us how to create custom information windows for Google Maps:

Continue reading


Art & Logic has been developing software on a work-for-hire basis since 1991. We have worked with over 900 clients in a diverse set of industries, including education, aerospace, music technology, consumer electronics, entertainment, financial services, and many more.


2 North Lake Avenue, Suite 1050
Pasadena, CA 91101
626-427-7184


Contact Us
Copyright 1995–2015 Art & Logic, Inc. All rights reserved. All trademarks associated with the registered trademark "Art & Logic," including but not limited to "ArtLogic" and "artandlogic.com," are owned by Art & Logic, Inc. Terms of Use and Privacy Policy