« July 2006 | Main | September 2006 »

August 31, 2006

Lighter moments

A lighter hearted day; some things I found amusing


Yes, that certainly IS a bump in the road



Bear Pairs!


And as I was clipping my toenails, I wondered how prehistoric man kept HIS toenails short ...
Picture of my toes NOT included. There's a limit to what you want to see, even on MY blog!

Posted by gje at 08:48 PM | Comments (0)


Related topics: via article database
More about Graham Ellis of Well House Consultants

August 30, 2006

Staff Meeting

With Well House Consultants growing - just over a month now until we open Well House Manor, and lots happening on many fronts - we've instigated a monthly staff meeting. It's to ensure that everyone's in the picture as to what has been happening in all departments, and what will be happening in the coming months. It's to allow us to reinforce the company line and ethos so that none of us drift away from our objectives, and the strategies we're applying to achieve them. And it's to give everyone a chance to make inputs ... in addition to chances that are always open during the month. Sometimes, the more formal setting helps.

Here's a couple of inputs that came up, from Christne and Leah, during yesterday's meeting.

"The travel reps used to be so helpful on our holidays, and it was really worthwhile going along to the welcome meeting. But these days, they're not telling you about the local shops and cafes near the hotel and where to get loacl buses - they're intent only on pushing their own high priced excursions".

"Should we provide a vending machine to sell things that people might have forgotten to bring when they're staying with us?"

These two inputs have both 'hit' our thoughts - taken us in directions that we perhaps hadn't thought to explore fully prior to the meeting (excellent - THAT is one of the meeting's objectives). And indeed after the meeting, combining Leah's and Christine's thoughts lead us to some firming up of strategy ... and how to tactically move towards it.

Resolved ... that we'll be looking at vending a limited selection of items, both technical and nontechnical, that people may have forgotten. Whether we do so through a vending machine or via front desk sales remains to be evaluated, and has been set down as an action.

Resolved ... that items we sell will be supplied as a service rather than as a profit centre; in that way, we'll be happy to advise our clients of other products and greater ranges that are available close by.

See all my talk of "objectives", "strategies" and "tactics"? ... in order for us all to see where we're headed, I've laid down a few definitions and details here.

Posted by gje at 08:35 AM | Comments (0)


Related topics: via article database

August 29, 2006

Bath - a tourist city on our doorstep

August Bank holiday - and a day out on Sunday revealed busy roads in the extreme; best to explore somewhere local. This summer, we've not travelled any great distances - not because we're looking to avoid all the chaos that's been going on at the airports, but because of 'the Manor project' that I mention here from time to time ... both because we've not wanted to be away for more than the day, and because we're learning that much more about our own locale so that we can better provide information for our visitors. And there are some real gems.

The town of Frome is only about 12 miles from us, although its across in the next county in the extreme corner of Somerset. A place I had just passed through many times over the years we've lived in the area and never stopped. But it turned out to be a real jewel. Quaint little streets, interesting shops and cafes, a river running through the centre, a museum ...and somewhere that we'll go back and explore in more detail in the future. (more pictures)

Bath, again only 12 miles from Melksham, is enormously famous and with plenty for the visitor to do ... and we don't even need to take the car as the bus that passes right by our place is in the heart of the City well within 30 minutes.. On Sunday afternoon, Bath was crowded but comfortable and what a glorious way to spend the public holiday - walking by the river, listening to the band striking up in the park, and eating an ice cream. (more pictures)

Posted by gje at 06:21 AM | Comments (0)


Related topics: via article database

August 28, 2006

Image maps for navigation - a straightforward example

Image maps can be a really simple and effective way of selecting from a series of options - a little bit more flexible that straightforward HTML links. We use an image map on every one of of main "Well House Consultants" pages - click on any on the languages named in our banner, and you'll be taken to a page about thet language, etc ...

Yesterday, I grabbed a series of possible "theme" pictures ... details of just what I'm up to another day ... and I want to present them on a single page for browsing, with the ability to zoom in on any one of them. Perfect use for an image map; try clicking on one of the thumbnails here and you'll see what I mean.

If you would like to see the source code or come on a course to teach you ... well ... just click on the links I've just given you.

Can you work out what links all 16 images in my example?

Posted by gje at 07:49 AM | Comments (0)


Related topics: via article database

August 27, 2006

Is Perl being replaced by PHP and Python?

I was transferring some Perl code into PHP this morning, and thinking back to comments made to me that Perl seems to be fading away, whereas PHP and Python are growing. Has Larry Wall and the Perl team lost its way, then?

