Best practices considered harmfull

Allan Kelly from Allan Kelly Associates

NoBestPractice-2018-06-20-16-53.jpg

I’ve long worried about “Best Practices”. Sure I usually play along at the time but lurking in the back of my mind, waiting for a suitable opportunity are two questions:

  • Who decided this was best practice?
  • Who says this practice can’t be bettered?

I was once told by someone from the oil industry that it was common for contracts to specify “best practice” should be used. But seldom was the actual practice specified. Instead each party to the contract would interpret best practice as they wished, until something went wrong. At that point, after an accident, after money was lost they would go to court and a judge would decide what was best practice.

Sure practice X might be the best know way of doing things at the moment but how much better could it be? By declaring something “best practice” you can be self limiting and potentially preventing innovation.

Now a piece in MIT Sloan Management Review (Why Best Practices Often Fall Short, Jérôme Barthélemy, February 2018) adds to the debate and highlights a few more problems.

Just for openers, sometimes people mistakenly identify the practice creating the benefits. Apparently some people looked at Pixar animation and decided that having rest rooms (toilets to us English speakers) in the centre of an office floor enhances creativity. They might do, but there is so much else happening at Pixar that moving all the toilets in your organization will probably make no difference at all.

But it is worse than that.

Adopting best practice from elsewhere does not mean it will be best practice in your environment but adopting that “best practice” will be disruptive. Think of all the money you will need to spend relocating the toilets, all the people who will be upset by a desk move they don’t want, all the lost productivity while the work is going on.

The author suggests that in some cases that disruption costs are so high the “best practice” will never cover the costs of the change. Organizations are better shunning the best practice and carrying on as they are. (ERP anyone?)

It gets worse.

There is risk in those best practices. Risk that they will cost more, risk that they won’t be implemented correctly and risk that they will backfire. What was best practice at one organization might not be best practice in yours. (Which might imply you need even more change, even more disruption at even more cost.)

In fact, some best practices – like stock options for executives – can go horrendously wrong and induce behaviours you most definitely don’t want.

So what is a poor company to do?

Well, the author suggests something that does work: copying good practices. Not best but “just OK”. That works. Copy the mundane stuff, the proven stuff. The costs and risks of a big change are avoided. (This sounds a bit like In Search of Mediocracy.)

In my world that means you want to be getting better at doing Agile instead of trying to leapfrog Agile and move to DevOps in one bound.

The author also suggests that where your competitive advantage is concerned keep your cards close to your chest. Do thinks yourself. Work out what your best practice is, work out how you can improve yourself.

I’ve long argued that I want teams to learn and learn for themselves rather than have change done to them. But I also want teams to steal. When they see other teams – at home or elsewhere – doing good things they should steal practices. The important thing from my point of view is for the teams to decide for themselves.

Sign-up to receive these posts by e-mail and free eBook of Xanpan

The post Best practices considered harmfull appeared first on Allan Kelly Associates.

Learn WordPress & build a website in ONE day

Paul Grenyer from Paul Grenyer


When: 28 June 2018, 9am to 4.45pm

Where: The Kings Centre, Kings Street, Norwich, NR1 1PH

How much: £150

RSVP: https://www.meetup.com/Norfolk-Developers-NorDev/events/250241910/

WordPress is the world’s best and most popular website builder and this hands-on course takes you through from the basics, including installation and set up, to cover all the most useful features and tools WordPress offers. Whether you already have a site and want to manage it properly or are starting completely from scratch, this is the course for you.

You will learn to

  • set up and run a great website of your own
  • add content, images and videos
  • add structure and navigation menus
  • apply an attractive design using easy templates
  • make the site search engine friendly
  • add contact forms, maps and take payments
  • add social networking and track visitorslearn to add all the features and functionality you need to run and develop a fantastic website
  • and much, much more…


How the course works


  • Please bring your own laptop: PC, Mac or Chromebook, any is fine. Or you can hire a laptop for the day here.
  • WiFi and power sockets are provided
  • No experience is needed – WordPress is incredibly easy to pick up and you will be free to go at your own pace throughout the day.
  • All training materials will be provided after the course, so there need be no fear of “falling behind”.This is an intensive course and assumes a reasonable working knowledge of using computers and the internet, even if you have little or no prior knowledge of WordPress. If you are comfortable with using email, copy/paste, saving files/folders and navigating the internet, you should be fine! (see more advice in our FAQ here)
  • After the course you are welcome to stay around for further discussion with your trainer Toby and with each other, about WordPress, about your website and about your business.
  • After the course, you will be sent all the course materials and clear instructions for setting up your site on its own domain name (old or new). You will have a year of free hosting, after which time it is from just £8/mo for unlimited space and bandwidth.


