Skip Menu |
 

This queue is for tickets about the CGI-Session CPAN distribution.

Report information
The Basics
Id: 21981
Status: resolved
Priority: 0/
Queue: CGI-Session

People
Owner: RSAVAGE [...] cpan.org
Requestors: erwan [...] mas.nom.fr
Cc:
AdminCc:

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



Subject: Bug with utf8
Date: Tue, 10 Oct 2006 01:11:48 +0200
To: bug-CGI-Session [...] rt.cpan.org
From: Erwan MAS <erwan [...] mas.nom.fr>
Download (untitled) / with headers
text/plain 490b
Hello , The program in attachement does not work . But when i remove the line "use encoding 'utf8';" the program work . Perhaps I had missed some thing. -- Show quoted text
____________________________________________________________ / Erwan MAS /\ | mailto:erwan@mas.nom.fr |_/ ___|________________________________________________________ | \___________________________________________________________\__/

Message body is not shown because sender requested not to inline it.

Subject: Re: [rt.cpan.org #21981] AutoReply: Bug with utf8
Date: Tue, 10 Oct 2006 01:16:16 +0200
To: bug-CGI-Session [...] rt.cpan.org
From: Erwan MAS <erwan [...] mas.nom.fr>
Download (untitled) / with headers
text/plain 1.8k
I paste de programm in the mail . --------------------------------------------------------------- #!/usr/bin/perl #---------------------------------------------------------------------------------------------- use encoding 'utf8'; #---------------------------------------------------------------------------------------------- use CGI::Session; #---------------------------------------------------------------------------------------------- sub create_ses { my $session = new CGI::Session("driver:File", undef, {Directory=>'/tmp'}); $session->param(-name=>'user', -value=>"coucou"); $session->param(-name=>'passwd', -value=>"cpan"); $session->expire('+30m'); my $sid=$session->id(); $session->close() ; return $sid ; } #---------------------------------------------------------------------------------------------- sub reopen_ses { my $sid=shift ; my $session = new CGI::Session("driver:File", $sid , {Directory=>'/tmp'}); # if ( $session ) { return 'OK' ; $session->close() ; } else { printf STDERR "can not create a new session '%s'",CGI::Session->errstr() ; } return undef ; } #---------------------------------------------------------------------------------------------- my $t=&create_ses() ; if ( $t ) { my $tt=&reopen_ses($t) ; if ( $tt ) { print STDERR "test is ok\n" ; } } #---------------------------------------------------------------------------------------------- --------------------------------------------------------------- -- Show quoted text
____________________________________________________________ / Erwan MAS /\ | mailto:erwan@mas.nom.fr |_/ ___|________________________________________________________ | \___________________________________________________________\__/
Subject: Re: [rt.cpan.org #21981] Bug with utf8
Date: Fri, 20 Oct 2006 19:03:08 -0500
To: bug-CGI-Session [...] rt.cpan.org
From: Mark Stosberg <mark [...] summersault.com>
Download (untitled) / with headers
text/plain 949b
Erwan MAS via RT wrote: Show quoted text
> > Hello , > > The program in attachement does not work . > But when i remove the line "use encoding 'utf8';" the program work . > > Perhaps I had missed some thing.
Erwan, I'm interested to see if we can resolve this, because I want to make sure that CGI::Session works with UTF. However, it's not something I need in my own work, it looks like you do. Would you be willing to help? First, see if you can keep reducing your test script further to see if you can isolate the problem, ideally as a "Test::More" style test script we could add to the test suite. If you do isolate the problem, perhaps you could take the next step and see if could also fix the bug in the source code. If you get stuck at any point, ask for help in the CGI::Session users mailing list. In any case, I'll thank you for the bug report. Someone will look into it further eventually if you don't. Mark -- http://mark.stosberg.com/
I'm giving this ticket to Ron Savage who has started to look into this. Mark On Sun Oct 22 16:14:58 2006, mark@summersault.com wrote: Show quoted text
> Erwan MAS via RT wrote:
> > > > Hello , > > > > The program in attachement does not work . > > But when i remove the line "use encoding 'utf8';" the program work . > > > > Perhaps I had missed some thing.
> > Erwan, > > I'm interested to see if we can resolve this, because I want to make > sure that CGI::Session works with UTF. However, it's not something I > need in my own work, it looks like you do. Would you be willing to help? > > First, see if you can keep reducing your test script further to see if > you can isolate the problem, ideally as a "Test::More" style test script > we could add to the test suite. > > If you do isolate the problem, perhaps you could take the next step and > see if could also fix the bug in the source code. > > If you get stuck at any point, ask for help in the CGI::Session users > mailing list. > > In any case, I'll thank you for the bug report. Someone will look into > it further eventually if you don't. > > Mark >
Download (untitled) / with headers
text/plain 754b
I see there's a fix for this in SVN and some passing tests. Would it be too much hassle to make this warning the test emits go away? Some users could take it to indicate a problem. I looked at distributing Test::Warn for this purpose, but it requires a string of dependencies itself. Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval 19) line 1. Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval 19) line 1. (in cleanup) Can't locate object method "renewed" via package "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) line 1. (in cleanup) Can't locate object method "renewed" via package "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) line 1.
Subject: Re: [rt.cpan.org #21981] Bug with utf8
Date: Sun, 16 Mar 2008 16:33:07 +1100
To: bug-CGI-Session [...] rt.cpan.org
From: Ron Savage <ron [...] savage.net.au>
Download (untitled) / with headers
text/plain 2.1k
Hi Mark On Sat, 2008-03-15 at 22:52 -0400, MARKSTOS via RT wrote: Show quoted text
> Queue: CGI-Session > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=21981 > > > I see there's a fix for this in SVN and some passing tests. Would it be > too much hassle to make this warning the test emits go away? Some users > could take it to indicate a problem. > > I looked at distributing Test::Warn for this purpose, but it requires a > string of dependencies itself. > > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > 19) line 1. > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > 19) line 1. > (in cleanup) Can't locate object method "renewed" via package > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) > line 1. > (in cleanup) Can't locate object method "renewed" via package > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) > line 1.
My first thought was to patch the text associated with the test to add: Warnings expected. Consult docs re 'utf8' I'll do that now in SVN. Also, let me copy here for the record the rationale I posted to the mailing list for these warnings: <==8><==> The new test program I've written passes all tests, but still emits a deliberate warning message. Here's my thinking: o Tests and installation should not fail in all those cases people are not using utf8 o References to utf8 are on RT, the docs (with my patch), and this email list's archive, to help people diagnose problems o My new test program passes all tests so automated testing and installation can continue, assuming all other problems are fixed, of course o The new test emits a warning so anyone watching the tests' progress will see a reference to utf8 being problematic o Clearly I do not have a solution to this problem, but I have no intention of diving into the innards of utf8-related code, so I see the new test as simply giving people more warning about utf8 problems than they've had up to now <==8><==> Sure, users can be confused, but to me that's better than having their programs behave mysteriously over a known problem. -- Ron Savage ron@savage.net.au http://savage.net.au/index.html
Download (untitled) / with headers
text/plain 2.8k
Hi, I had also this problem, but when using Storable as serializer and MySQL for storage. I changed the serializer to yaml and the problem was solved. I know this is just a workaround... If this is of any help: My dsn: DBI:mysql:database=blabala;host=localhost;mysql_enable_utf8=1 note the 'mysql_enable_utf8=1' and I use also DBIx::Simple::UTF8Columns which automatically encodes the data sent to the database. But Storable files/data are binary and are not supposed to be utf8 upgraded. Since YAML dumps are just text there is no problem. On Sun Mar 16 01:30:18 2008, ron@savage.net.au wrote: Show quoted text
> Hi Mark > > On Sat, 2008-03-15 at 22:52 -0400, MARKSTOS via RT wrote:
> > Queue: CGI-Session > > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=21981 > > > > > I see there's a fix for this in SVN and some passing tests. Would it be > > too much hassle to make this warning the test emits go away? Some users > > could take it to indicate a problem. > > > > I looked at distributing Test::Warn for this purpose, but it requires a > > string of dependencies itself. > > > > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > > 19) line 1. > > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > > 19) line 1. > > (in cleanup) Can't locate object method "renewed" via package > > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) > > line 1. > > (in cleanup) Can't locate object method "renewed" via package > > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at (eval 19) > > line 1.
> > My first thought was to patch the text associated with the test to add: > > Warnings expected. Consult docs re 'utf8' > > I'll do that now in SVN. > > Also, let me copy here for the record the rationale I posted to the > mailing list for these warnings: > > <==8><==> > The new test program I've written passes all tests, but still emits a > deliberate warning message. Here's my thinking: > > o Tests and installation should not fail in all those cases people are > not using utf8 > > o References to utf8 are on RT, the docs (with my patch), and this email > list's archive, to help people diagnose problems > > o My new test program passes all tests so automated testing and > installation can continue, assuming all other problems are fixed, of > course > > o The new test emits a warning so anyone watching the tests' progress > will see a reference to utf8 being problematic > > o Clearly I do not have a solution to this problem, but I have no > intention of diving into the innards of utf8-related code, so I see the > new test as simply giving people more warning about utf8 problems than > they've had up to now > <==8><==> > > Sure, users can be confused, but to me that's better than having their > programs behave mysteriously over a known problem. >
Download (untitled) / with headers
text/plain 3.1k
BEROV, I'm not sure I understand: Are suggesting there's still a further change that we should be making in CGI::Session? Mark On Sat Apr 05 13:51:22 2008, BEROV wrote: Show quoted text
> Hi, I had also this problem, but when using Storable as serializer and > MySQL for storage. > I changed the serializer to yaml and the problem was solved. > I know this is just a workaround... > > If this is of any help: > My dsn: > DBI:mysql:database=blabala;host=localhost;mysql_enable_utf8=1 > > note the 'mysql_enable_utf8=1' > > and I use also DBIx::Simple::UTF8Columns which automatically encodes the > data sent to the database. > > But Storable files/data are binary and are not supposed to be utf8
upgraded. Show quoted text
> > Since YAML dumps are just text there is no problem. > > > On Sun Mar 16 01:30:18 2008, ron@savage.net.au wrote:
> > Hi Mark > > > > On Sat, 2008-03-15 at 22:52 -0400, MARKSTOS via RT wrote:
> > > Queue: CGI-Session > > > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=21981 > > > > > > > I see there's a fix for this in SVN and some passing tests. Would
it be Show quoted text
> > > too much hassle to make this warning the test emits go away? Some
users Show quoted text
> > > could take it to indicate a problem. > > > > > > I looked at distributing Test::Warn for this purpose, but it
requires a Show quoted text
> > > string of dependencies itself. > > > > > > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > > > 19) line 1. > > > Can't locate package Encode::Encoding for @Encode::utf8::ISA at (eval > > > 19) line 1. > > > (in cleanup) Can't locate object method "renewed" via package > > > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at
(eval 19) Show quoted text
> > > line 1. > > > (in cleanup) Can't locate object method "renewed" via package > > > "Encode::utf8" (perhaps you forgot to load "Encode::utf8"?) at
(eval 19) Show quoted text
> > > line 1.
> > > > My first thought was to patch the text associated with the test to add: > > > > Warnings expected. Consult docs re 'utf8' > > > > I'll do that now in SVN. > > > > Also, let me copy here for the record the rationale I posted to the > > mailing list for these warnings: > > > > <==8><==> > > The new test program I've written passes all tests, but still emits a > > deliberate warning message. Here's my thinking: > > > > o Tests and installation should not fail in all those cases people are > > not using utf8 > > > > o References to utf8 are on RT, the docs (with my patch), and this email > > list's archive, to help people diagnose problems > > > > o My new test program passes all tests so automated testing and > > installation can continue, assuming all other problems are fixed, of > > course > > > > o The new test emits a warning so anyone watching the tests' progress > > will see a reference to utf8 being problematic > > > > o Clearly I do not have a solution to this problem, but I have no > > intention of diving into the innards of utf8-related code, so I see the > > new test as simply giving people more warning about utf8 problems than > > they've had up to now > > <==8><==> > > > > Sure, users can be confused, but to me that's better than having their > > programs behave mysteriously over a known problem. > >
> >
Download (untitled) / with headers
text/plain 112b
Because there is have been no response from the requestor in the last 5 months, I'm considering this resolved.


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.