Part of the lesson is in my comment that Perl SEEMS to be fading. In my particular world, where I'm predominantly involved in training people, there's a call for my services at times when a language or system is fast growing, as that's when there's a shortage of skills in the field and people moving afresh to it. I've been passed graphs of book sales, showing a slight drop in Perl and a growth in PHP and Python, but then the same "front-loaded" comment applies - people will buy books on Perl as they learn perl - early on in their experience, and on Python as they're just hatching their first programs on Python.

Perl 6 has been rather too long in coming for its own good - six years last month since it was announced - and that has lead to a hiatus. There's little point in developing new extras for Perl 5 when they'll need to be re-engineered for Perl 6, and there's also a natural reluctance on the part of decision makers to start new projects with new groups of employees using a syntax who's deprication plan has already been mooted. But that's not to say that Perl 5 doesn't continue on in fine health, and as an excellent language for many, many applications. And if you read into the detail of Perl 6, you'll find that (through ponie) the old syntax will still be very much useable into the future. I rather suspect that we'll see a resurgance of Perl when "Perl 6" comes out. Whether it regains the same market share that it had six years ago, I don't know and I won't hazard a guess; only time will tell.

Posted by gje at 08:33 AM | Comments (1)


Related topics: via article database

Useful links: Python training, Perl training, PHP training

August 26, 2006

Course scheduling and Geekmas - are they traditions yet?

How many years does it take to establish a tradition?

Can I say that this is the time of year when, traditionally, we schedule next year's training program? It's something that we've done here at Well House Consultants since the Summer of 2000, and prior to that it's something I used to be involved in every August (see here and here) at First Alternative. Anyway - next year's course dates are all up on our web site - see http://www.wellho.net/course/index.html and can be booked at 2006 prices if you confirm by 31st December.

Is Geekmas a tradition?. It certainly feel as if it's becoming one, even though this is just its third year. It started in Novermber 2004, with us throwing open our doors for a free two-day series of Open Source talks, lectures, seminars, discussions - and coffee, food and a curry too - on the last weekend of November. Although primarily intended for course delegates who want to catch up on the latest developments, we welcome any and all technical friends, but we do ask you to let us know if you'll be attending ahead of time - there's more details here

This year, our Geekmas celebration moves from our current training centre in The Spa in Melksam to "Well House Manor" - our new business hotel which opens its doors at the end of next month, just a few hundred yards up the road towards the town centre. We'll have space for more people to attend, an additional conference room so that we can run two tracks if need be, and overnight accommodation available (that has to be charged for, I'm afraid) for people who are travelling a distance.

Posted by gje at 06:45 AM | Comments (0)


Related topics: via article database

August 24, 2006

Hotel, Melksham, Wiltshire


"When you're advertising your hotel, DON'T list out all the features such as the fact that all rooms are en-suite - people EXPECT that as standard these days" so came the recent advise from a marketing guru. He's probably right ... so I'm going to tell you today what's different about Well House Manor, and there IS plenty to tell you about.

Well House Manor is, without apology, a hotel for business travellers. Lisa and Graham Ellis, pictured either side of this text, have travelled a great deal on business, know what they need, and aim to provide it. They've also been running Well House Consultants - a business that welcomes many business visitors to Melksham each month - for a number of years, and have been listening to what their customers are looking for on top of the standard.

What's different at Well House Manor?

• All bedrooms have wired and wireless Internet access available without additional charge, and without bandwidth limits.

• A public access computer is available for use if you haven't brought your own laptop, and a monochrome laser network printer / copier is provided too.

