Coffeehouse Thread

23 posts

Forum Read Only

This forum has been made read only by the site admins. No new threads or comments can be added.

The code that's caused the lastest scandal at the BBC

Back to Forum: Coffeehouse
  • User profile image
    GoddersUK

    Some of the UK niners may have heard of the latest embarrassing scandal that threatens to bring down our great national broadcaster. All caused by some programming on the BBC website; here's a snippet of the offending code, courtesy the BBC web developer's blog:

    drawDisplay: function(pos){
        this.context.clearRect(0,0,49,49); // clear canvas
        this.context.save(); // save state before translation
        this.context.translate(24.5, 24.5); // move 0,0 to center
        this.context.strokeStyle = "#fff";
        for (var i = 0; i<12 ; i++){ // draw numerals
            var lineWidth = 1.2+(i*0.1), rotation = 30*(i+1),
                startX1 = -0.5 - lineWidth/2,
                startX2 = 0.5 + lineWidth/2,
                startY = -26, endY = -18;
            this.drawLine(lineWidth, rotation, startX1, startY, startX1, endY);
            this.drawLine(lineWidth, rotation, startX2, startY, startX2, endY);
        }
        this.drawCircle(2, 0, 0, 5, 0, Math.PI*2, true); // draw centre circle
        this.drawLine(3, pos.hrsPos, 0, -6, 0, -17); // draw hour hand
        this.drawLine(2, pos.minPos, 0, -6, 0, -24); //draw minute hand
        this.drawLine(1, pos.secPos, 0, -6, 0, -26); //draw second hand
        this.drawLine(1, pos.secPos, 0, 5, 0, 10);    
        this.context.restore(); // go back to the state before translation
        this.drawnPos = pos;
    }

    Yes folks, this is the breaking news that the clock on the BBC website in fact simply displays the visitor's computer's local time. Thankfully a courageous member of the British public has taken on an editorial sin so heinous that the BBC Trust's editorial standards committee was forced to step in and take action! I can now sleep safely in my bed at night, thank goodness!

  • User profile image
    Ian2

    Who clocked that?

  • User profile image
    SimonJ

    And the solution is...

    ... to remove the clock from the page.

  • User profile image
    Bas

    Wow. Wow.

  • User profile image
    Harlequin

    This makes sense to me. The BBC website should have a service that reads the time from an accurate clock source, detect the locale of the user, recalculate, and show that to the user.

  • User profile image
    ScanIAm

    This is an outrage.

     

    Seriously, though, what would keep them from reading time from a time service and then updating it periodically.  I can guarantee that there are more annoying and time consuming things going on in the page, now. 

  • User profile image
    kettch

    @Harlequin: Agreed. A clock based on the local machine's time is so 1990's Geocities. Why in the world is it going to take 100 days?

  • User profile image
    magicalclick

    Tell me how you can collect user location reliably without user messing it up. System locale, GPS, IP behind proxy are all unreliable because they are all user data one way or another. And these data are often out of control of actual user, which blocks him form correcting the time himself.

    Leaving WM on 5/2018 if no apps, no dedicated billboards where I drive, no Store name.
    Last modified
  • User profile image
    Dr Herbie

    @Harlequin: Screw that, this is Britain!  The clock should show the time in London and anyone outside of the UK will have to make do.  Devil

    Herbie

  • User profile image
    Ian2

    @Dr Herbie:Of course, BRITISH Broadcasting. GMT - and that should be touted as a feature, not a dumbing down!  C'mon!!

  • User profile image
    cbae

    , Dr Herbie wrote

    @Harlequin: Screw that, this is Britain!  The clock should show the time in London and anyone outside of the UK will have to make do.  Devil

    Herbie

    Don't you mean the time at the Royal Observatory, Greenwich? Devil

  • User profile image
    Ian2

    @cbae: Absolutely, who among us has not stood with one foot either side of that line?

  • User profile image
    davewill

    , Dr Herbie wrote

    @Harlequin: Screw that, this is Britain!  The clock should show the time in London and anyone outside of the UK will have to make do.  Devil

    Herbie

    Now that's the spirit. Go Herbie. This BBC clock fiasco makes it sound like everyone is a puppet for the queen.

  • User profile image
    vesuvius

    @GoddersUK: To be honest, it pleases me to see some rushed code rather than the 100 million abandoned project which clearly lacked an Agile methodology, and stuck to the "This is the BBC!" attitude, resulting in the technology they were developing, becoming outdated because of the bureaucracy and red tape they are famous for. It is good for making Films, but in the technology world you have to be Agile as well.

    All they need to do now is fix the problem, the key thing is the website got launched on time, and it has taken years for anyone to notice, especially since it is frequented by millions of users daily, including computer types like you and Niners here.

  • User profile image
    ScanIAm

    , vesuvius wrote

    All they need to do now is fix the problem, the key thing is the website got launched on time, and it has taken years for anyone to notice,

    I'm still not entirely clear on what the fuss about.  Was it the fact that some website widget doesn't have atomic clock accuracy?

  • User profile image
    vesuvius

    , ScanIAm wrote

    *snip*

    I'm still not entirely clear on what the fuss about.  Was it the fact that some website widget doesn't have atomic clock accuracy?

    I'm not sure either, can anyone else figure out what the fuss is about?

  • User profile image
    MasterPi

    , vesuvius wrote

    *snip*

    I'm not sure either, can anyone else figure out what the fuss is about?

    Phew...I thought I was the only one out of the loop. I thought the issue was that they're making a big deal out of 90s clock widget...

  • User profile image
    cbae

    I'm not exactly sure what the brouhaha is all about either, but whatever it is, it's likely to bring the BBC down to the level of Fox News in terms of journalistic integrity. I just feel it.

     

    Generic Forum Image

Conversation locked

This conversation has been locked by the site admins. No new comments can be made.