[ensembl-dev] Atlas tracks - fail to add on Gramene genome browser, method not allowed

Wei, Xuehong weix at cshl.edu
Mon Mar 23 17:37:42 GMT 2015


Hi, Ensembl Developers,

On Gramene genome browser which is build on top of ensemble web infrastructure, users cannot succeed in adding Atlas tracks by url. In the error log, we see error messages like

"Uncaught exception 'URLException' with message 'Could not get headers.'\n  Thrown by EnsEMBL::Web::File::Utils::URL::get_headers in module EnsEMBL::Web::File::Utils::URL at /usr/local/ensembl-live/ensembl-webcode/modules/EnsEMBL/Web/File/Utils/URL.pm on line 302…”

I further trace the source of the error to the following code in function get_header

    my $http = HTTP::Tiny->new(%params);
    my $response = $http->request('HEAD', $url); ####FAILED

I wrote a test script to test this $http->request and found while ‘HEAD’ returned error, ‘GET’ would succeed (See below). Obviously ensemble genome browser has no problem using ‘HEAD’. So I am wondering whether this is a permission setting on wwwdev.ebi.ac.uk<http://wwwdev.ebi.ac.uk> that restricts the methods from outside request to ‘GET’. If it is, could you grant outside request ‘HEAD’ method too?

Thanks,


#!/bin/env perl

use HTTP::Tiny;
use Data::Dumper;

my $url='http://wwwdev.ebi.ac.uk/gxa/experiments/E-ATMX-20/tracks/E-ATMX-20.g1_g2.genes.log2foldchange.bedGraph';


my $http = HTTP::Tiny->new;

my $response = $http->request('HEAD', $url);

warn (Dumper($response));


perl test.pl

$VAR1 = {
          'success' => '',
          'protocol' => 'HTTP/1.1',
          'headers' => {
                         'content-type' => 'text/html;charset=UTF-8',
                         'set-cookie' => 'JSESSIONID=C3301F4233490280BC8F2658EF225186; Path=/gxa/; HttpOnly',
                         'transfer-encoding' => 'chunked',
                         'date' => 'Sun, 22 Mar 2015 19:13:36 GMT',
                         'vary' => 'Accept-Encoding',
                         'allow' => 'GET',
                         'server' => 'Apache-Coyote/1.1'
                       },
          'status' => '405',
          'url' => 'http://wwwdev.ebi.ac.uk/gxa/experiments/E-ATMX-20/tracks/E-ATMX-20.g1_g2.genes.log2foldchange.bedGraph',
          'reason' => 'Method Not Allowed'
        };

Sharon






More information about the Dev mailing list