• All bedrooms are equipped with large (26") flat screen TVs, with all freeview channels available. TVs have an SVGA adaptor fitted so that you can use the big screen on your laptop if you wish.

• As well as a hospitablity tray in each room, we provide a real coffee machine that's available for general use in the lounge, 24 hours a day. Press the button, and it grinds the beans ...

• Early breakfast is available - even at the weekend. If you need to catch the first train to London, we'll even offer you a complimentary lift to the station. We know how a full cooked breakfast is often too much for the businessman, so we've opted to provide a high quality continental breakfast instead.

• All bedrooms are provided with an empty mini-fridge and a laptop computer safe for you use during your stay.

• We ENCOURAGE our guests to eat out in Melksham in the evening, or to bring their own food in if they prefer from one of the many takeaways. A microwave over, knives and forks, plates and glasses are all provided for your use in our "Whitworth" dining room.

• Well House Manor is set in 3/4 acre of secluded grounds - it's intended to be a quiet "office away from the office" and "home from home" for our visitors. To help ensure a quiet environment we do not provide a bar, but you are very welcome to bring in your own drinks from the offlicense that's just 3 doors up the road.

• We include all the faciities we've listed in our room rate - there's no extras for this and extras for that, which means that you can pay on arrival and simply drop off your keycard when you leave.

If you like what you read and you want to stay, please email us (graham@wellho.net or lisa@wellho.net) or call us on 01225 709638. We're offering rooms at an introductory 60 pounds per night from our imminent opening through to the end of the year. On line booking will be available from January 2007.

If you would like to read more, you can "knife and fork" through details on our Well House Manor FAQ

Posted by gje at 11:37 AM | Comments (0)


Related topics: via article database

August 23, 2006

To join an organisation?

It came as a bit of a surprise to me - but a pleasant one - when I learnt that Lisa and I were the only generation of Ellises who weren't members of the National Trust. Visiting The Courts at Holt, Dad, a life (and it seems lifelong!) member showed his card and sailed through the gate and, blow me, so did Chris and Delene, too. One of those 'proud of your kids' moments - quite illogical pehaps, but never the less one of those moments. I'm really happy to say "they're with me" about both of 'em. OK - enough of these soppy moments.

Visiting Stourhead on Sunday, Lisa and I took the plunge - joined up too. There are times that I feel it's just too easy to join this and join that in a fit of enthusiasm, and to really wonder a little later just why you did so. But I think this one's going to be different.

So Lisa and I are now like the couple you see to the side of this entry (well, the picture will change each time you refresh, and we're not QUITE like some of the couples) ... and really it's long overdue. We've visited Lacock and Holt, Dyrham and now Stourhead and no doubt we'll be back there from time to time as, proudly, we show visitors the beauty of Wiltshire.

Link - pictures of Stourhead
Link - pictures of the gardens at Stourhead

Posted by gje at 12:58 AM | Comments (1)


Related topics: via article database

August 22, 2006

Dramatic Skys at Longleat

The days are getting a little cooler - thank goodness - and the cloudless hot days of summer are gone. Some heavy clouds, mellowing the colour and tones, give rise to gentle tones that, frankly, can look a little drab on the web page.

There are, though, compensations. This image here, late in the day on Sunday with the sun starting to disappear being the trees on the Longleat Estate would have been washed out in high summer, but now the threatening cloud give rise to a dramatic sky.

We took further pictures of Heaven's Gate while we were at Longleat, including the Longleat Stone Circle; on this particular visit, though, we didn't have time to make the lovely lake at Shear Water.

Posted by gje at 04:44 PM | Comments (0)


Related topics: via article database

August 21, 2006

Forum help - a push in the right direction

If I was a farmer, driving my tractor down the busy A350 one day, and I came across a chap in a car who had pulled off onto a soft verge and got stuck, what would I do? Stop and help, I hope, if I had a rope with me and I could pull him our of the mire quickly and if I wasn't in a desparate rush.

It's on the same basis that if I happen to see a post on a forum to which I'm a visitor, I'll chip in with a suggestion or answer that may be helpful. There are, I confess, times that I look at the proverbial car stuck in the mud and, wondering just what I might be getting myself into, just drive on by - shall we call it personal defence / safety, and I've see so many of these questions that I can usually recognise the ones that are likely to turn nasty on me, as if I was the one who drove them off the road in the first place. With our own Opentalk forum, each visitor who wants to post a question has to register, and most are customers. Only VERY rarely will I decline to offer suggestions there

"What's in it for you, Graham?". So ask some of the more thoughful people about my approach. Well - there's a great deal of good vibes felt from helping someone - seeing how a few minutes of work gets someone happily off on their holiday - isn't there? But there's more to it than that. If it was just the pleasure of seeing people on their way, then I might get bored and jaded and give up. There is a business reason too. Having answered a question on a forum, the posts / responses end up - at the least - on line for a few weeks, allowing others with the same questions to access the answers; a minority of those might even be interested in our other services, so I can put the whole thing down to marketing; in a relatively small community (open source developers, UK), the name of Well House Consultants is getting rather better known than it was a few years ago - and what better reputation for a training company to have than being a helpful guide to those who need a quick pointer in the right direction?

Just occasionally, this farmer does get it wrong and regret stopping to help a motorist. I stopped to help some guy from Bournemouth who had a piece of PHP that was broken, and he was off to the side of the road in the soft verge of the Semington bypass. Even at a first quick tinker with his problem, it was obvious that he didn't understand at all how to drive his PHPmobile, and having given him a couple of pointers I also suggested that he take it into a garage or to an instructor as soon as he could, so that he could complete his journey home to the south coast. But apparently, he didn't really want any sort of help that would actually cost him anything, even if he was going to put anyone who helped him to a great deal of trouble and their expense. What he really wanted was for someone to come along with a free tow truck, put him on the back and drive all the 50 miles to his home and drop him off. Oh - no "thank you" at all to me, of course - just a snide comment after my first response and nothing after some further advise which offered him some excellent directions.

I visited the forum (NOT ours) where this guy posted just a few minutes ago to see if any other farmer has stopped to help him. No - they haven't (and after the reaction I got, I'm not surprised). The guy himself has walked away from his vehicle to another road, where he's thumbing a lift asking for a free ride to Bournemouth ... "I have a job for someone to write this code for me". Indications are that he's offering (if anything) peanuts, so I suspect that all he'll get answering will be monkies. Very rarely do I get any satisfaction in seeing someone in trouble, but I'm allowing myself an exception in this case. And I'm taking a reminder from it to remember my "please" and "thank you"s and to not request unreasonable help from people myself.

Posted by gje at 08:16 AM | Comments (0)


Related topics: via article database

August 20, 2006

Computers, Brides and Cream Teas

Every so often, we have a technical purchasing "burst" and approach some unexpecting computer salesman, ask him about his products, and startle him with "we'll have three, and two printers please". Yesterday was one of those days.

Now that everything's coming together at Well House Manor, we're able to evaluate our technical system needs ... and we decided to go for a common system standard for front desk, internet access, and firewall / splash page systems. If you're a regular reader here, you'll probably learn more in the coming weeks about technical issues we've resolved as we set up a bevvy of webcams on the intranet, devices for printing and encoding swipe cards, our booking system, our sound systems (yes, they'll be on the computers too) and more.

