Skip Menu |

This queue is for tickets about the TAP-Formatter-HTML CPAN distribution.

Report information
The Basics
Id: 37983
Status: resolved
Priority: 0/
Queue: TAP-Formatter-HTML

People
Owner: steve [...] purkis.ca
Requestors: cdavaz [...] gmail.com
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: (no value)
Fixed in: (no value)



Subject: CSS and JS Paths on Win32 get mangled
File-schemed CSS and JS paths get mangled on Win32. If we have file://C:\some\path we will get file://C:%5Dsome%5Dpath which doesn't work (the CSS or JS file won't get loaded by the browser). I made a fix in the attached file. However this fix only works if I manually specify the URIs using $formatter->css_uris(['C:\some\path']); or the equivalent js_uris call.
Subject: HTML.pm

Message body is not shown because it is too large.

On Mon Jul 28 06:13:08 2008, DAVAZ wrote: Show quoted text
> File-schemed CSS and JS paths get mangled on Win32.
[snip!] Eep, that's not good. What version did you patch - 0.04? And which flavour/version of Perl are you using? Active Perl? Cheers, -Steve
On Mon Jul 28 06:13:08 2008, DAVAZ wrote: Show quoted text
> File-schemed CSS and JS paths get mangled on Win32. If we have > > file://C:\some\path
I think this may be a case of invalid file URI's being passed into TFH - see http://blogs.msdn.com/ie/archive/2006/12/06/file-uris-in-windows.aspx According to this, you should be using the following: file:///C:/some/path Can you try that & see if that works?
From: brendanshoe
I'll jump in, as I've also been experiencing this in 0.06 on Windows using ActivePerl. I've only been using the default CSS and JS files, so I haven't tried changing the input. The error I've been receiving, which I suspect is related to this is: Warning: couldn't read C:%5CPerl%5Csite%5Clib%5CTAP%5CFormatter%5CHTML%5Cdefault_page.css: file does not exist! Warning: couldn't read C:%5CPerl%5Csite%5Clib%5CTAP%5CFormatter%5CHTML%5Cdefault_report.css: file does not exist! This occurs in slurp_css, as it doesn't seem to think uri->path points to a valid file. If uri->file is used instead, it works properly for me. From some quick testing of URIs through Explorer: C:%5CPerl%5Csite%5Clib%5CTAP%5CFormatter%5CHTML%5C is interpreted as file:///C:%255CPerl%255Csite%2555Clib%255CTAP%255CFormatter%255CHTML%255 C for some reason, and is not found. file://C:%5CPerl%5Csite%5Clib%5CTAP%5CFormatter%5CHTML%5C is not found file:///C:%5CPerl%5Csite%5Clib%5CTAP%5CFormatter%5CHTML%5C, as indicated by the linked article, does work. Let me know if you need me to try anything else out. On Mon Feb 02 17:08:56 2009, SPURKIS wrote: Show quoted text
> On Mon Jul 28 06:13:08 2008, DAVAZ wrote:
> > File-schemed CSS and JS paths get mangled on Win32. If we have > > > > file://C:\some\path
> > I think this may be a case of invalid file URI's being passed into TFH > - see > http://blogs.msdn.com/ie/archive/2006/12/06/file-uris-in-windows.aspx > > According to this, you should be using the following: > > file:///C:/some/path > > Can you try that & see if that works? >
This feature will be in 0.08, which is on it's way to CPAN.