Skip Menu |
 

This queue is for tickets about the CPAN-Mini-Webserver CPAN distribution.

Report information
The Basics
Id: 65532
Status: open
Priority: 0/
Queue: CPAN-Mini-Webserver

People
Owner: Nobody in particular
Requestors: MELEZHIK [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.51
Fixed in: (no value)



Subject: 1) want to setup cash ttl parameter as env var or command line option 2) utf8 bug for pod documentation 3) no pod doc handler
MIME-Version: 1.0
X-Mailer: MIME-tools 5.427 (Entity 5.427)
X-RT-Original-Encoding: utf-8
Content-Type: multipart/mixed; boundary="----------=_1297090433-9726-531"
Content-Length: 0
Content-Type: text/plain; charset="UTF-8"
Content-Disposition: inline
Content-Transfer-Encoding: binary
Content-Length: 268
Download (untitled) / with headers
text/plain 268b
I'd like to report about these 3 issues: 1) necessity for setting up "cash ttl parameter" as env var or command line option 2) for some encodings pod document is not shown correctly 3) workaround in case module has not pod documentation Sample patch is attached
Subject: patch1.txt
MIME-Version: 1.0
Content-Type: text/plain; charset="utf-8"; name="patch1.txt"
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline; filename="patch1.txt"
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: ascii
Content-Length: 1281
Download patch1.txt
text/plain 1.2k
--- /usr/local/lib/perl5/site_perl/5.8.9/CPAN/Mini/Webserver.pm 2011-01-30 18:57:54.000000000 +0300 +++ /home/melezhik/sandbox/utils/cpan/patches/Webserver.pm 2011-02-07 17:47:21.000000000 +0300 @@ -115,7 +115,7 @@ && ( -f $authors_filename ) && ( -f $packages_filename ); - my %cache_opts = ( ttl => 60 * 60 ); + my %cache_opts = ( ttl => $ENV{CASH_TTL} * $ENV{CASH_TTL} ); $cache_opts{directory} = $cache_dir if $cache_dir; my $cache = App::Cache->new( \%cache_opts ); @@ -455,7 +455,7 @@ $parser->no_whining( 1 ); $parser->no_errata_section( 1 ); $parser->output_string( \my $html ); - $parser->parse_string_document( $contents ); + $parser->parse_string_document("=encoding utf-8\n\n=cut\n\n".$contents); $html =~ s/^.*<!-- start doc -->//s; $html =~ s/<!-- end doc -->.*$//s; @@ -468,8 +468,8 @@ pauseid => $pauseid, distvname => $distvname, filename => $filename, - contents => $contents, - html => $html, + contents => $parser->content_seen ? $contents : 'no pod documentation found', + html => $parser->content_seen ? $html : 'no pod documentation found', } ); }
MIME-Version: 1.0
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-19311-1297091757-1164.65532-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 536
Download (untitled) / with headers
text/plain 536b
Hi Alexey, thanks for the feedback and suggestions. As for the cache timeout, sure, i'll implement that via a config file option or command line option. Not too sure how i'll do that yet, but i don't see ENV-mangling as the best way to go about it. I'll have to review how current configuration is handled. As for the POD not displaying right, can you please tell me which cpan modules at which versions exhibit problems so i can write proper tests for the fixes? (And actually make sure that the proposed patch fixes them. ;) )
MIME-Version: 1.0
In-Reply-To: <rt-3.8.HEAD-19311-1297091757-1164.65532-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <rt-3.8.HEAD-19311-1297091757-1164.65532-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-19313-1297155588-103.65532-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 724
Download (untitled) / with headers
text/plain 724b
Пнд Фев 07 10:15:57 2011, MITHALDU писал: Show quoted text
> Hi Alexey, thanks for the feedback and suggestions. > > As for the cache timeout, sure, i'll implement that via a config file > option or command line option. Not too sure how i'll do that yet, but
i Show quoted text
> don't see ENV-mangling as the best way to go about it. I'll have to > review how current configuration is handled. >
Yeah, ofcourse ENV-mangling was proposed as simple but not best solution, config-way is ok ((: Show quoted text
> As for the POD not displaying right, can you please tell me which
cpan Show quoted text
> modules at which versions exhibit problems so i can write proper
tests for the fixes? (And actually make sure that the proposed patch fixes them. ;) ) comming soon
MIME-Version: 1.0
In-Reply-To: <rt-3.8.HEAD-19311-1297091757-1164.65532-0-0 [...] rt.cpan.org>
X-Mailer: MIME-tools 5.427 (Entity 5.427)
Content-Disposition: inline
References: <rt-3.8.HEAD-19311-1297091757-1164.65532-0-0 [...] rt.cpan.org>
Content-Type: text/plain; charset="UTF-8"
Message-ID: <rt-3.8.HEAD-7681-1297332231-446.65532-0-0 [...] rt.cpan.org>
Content-Transfer-Encoding: binary
X-RT-Original-Encoding: utf-8
Content-Length: 411
Download (untitled) / with headers
text/plain 411b
Show quoted text
> As for the POD not displaying right, can you please tell me which
cpan Show quoted text
> modules at which versions exhibit problems so i can write proper
tests Show quoted text
> for the fixes? (And actually make sure that the proposed patch fixes > them. ;) )
you can test against this test module, wrote by me, it contains utf pod documentation (russian language) - http://search.cpan.org/~melezhik/ AMZ_TEST-v0.0.3/lib/AMZ/Test.pm


This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.