So why the picture of the wedding car at Iford Manor? On our way home from Bath, we drove down the tiny lane past there and stopped for a cream tea ... to encounter Maid Marion getting hitched to Robin Rood, with the heavens opening on them for a short, sharp shower that dampended Maid Marion's spirits, and had Robin's Mum's high heeled shoes sinking into the turf of these lovely gardens. I know the bride and groom were looking pretty dour when they left for the reception, but I expect that if they've got the spirit to set up a wedding like that in the first place, they'll also have the spirit to look back and laugh in a few years.

We sat down in the cafe and waited for a fresh batch of scones to come out of the oven. The wedding photographer joined us, and was telling us how the wedding group had to stand huddles under umbrellas while setting up the pictures, to hide them at the last minute while he clicked a time or two. And, alas, how some of his shots so carefully pre-planned the week before had been washed out as half the party headed off early to the reception to keep dry. Still - a cheerful sole, and a lovely weekend in Wiltshire - goodness; what a beautiful part of the world to live in.

[[Both pictures - taken by Lisa]]

Posted by gje at 03:20 AM | Comments (0)


Related topics: via article database

Reporting on the 10 largest files or 10 top scores

What are the biggest 10 files in or below this directory?

What are the 20 'worst' spams I have received in the last month?

What are the five top scores recorded for a popular game on my web site?

It's a very common requirement indeed to provide a program to answer questions like these, and if you've only got a handful of files /spams / score records, it's easy to write a program to read them all into an array (PHP) or list (Perl, Python), sort that array or list when you've read them all, and print out the first however-many. But that approach becomes impractically slow and memory greedy if you have a big log file ... as for example the quarter of a million records I have in my spam record file at the moment.

Here's the technique you can use to find the top 20 records from several million in a log file - quickly, and efficiently ....

1) Set up an empty list to contain the top 20 (so far) as you discover them.

2) pass through the record one by one ...
2a) Work out the comparsion factor (size, score) for the record just read
2b) If you have already read and stored 20 records, and the new record is below the 20th one stored, reject it OTHERWISE ...
2c) Step through the records retained so far and insert the new one at the appropriate place in the list
2d) If the list now contains more that 20 records, truncate it to 20

3) Print out your results from the list you now have.

You can see this algorithm implemented in PHP here and you can run it here. It's not the simplest of code, but it should aways work no matter how large or how small the cutoff between the 20th and 21st record is (as opposed to alternative algorithms that set a threshhold), and it should always work quite fast even on a data set that's pretty huge; most of the data will be rejected summarily and won't need to be stored at all.

You might suggest that my data should be stored in a MySQL database and not a plain text file ... that's not the problem I was given, and is worthy of an entry here another day!

Posted by gje at 01:58 AM | Comments (0)


Related topics: via article database

August 19, 2006

Talking about other training companies.

I always feel very - honoured - when delegates on our training courses start talking about other training organisations (in terms ranging from positive through neutral to negative) when they're with us. Somehow there's a feeling that our "come as a student, leave as a friend" ethos is shining through, and that some of the comments would simply not be made if our students were not utterly confident with the quality of the service that we're providing.

Curiously, there are (even) times that I find myself coming to the defense of / explaining issues raised about other training providers and why they sometimes do business in a way which doesn't appear to be best suited to their clients. Very occasionally, the things I find myself explaining relate to us as well, but rather more often they're discussions of business practises that we have considered and decided against at Well House Consultants.

Posted by gje at 09:30 AM | Comments (0)


Related topics: via article database

August 18, 2006

Tomcat - Shutdown port

