Sunday, July 23, 2017

T'were Better Back In't Olden Times ...

Dribs and drabs of information come to us on the aetheric waves that bounce around inside the crystal sphere that surrounds our local universe (Pluto is so not included) and are eagerly circulated around the little group, for actual excitement is not easy to come by in Moux. In the latest splatters, we have learnt that not only is there a prospective tenancière for the bar, but apparently the legal disputes have been resolved, and so there is no judicial impediment to its being joined in holy matrimony imminent reopening.

Also, we learn that the majority of the problems were, as all suspected, largely of the mairie's own making: for what they did (or so it would seem, according to that nice young Mr. Reliable of the well-known local family, the Sources) when leasing the bar to Ivan and Nadège, was actually hand over title to the licence IV that went with it. (This is a bit of paper that says, officially, that you are allowed to serve alcoholic beverages on the premises and is thus more or less a sine qua non for running a bar: the thing is, of course, that they don't actually make them any more - can't get the wood these days - so they trade for quite a hefty price.) So it seems that the mairie eventually clenched its collective sphincter and bought it back, and lo! the problems have disappeared.

Don't know where the money came from, but it would be rather nice if they could rummage down the back of the sofa and come up with enough small change to pay for the connection to the optical fiber that's currently being laid in the village, on its way to Douzens and Conilhac and even Fontcouverte: but apparently our Dear Leader can see no reason why people should want high-speed internet access.

Personally, I'd been led to believe that the whole operation was being subsidised to the hilt by the conseil général and so in fact it would cost the village sod-all: maybe I'm wrong, or maybe Réné is just having a hissy-fit. Whatever. What we've got is still better than good old dial-up, back in the days when we had the then hi-tech US Robotics modem chundering along at the breath-taking pace of 19200 baud, and we had to yell at the kids not to try phoning because we were doing research on kitty porn.

Sometimes the STOOPID it burns and it gets to me, and you'll just have to put up with it for a short time. Back in the day, about 40 years ago, the first lesson we learnt as wet-behind-the-ears programmers was "validate everything, as soon as you can". (Not actually true, the first lesson we learnt was "The upstairs bar at the Commercial/permanently reserved table at the Stable opens in 30 minutes, now would be a good time to go before some numpty from the Gas Department decides to try it on", and the second one was how to read a stack dump, but you get my drift.)

But somewhere along the yellow brick road to this brave new digital world in which we live, it would seem that the principle has been either forgotten, or maybe accidentally tossed out when the trousers went into the wash. For I am in the throes of implementing a data exchange system involving curl, and JSON strings (if your eyes are starting to glaze over, feel free to skip a couple of paragraphs), and handling incoming SMS, and amongst the data that I have to handle is the IMEI of the data source.

Should not be a big deal, for I already do that - it is just a string of 15 digits - but for some strange reason the database guys across the table from me decided to push it as an integer, rather than a string. So I called. "Could you not", I asked, "send it off as a 15-character string, left-padded with zeros if necessary? Because as an integer, it blows up the bloody Linux library routines, and I shall have to go modify them."

"Oh no, can't do that, it's an integer."

"Why not just change the typedef in your database to CHAR(15) or, if that's too much hassle, just export it using one of the many SQL functions available for just this porpoise?"

"Oh no! If we changed it to CHAR then people could just type any old thing and we'd have to validate it, and if we used a typecast for export that would mean extra work for us, and besides our JSON wouldn't be pure!"

Christ, even the bloody key-punch machines had programmable templates, such as "ten-character field: first three upper-case alpha, next six numeric digits only, last one either M or F": I for one am not entirely sure that "progress" is quite the right word to describe what we've done over the last four decades.

Still, we shall see just how "pure" their bloody JSON is once I've buggered it: in the interim I have modified the appropriate libraries to use 64-bit integer values, changed my code to do some special handling, and perform all the validation that should (in an ideal world) have been done at the front-end in my code (something which, I admit, I was going to do anyway because when it comes to providing me with guaranteed clean, sanitized data I don't trust them worth a damn).

Of course the downside is that when I do detect an error (and believe me I will, I just know it) I have no way of getting that information back up the chain to the actual database, so they'll just have to live with things inexplicably failing to respond as they should ...

Not sure what to make of this one: a request for tender from the CNRS which popped up in my inbox this afternoon. "Avis de publicite No 51027 : 'tableau de bord de suivi de la construction de cartes mentales' a ete publie ce jour." Skipping the blabla, this is asking for a "dashboard to follow fabrication of mental cards" and it's those last two words that rather worry me because I can't work out what they're doing in that sentence.

Just maybe, as "carte" could equally well mean "map", they are calling for a device to track the construction of memory palaces, or the oeuvre of Schuiten and Peeters ... then again, maybe not.

Whatever, evaporation has happened and all the vitamins have inexplicably disappeared from my glass so, ever-careful as to my health, I must go refill it. Mind how you go, now.

No comments:

Post a Comment