More details here (https://wpcourses.co.uk/wordpress-training-courses/?gclid=EAIaIQobChMI0bSL8tTR1wIVSjobCh2A9gVdEAAYASAAEgJLnfD_BwE).

Number of parameters vs. accessing globals

Derek Jones from The Shape of Code

I spend a lot of time looking at software engineering data, asking, what is the story here?

In a previous post I suggested that the distribution of the number of functions defined to have a given number of parameters, might be a signature of developer beliefs about the relative cost of parameter passing vs accessing globals.

Looking at the data that Iran Rodrigues Gonzaga Junior made available (good man), as part of his thesis Empirical Studies on Fine-Grained Feature Dependencies, I saw it contained information about the number of parameters in a function definition and whether functions accessed a global (Gonzaga’s research question is in another direction; I am always repurposing data).

Are functions that access globals, defined with fewer parameters, compared to those that do not contain any such access? The plot below shows a count of the number of functions defined to have a given number of parameters, for four systems written in C; the solid lines are functions that did not access globals, the dashed lines are functions that accessed globals (code+data).

Number of functions defined to have a given number of parameters; four systems, written in C

Over all 50 projects measured, functions that don’t access globals are defined, on average, to have an extra 0.7 parameters (the fitted Poisson regression models are better than a poke in the eye {i.e., the distribution is not really Poisson}, it’s more informative to look at the plotted data).

There is a lot of variation between projects (I picked these four because they were the larger projects and showed variation in behaviors). While the shape of the distributions varies a lot, there is always a noticeable difference in the mean.

Is this difference between projects a difference in developer beliefs, a difference in application requirements, a difference in developer coding habits (and parameter usage is a side effect; are there really that many getters and setters)?

I was hoping for a simple answer, and could not find one. Since I am writing a book and not researching individual issues in detail, it’s time to move on.

Ideas welcome.

Further On Natural Analogarithms – student

student from thus spake a.k.

My fellow students and I have of late been thinking upon an equivalence between the roots of rational numbers and an infinite dimensional rational vector space, which we have named -space, that we discovered whilst defining analogues of logarithms that were expressed purely in terms of rationals.
We were particularly intrigued by the possibility of defining functions of such numbers by applying linear algebra operations to their associated vectors, which we began with a brief consideration of that given by their magnitudes. We have subsequently spent some time further exploring its properties and it is upon our findings that I shall now report.

Connecting to Slack from an IRC client using slirc

Andy Balaam from Andy Balaam's Blog

I tried to get back to an IRC interface to Slack using Matrix, and it had some problems. Thanks to Colin Watson’s comment on that post, I tried Daniel Beer’s slirc, and so far it seems to be working pretty well.

Here’s what I did:

Get a Slack legacy token which slirc will use to connect to Slack as you. Follow the instructions given at that link, and you should end up with a token that looks something like “abcd-123456768-ETC-ETC”. Keep a note of it.

Install the prerequisites for slirc, and download it:

sudo cpan AnyEvent AnyEvent::HTTP AnyEvent::Socket AnyEvent::WebSocket::Client URI::Encode Data::Dumper JSON
mkdir slirc
cd slirc
wget -q 'https://www.dlbeer.co.nz/articles/slirc/slirc-20180515.pl'
chmod +x slirc-20180515.pl

Create a file in the slirc directory you created above, called rc.conf, and make it look like this:

slack_token=abcd-123456768-ETC-ETC
password=somepassword
port=6667

Replace “abcd-123456768-ETC-ETC” with the Slack legacy token you noted down earlier.

Replace “somepassword” with something you’ve made up (not your Slack password) – this is what you will type as the password in your IRC client.

Run slirc and leave it running:

./slirc-20180515.pl rc.conf

(Make sure you are inside the slirc dir when you run that.)

Start your IRC client (e.g. HexChat) and add a server with address “localhost” and port 6667, with your slack username and the password you added in the rc.conf (which you wrote instead of “somepassword”).

This mostly works for me, except it has a tendency to open a load of ad-hoc chats as channels, so I have to close them all to get a usable list.

Main memory: the crucial component that vendors don’t mention

Derek Jones from The Shape of Code

CPU performance hogs the limelight when people discuss the year-on-year increases in computing power that used to occur.

This focus on cpu performance was/is driven by marketing, the people with the money either don’t want customers thinking about the performance impact of main memory size or speed, or want them to treat the processor as the most important component of a computer. Vendors want processor performance to drive customer purchase decisions.

Hardware manufacturers used to entice new customers with low cost machines, containing minimal memory. Once a customer started to use their shiny new computer, they found that it did save them lots of time and money, but also they needed more memory (which could only be brought from the manufacturer and was not cheap).

The plot below shows the prices IBM charged for System 360s, in 1966. Anti-trust investigations uncover all kinds of interesting data, like selling low-spec equipment at a loss to entice customers and make life difficult for competitors (code+data for all plots).

Profit margin on IBM 360s sold with various memory sizes

The plot below (data from the 19 Aug 1985 issue of ComputerWorld) shows how the price of computers increased as the minimum about of memory they supported increased.

Yes, in 1985 top end computers came with over 50M of memory; but most customers thought themselves lucky if they had a few megabytes.

If the processor is slow, it just takes longer for programs to run. If the computer does not have enough memory, programs cannot run. For most applications memory requirements are addressed first, followed by processor performance; memory requirements is the number one issue. The optimizations that commercial compilers could perform were limited by the memory capacity of developer machines.

List price of computers, in 1985, supporting the given minimum amount of  memory

Intel’s main line of business used to be selling memory chips, but these chips became commodity items as more companies entered the market; Intel bet the farm on selling processors and the rest is history. As a seller of a unique product it was/is in Intel’s interest to spend lots of money on marketing the benefits of processor performance; sellers of commodity items (such as memory chips) don’t have nearly as much to gain from generic product marketing, because customers may choose to buy from other sellers (in such markets sellers have to concentrate on marketing themselves).

Memory capacity/speed and cpu speed are two aspects of system performance; they need to be balanced to meet customer drive application requirements. The plot below shows the SPEC cpu integer performance of 4,332 systems running at various clock rates; the colors denote the different peak memory transfer rates of the memory chips in these systems (code+data).

SPEC cpu integer performance vs. cpu clock rate

These days (and perhaps in the past, I don’t have any data), memory performance is a much better predictor of system performance, but vendors don’t have an incentive to market this fact.

Introduction to Laravel Workshop

Paul Grenyer from Paul Grenyer



When: Wednesday, 20 June 20 - 9:00am to 4:45pm

Where: Kings Centre, King Street, Norwich, NR1 1PH

How much: £85

RSVP: https://www.meetup.com/Norfolk-Developers-NorDev/events/250343445/

If you would like to start using the worlds most popular PHP framework, this is the workshop for you.

We will cover from installing Laravel to building a basic application. Everyone will learn along as we go from a freshly installed Laravel application up to creating a basic web app that interacts with a database.

Course Details

We will aim to cover the following (subject to change and class experience)

  • Routing
  • Using Blade (templating)
  • Controllers
  • Validation
  • Config/Env
  • Using Eloquent (database ORM)
  • Laravel inbuilt Auth
  • Artisan (CLI commands)
  • File Storage

Instructor

Simon Bennett is a Software Consultant who works with Laravel daily, helping clients update there development practices and coding software for startups. He also runs his own SAAS for backing up DigitalOcean servers which of course is all built with basic Laravel.

Prerequisites

This beginners workshop will run through simple code as we learn about Laravel.

Basic knowledge of PHP is required, I would recommend you know you know basic OOP.

To save time on the day, you will be contacted directly before the workshop with a guide on setting up docker. The reason we use docker is to make sure we are using identical environments on Windows/Mac/Linux.

Since Laravel used to build web-based applications (mostly), it would be helpful to a basic understanding of developing websites in PHP and MySQL.

  • Bring your Laptop
  • Have Docker installed
  • A good IDE like PHPStorm is strongly recommended
  • Working command terminal
  • A GIT client installed