On a new installation of Tomcat (default config files), you'll notice that your server.xml file is set up with a shutdown port of 8005, and shutdown="SHUTDOWN". What does this mean?

It means that anyone who contacts the server locally on port 8005 and send it the words SHUTDOWN can cause Tomcat to close out all its web applications and shut down cleanly. Yikes - is this a security hole of what? It could be. Fortunatly , you'll notice that I said it's a LOCAL connection to the port that causes a shutdown, so it no-one can ssh or telnet in, nor log in from the keyboard unless they're an admin, it might not be a problem ....

If your Tomcat server allows anyone except the administrator to log in with a shell, then I strongly suggest you change shutdown="SHUTDOWN" to shutdown="waSS-I41tis" so that at least it won't be a string that any hacker can guess. You might like to change the port number too. Alas, it would be unwise to disable the facility completely, since catalina.sh and shutdown.sh use the port (details read from the config file) as part of their processing. At least server.xml is neither group nor world readable.

waSS-I41tis => "what a STUPID SYSTEM - I for one think it's silly"

Posted by gje at 07:12 PM | Comments (0)


Related topics: via article database

August 17, 2006

Build on what you already have with OO

If I start recalling a "Goons" sketch, then I'll show my age .... but never mind. It was a RERUN that I saw ;-)

Spike Milligan is counting votes at an election. "Two thousand, six hundred and forty two". "Two thousand, six hundred and forty three". "Two thousand, six hundred and forty four" ...

"Would you like a cup of tea" - a pleasant young gent walks up. "Thank you" says Spike. Sound effect - tea slurping.

"Two thousand, six hundred and .....". "Two thousand and .....". Pause. "One". "Two". "Three" ...

It's a classic, and we all laughed. And yet, when we're programming, it's so tempting to develop code from scratch - not to build on existing logic but to redevelop something that's already been redeveloped. And that's why the Object Oriented principle of inheritance is so brilliant and efficient. Taking one class defeinition, you define a new class ... not from scratch, but rather in terms of specifying only those things that are added or changed.

If Spike had jotted down the number he was at on a piece of paper, he could have carried on so easily after his cuppa. Of course, it wouldn't have been funny, but then programming isn't funny.

Posted by gje at 08:29 AM | Comments (0)


Related topics: via article database

August 16, 2006

Python - when to use the in operator

Python's in construct, when used with an if statement, lets you loop through all the members of a collection (such as a list or a tuple) and see if there's a member in the list that's equal to the pattern - thus

val = 17
if val in [1,4,5,7,12,14,17,20,34]: print "yes"

will print out "Yes". For looking for an element in a list, this is both quick coding and very efficient at run time, as the check is being done at a 'C level' - in other words, internally to Python without a constant series of reference back to the byte code. However - it IS still a loop.

Consider the following code which checks whether an integer entered by the user in between 0 and 30:

value = int(raw_input("Give me a number between 0 (inclusive) and 30 (exclusive): "))
if value in range(0,30): print "It is in range (1)"
if value < 30 and value >= 0: print "It is in range (2)"
if value in xrange(0,30): print "It is in range (3)"

All three work, and work well. BUT ... if the range we were checking was between 0 and 3 million, it would be a different story. The first test would create a list of 3 million integers internally and would then check our value against each of them - a real memory hog, and likely to break if the number was an order of magnitude higher that 3 million. The third test uses a generator function; not a memory hog, but never the less an internal loop looking at each number from 0 to 2,999,999 in turn and so really slow. The second test remains fast - just two checks to be made, no internal loop, no matter how high the top limit integer is!

Posted by gje at 07:39 AM | Comments (0)


Related topics: via article database

Useful link: Python training

August 15, 2006

Python makes University Challenge

"In computer programming terms, what does OOP signify when used in the context of languages such as Python and Java" .... I couldn't quite believe my ears when I heard Jeremy Paxman asking that question last night on University Challenge.

Posted by gje at 07:14 PM | Comments (0)


Related topics: via article database

Useful link: Python training

August 14, 2006

Old Wardour Castle

OK ... so I've been playing with Photoshop with these pictures, taken yesterday at Old Wardour Castle, right down in the bottom left corner of Wiltshire.

 
 

There are more - not so processed - pictures here

Posted by gje at 06:26 AM | Comments (0)


Related topics: via article database

Displaying data at 5 items per line on a web page

If you want to display a list of items in (say) 5 columns on a web page, use a table. A loop in PHP will let you generate all the table cells very easily, then add in a little extra code to deal with:
  a) The very first cell (you need to open table and row)
  b) Every fifth cell (you need to start a new row) and
  c) The very last cell (you need to pad out the last row and close the table).

Like an example?
  Working demonstration here
  Source code here

Posted by gje at 05:27 AM | Comments (0)


Related topics: via article database

August 13, 2006

Comparison of Object Oriented Philosophy - Python, Java, C++, Perl

There are two different philosophies that have been adopted by the authors of Object Oriented languages.

The first approach is to set the thing up in such a way that a programmer who uses someone else's code as the basis for his isn't going to be trusted to use that other person's code in a sensible manner. This is the approach taken by languages such as Java and C++, where the programmer who writes the classes / modules that are going to be re-used inserts words like "public", "private" and "protected" all over the code, and declares "virtual functions" or "abstract methods" as appropriate. This forces a user-programmer of the class / module to only make calls that are allowed by his 'supplier' - strict adherance to that person's law is necessary.

The result of this first approach is a system that's pretty cast-iron in what it provides, and it means that even the newest of newcomers to a project isn't going to break an unwritten rule (since the rules are written!!). But at what cost? It's the equivalent of having a policeman at each street corner checking up on everything everyone done ... and yet most of us don't need the incentive of having a policeman on every corner to ensure we don't exceed the speed limit!

Roll out the second approach - taken by Python and Perl. In these languages, the programmer who writes the code that makes use of a base class / package / module from elsewhere is trusted to make sensible use of that base class. It cuts out the need to "public" everything that's to be public. It cuts out the need to define abstract methods. It even cuts out the need to define classes as inheriting from a base class if all that you're looking for is a list of objects that are polymorphic ("have methods of the same name to do the same thing"). Much quicker and easier to code - much more effective - with a big IF ... and that's that it's much more effective IF you can trust your higher level user.

Do you consider yourself to be a "boy racer"? Would you go mad and mow people down as you drive along the road if it wasn't for a covert or overt police presence? Of course you wouldn't! You do things legally, don't you? Perhaps the very occasional compromise at the edges - come on, we've all done something we shouldn't at some time in our life - but basically we're law abiding citizens for the most part, going along with the law and the spirit of what's intended by the law.

And so it is with programming - the vast majority of developers who call up other people's code will abide by the rules set down, even if they're able to break the rules without the compiler stopping them. The vast majority of developers are NOT boy-racers, and any such temptation will in any case be brought to book later on when the person managing the project asks them "why the ****" if something has gone wrong, or they find themselves wasting hours sorting out the side effect of some transgression.

It turns out, then, that the Python and Perl approach of trusting the code re-user makes for much quicker and shorter coding for the original class author, and for the code re-user ... provided that both are reasonably responsible people. And that's typically gooing to be the case. Only where you have code that's going to be re-used by someone who could be considered as a bull in a china shop, or where the stakes of an error are so high as to having mere trust be unacceptable (critical banking, nuclear and defense applications) do you require the policeman-waiting-to-pounce philosophy that's imposed by C++ and Java.

Posted by gje at 06:24 AM | Comments (0)


Related topics: via article database

Useful links: Python training, Perl training, Java training

August 12, 2006

Butterflies in a Wiltshire garden

Painted Lady
Seen, sometimes in abundance in all parts of the British Isles, it is really a native of North Africa where it breeds in such extreme numbers that emigration is a necessity. Thistles are the principle foodplant, but it's often seen on other plants such as Burdock, Mallow and Nettle.


Small Tortoiseshell
Generally found in Southern and Midland counties of England. Two broods in the year - one in June, and one in August and September. Foodplant - nettle (me thinks we must have a lot of nettles around these parts!)


Comma
Up to the 1920s, the comma had a shrinking range and was more or less confined to the southern Welsh Marches. These days it's much more abundant - I remember being excited finding examples at Petts Wood in my youth, and we've plenty in our garden. We've probably got plenty of nettles around somewhere too, as that's one of its principle food plants.


Red Admiral
Seen on the wing from June through to October. Guess what it's young catapillars eat? You've got it - nettles again!


Peacock
Se in every part of the United Kingdom, though scarcer in Scotland. Foodplant ... do I even need to tell you??


All photographs taken 12th August 2006, at 404, The Spa, Melksham. We also do a good line in accommodation for visitors to the town and Open Source training courses

Posted by gje at 08:27 PM | Comments (0)


Related topics: via article database

August 11, 2006

Where to go within 30 minutes of Melksham

I often thought of writing a book "within about an hour", describing some of the places to go and see within about an hour of where I live - indeed, that's much of the inspiration for the data on our share pages system which starts you at Melksham

Truth be known - it dosen't need to be "within an hour" for most of the places I would list, as there's plenty to see and do within half an hour ... such as ...

National Trust and other grand houses and historic buildings

Great Chalfield and external link
The Courts, Holt and external link
Corsham Court and external link
Lacock Abbey and external link
Bowood and external link
Longleat and external link

Other places of interest - artefacts, relics, etc

Maud Heath's Causeway and external link
Avebury and Silbury Hill and external link
Caen Hill Locks and external link
Sandy Lane Church and external link
Castle Combe and external link
Stonehenge and external link

Local towns within 30 minutes

Chippenham
Calne
Bradford on Avon
Trowbridge
Devizes
Westbury

Major cities / larger towns within an hour

Bath
Salisbury
Swindon
Bristol
Marlborough
Malmesbury

Posted by gje at 11:51 PM | Comments (0)


Related topics: via article database

August 10, 2006

Freedom of speech and freedom to post

I'm a great one for 'freedom of speech'. In other words, I'm very happy to say that in the generality of things, people should be allowed to think whatever they like, and express those views even if they're at variance with most other people. But you'll notice that I have pulled back from giving blanket permission for everyone to write and say whatever they like.

It's with some disquiet that I hear our new Home Secretary say that some civil liberties and freedoms may need to be limited in the short term in order for us to be safe and have that freedom in the long term. He may well be very well intentioned in suggesting that freedoms will be restored, but government does have an unfortunate history of applying short term and limited measures which become extended or permanent. I recall the first speed cameras on our roads were introduced on just a few fast urban roads with a promise that "we will NOT extend to motorways" and that Income Tax was introduced as a temporary measure only to fund the Napolionic Wars in the early 1800s.

With such a disquiet being in my nature, why am I not advocating total freedom of speech? Well - I've just spent a couple of hours removing explicit sexual images from all the boards on our forums, and filtering out the same images from personal messages left for our members. I don't consider such material to be appropiate to a forum concerning Open Source programming, nor to one concerning the train services in Wiltshire; if people want such material, they can sign up for it elsewhere.

And, quite exceptionally, I have banned the member concerned. The posts and messages are very very clearly in breach of the user agreement, and the multiple posting contravenes another part of the agreement. In such quantity, "oops - posted to the wrong forum" isn't a valid excuse. Any yet ... I've still asked him to email me if he feels that there was good reason for his actions so that I can fairly listen. I don't actually expect to hear from him, mind you!

Posted by gje at 05:51 AM | Comments (0)


Related topics: via article database

No news is good news with Unix and Linux

No news is good news ... so says Linux and Unix. All processes return a status code, and you can expect that to be:
0 - success
1 - failure
2 - abject failure

So, for example, the grep utility returns a status as follows:
0 - found what you were looking for!
1 - nothing found
2 - sorry - couldn't even read the input file

Posted by gje at 05:47 AM | Comments (0)


Related topics: via article database

Useful link: Linux training

August 09, 2006

Fighting illegal net use by imposing download limits

I was away in Cambridge last night ... and St Neots tonight. On line via a hotel's wireless connection, and limited to 150 Mbytes of traffic for my session. I've always felt that these hotel limits are agressively low - if I need to grab (say) a fresh download of J2EE, I'll have used up most of my allocation in a single operation.

Why have such a tight limit? Could it be because there's a big hotel on a single broadband link and they want to share fairly? Could it be because they want you to buy another package, and another and another if you use up the resource? No - I had a look at the FAQ last night, and it tells me that they impose the limit to actively discourage the illegal sharing of music via peer to peer systems, and the downloading of illicit film clips.

Posted by gje at 06:37 AM | Comments (0)


Related topics: via article database

August 07, 2006

Pictures of the Vale of Pewsey

Alton Barnes White Horse from the Canal The Alton Barnes White Horse is cut into the hillside above the Vale of Pewsey, where the main railway and the Kennet and Avon Canal share the valley up to Savernake - a remote spot where they pass over the watershed into the valley of a tributary of the River Thames.

Although we live only 10 miles from the Vale, it's not an area that we pass through very often; the roads are twisty and narrow (even if it is at the heart of other modes of transport), but yesterday we took a break, visited the Vale, and took a few pictures for our pictobook of Wiltshire.

More pictures ...

The Vale of Pewsey
Honey Street
Wootton Rivers
Savernake
Crofton
Wilton Windmill
Ludgershall and Tidworth

Posted by gje at 06:29 AM | Comments (0)


Related topics: via article database

August 06, 2006

Pictures of Avebury, Longleat and Dyrham

Avebury

It's summer in Wiltshire, and in spite of being rushed off our feet with training (open source stuff), training (trying to save the local train service), and refurbishing a B&B into a hotel, we've both had a few chances to get out and take some pictures. This morning, I've spend a few minutes going through some of those pictures and adding them into our web site - there's getting to be quite an array of places covered (clickable map) although we've still got a few holes.

The picture above was taken at Avebury ... Other pictures just added include mine of Longleat and Lisa's of Dyrham

Posted by gje at 08:37 AM | Comments (0)


Related topics: via article database

August 05, 2006

An excellent use for a visitor count?

Visitor counters are oversold. Very much oversold. I don't give a *&^%$ when I go down to my local supermarket whether I'm visitor number 27 or visitor 2765, so why should I want to know on a web site?

Well - you may not be interested in how many visitors I've had to my "Save the train" website that's trying to raise the profile of the Swindon to Southampton train service that's being scrapped in December, but I tell you ... I AM interested in getting visitors to read about it. And I'm keeping tabs of the number of different remote hosts who've accessed us .... I've got a target of ten thousand for the first year which ends in 10 days time. I'm within a few hundred but it's going to be close.

I would much appreciate you clicking through - I'll give you the link again - it's
http://www.savethetrain.org.uk

If we succeed, then come down to Melksham by train after the 9th of December, let me know, and I'll come down to the station here with a steaming cup of coffee. Black or white? one lump or two??

Thanks!

Graham

Posted by gje at 12:48 PM | Comments (0)


Related topics: via article database

August 04, 2006

PHP - a team member leaves

I read that Jani Taskinen, one of (quite a number) of lead developers on the PHP project, has quit after six years. Much PHP development takes place in Israel, and Jani - who has been a UN peacekeeper and who has friends in the Middle East conflicts, concluded that he could not continue to work with a project with close Israeli connections.

Very sad. I respect his decision and wish him well for the future. But I don't see it having a great effect on PHP's future; gaps will be filled, and the language will go on strong. And most of us users are working very well and happily with the current releases, which are excellent; the need for new bells and whistles and development is a medium to long term one and rarely will a couple of months delay / hiccough be dramatic. No doubt the changes will have a big impact on Jani's life. "Not a great career move" said a commenter elsewhere and that's probably so, but he should be happy in who he works with and what he does, and the move may well bring a new career and a new happiness for him. I certainly hope so.

More discussion

Posted by gje at 06:47 AM | Comments (0)


Related topics: via article database

Useful link: PHP training

August 03, 2006

Dynamic functions and names - Python

In Python, everything is held as an object in a variable - and I do mean everything, even named pieces of code. So that means that you can do some amazing things (or things that would be amazing in other languages) such as set up a named piece of code to perform action "x", the replace it dynamically with a piece of code to perform action "y" or action "z".

# conditional functions

def about():
   return "initial"

try:
   value = int(raw_input("Please enter a number: "))
   if value % 2:
      def about():
         return "that's odd"
   else:
      def about():
         return "that's even"
except StandardError:
   pass

print about()

This piece of code sets up a function called "about" to a default value, then replaces it with two alternative pieces of code if the user enters an odd or even number, leaving it alone if the user doesn't make a valid entry .... so that when the about() function is called, it runs in in one of three different ways ...

earth-wind-and-fire:~/aug06 grahamellis$ python confun
Please enter a number: 5
that's odd
earth-wind-and-fire:~/aug06 grahamellis$ python confun
Please enter a number: 4
that's even
earth-wind-and-fire:~/aug06 grahamellis$ python confun
Please enter a number: ksjksdjkfsdf
initial
earth-wind-and-fire:~/aug06 grahamellis$

Posted by gje at 06:02 AM | Comments (0)


Related topics: via article database

Useful link: Python training

August 01, 2006

Robert and William Whitworth

Robert Whitworth first surveyed the line for a canal through the Vale of the White Horse in 1784, as part of a plan by the Thames and Severn Canal Company to bypass the upper Thames, which they saw as an impediment to their trade. Further surveys followed, with a great deal of activity from 1793 to 1795 when the Wilts and Berks Canal Act was passed, for a canal from Abington on the Thames to Semington on the Kennet and Avon Canal just to the South of Melksham. Both Robert Whitworth and his son William were heavily involved in the planning of this canal, with William standing in for his father at important meetings that decided the line of the canal.

Compulsory purchase of land and construction started as soon as the act was passed, with Robert Whitworh as the chief engineer; when he passed away in 1799, his son William took over most of his father's role; starting from the Semington end of the canal, the Thames was eventually reached on 10th September 1810. William's last know report to the committee was dated April 1811, listing a few remaining works to be done at an estimated cost of 10 thousand pounds.

The Wilts and Berks Canal passed less that 100 yards from Well House Manor, and we've named our two main training rooms "The Wilts" and "The Berks" in honour of this local piece of history. We're naming our dining room "The Whitworth" in honour of Robert and William, who surveyed and managed the building of this great undertaking and brought waterborne carriage of goods to Melksham Wharf in 1798.

See also:
Well House Manor - initial FAQ

Wilts and Berks History
Robert and William Whitworth, engineers
The Wilts and Berks in Melksham
The reservoir at Coate Water
The canal at Calne

Posted by gje at 09:00 PM | Comments (0)


Related topics: via article database