Skip Menu |

This queue is for tickets about the DBIx-Class-Schema-Loader CPAN distribution.

Report information
The Basics
Id: 21316
Status: rejected
Priority: 0/
Queue: DBIx-Class-Schema-Loader

People
Owner: blblack [...] gmail.com
Requestors: LGODDARD [...] cpan.org
Cc:
AdminCc:

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



Subject: Simplest example fails
package setupdb; $_ = "CREATE TABLE Programmes ( id INT UNSIGNED NOT NULL AUTO_INCREMENT, crid VARCHAR(255) NOT NULL, PRIMARY KEY (id) ) TYPE=INNODB CHARACTER SET=UTF8 COMMENT='Radio::Four prototype' ;"; open OUT,">temp.temp"; print OUT $_; close OUT; `mysql TEST23 < temp.temp`; unlink 'temp.tmep'; package Radio::Four21; use base qw/DBIx::Class::Schema::Loader/; __PACKAGE__->loader_options( relationships => 1, debug => 1, ); # in seperate application code ... # use My::Schema; # my $schema1 = My::Schema->connect( $dsn, $user, $password, $attrs); our $DB_NAME = 'RADIO4PROGRAMMES2'; # 'Four'; our $DB_HOST = 'localhost'; # 'extdev.bbc.co.uk'; our $DB_PORT = ''; # '3306'; our $DB_USERNAME = ''; # our $DB_AUTH = $WINDOWS? '' : ''; 1; package main; # use Radio::Four21; warn "OK"; warn Radio::Four21->dump_to_dir('D:/R42/conf/tmp'); warn "OK"; warn "DB=$Radio::Four21::DB_NAME\n"; my $schema = Radio::Four21->connect( "dbi:mysql:database=$Radio::Four21::DB_NAME;host=$Radio::Four21::DB_HOS T;port=$Radio::Four21::DB_PORT" , $Radio::Four21::DB_USERNAME, $Radio::Four21::DB_AUTH, $Radio::Four21::DB_ATTRS ); # perl -MDBIx::Class::Schema::Loader=dump_to_dir:D:/R42/conf/tmp - MRadio::Four21 -e 'Radio::Four21->connection ("dbi:mysql:dbname=RADIO4PROGRAMMES2")' __END__ __END__ OK at D:\R42\Radio-Four\conf\setup_schema.pl line 22. D:/R42/conf/tmp at D:\R42\Radio-Four\conf\setup_schema.pl line 23. OK at D:\R42\Radio-Four\conf\setup_schema.pl line 24. DB=RADIO4PROGRAMMES2 Radio::Four21::Programmes->load_components("PK::Auto", "Core"); Radio::Four21::Programmes->table("programmes"); Attempt to free unreferenced scalar: SV 0x21e0b14, Perl interpreter: 0x23466c at C:/perl58_AS/site/lib/DBIx/Class/Schema/Loader/Base.pm line 492. Radio::Four21::Programmes->add_columns( "id", { data_type => "INT", default_value => undef, is_nullable => 0, size => 10 }, "crid", { data_type => "VARCHAR", default_value => "", is_nullable => 0, size => 255 }, ); Radio::Four21::Programmes->set_primary_key("id"); Dumping manual schema for Radio::Four21 to directory D:/R42/conf/tmp ... DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No such file or directory at D:\R42\Radio-Four\conf\setup_schema.pl line 28 Tool completed with exit code 2 Show quoted text
win32>perl -V
Summary of my perl5 (revision 5 version 8 subversion 8) configuration: Platform: osname=MSWin32, osvers=5.0, archname=MSWin32-x86-multi-thread uname='' config_args='undef' hint=recommended, useposix=true, d_sigaction=undef usethreads=define use5005threads=undef useithreads=define usemultiplicity=define useperlio=define d_sfio=undef uselargefiles=define usesocks=undef use64bitint=undef use64bitall=undef uselongdouble=undef usemymalloc=n, bincompat5005=undef Compiler: cc='cl', ccflags ='-nologo -GF -W3 -MD -Zi -DNDEBUG -O1 -DWIN32 - D_CONSOLE -DNO_STRICT -DHAVE_DES_FCRYPT -DNO_HASH_S EED -DUSE_SITECUSTOMIZE -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS - DUSE_PERLIO -DPERL_MSVCRT_READFIX', optimize='-MD -Zi -DNDEBUG -O1', cppflags='-DWIN32' ccversion='12.00.8804', gccversion='', gccosandvers='' intsize=4, longsize=4, ptrsize=4, doublesize=8, byteorder=1234 d_longlong=undef, longlongsize=8, d_longdbl=define, longdblsize=10 ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='__int64', lseeksize=8 alignbytes=8, prototype=define Linker and Libraries: ld='link', ldflags ='-nologo -nodefaultlib -debug -opt:ref,icf - libpath:"C:\perl58_AS\lib\CORE" -machine:x86' libpth=\lib libs= oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib netapi32.lib uuid.lib ws2_32.lib mpr.lib winmm.lib version.lib odbc32.lib odbccp32.lib msvcrt.lib perllibs= oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32. lib oleaut32.lib netapi32.lib uuid.lib ws2_32.lib mpr.lib winmm.lib version.lib odbc32.lib odbccp32.lib msvcrt.lib libc=msvcrt.lib, so=dll, useshrplib=yes, libperl=perl58.lib gnulibc_version='' Dynamic Linking: dlsrc=dl_win32.xs, dlext=dll, d_dlsymun=undef, ccdlflags=' ' cccdlflags=' ', lddlflags='-dll -nologo -nodefaultlib -debug - opt:ref,icf -libpath:"C:\perl58_AS\lib\CORE" -machin e:x86' Characteristics of this binary (from libperl): Compile-time options: MULTIPLICITY PERL_IMPLICIT_CONTEXT PERL_IMPLICIT_SYS PERL_MALLOC_WRAP PL_OP_SLAB_ALLOC USE_ITHREADS USE_LARGE_FILES USE_PERLIO USE_SITECUSTOMIZE Locally applied patches: ActivePerl Build 817 [257965] Iin_load_module moved for compatibility with build 806 PerlEx support in CGI::Carp Less verbose ExtUtils::Install and Pod::Find Patch for CAN-2005-0448 from Debian with modifications Partly reverted 24733 to preserve binary compatibilty 27528 win32_pclose() error exit doesn't unlock mutex 27527 win32_async_check() can loop indefinitely 27515 ignore directories when searching @INC 27359 Fix -d:Foo=bar syntax 27210 Fix quote typo in c2ph 27203 Allow compiling swigged C++ code 27200 Make stat() on Windows handle trailing slashes correctly 27194 Get perl_fini() running on HP-UX again 27133 Initialise lastparen in the regexp structure 27034 Avoid "Prototype mismatch" warnings with autouse 26970 Make Passive mode the default for Net::FTP 26921 Avoid getprotobyname/number calls in IO::Socket::INET 26897,26903 Make common IPPROTO_* constants always available 26670 Make '-s' on the shebang line parse -foo=bar switches 26379 Fix alarm() for Windows 2003 26087 Storable 0.1 compatibility 25861 IO::File performace issue 25084 long groups entry could cause memory exhaustion 24699 ICMP_UNREACHABLE handling in Net::Ping Built under MSWin32 Compiled at Mar 20 2006 17:54:25 @INC: C:/perl58_AS/lib C:/perl58_AS/site/lib . X:\>
Can you please supply a simple test script which clearly illustrates the problem? What you've given is specific to your code and/or system, and has obvious typos.
Rejected: need simpler/clearer test case. The best guess I can divine from the bug report itself is that the user failed to create a neccesary output directory.
Subject: Re: [rt.cpan.org #21316] Simplest example fails
Date: Wed, 27 Sep 2006 19:18:15 +0100
To: bug-DBIx-Class-Schema-Loader [...] rt.cpan.org
From: Lee Goddard <lee [...] leegoddard.net>
via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > > Rejected: need simpler/clearer test case. The best guess I can divine > from the bug report itself is that the user failed to create a neccesary > output directory. > >
How about having your software -- and I don't remember what it is and the current lazy and idiotic rt.cpan.org test-run install doesn't tell me -- but how about having your software report when the output directory doesn't exist? -- Lee Goddard Server-side Systems Ltd London N1 :: 0208 369 6832

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

On Wed Sep 27 14:18:35 2006, west.finchley@leegoddard.net wrote: Show quoted text
> via RT wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > > > > > Rejected: need simpler/clearer test case. The best guess I can divine > > from the bug report itself is that the user failed to create a neccesary > > output directory. > > > >
> How about having your software -- and I don't remember what it is and > the current lazy and idiotic rt.cpan.org test-run install doesn't tell > me -- but how about having your software report when the output > directory doesn't exist?
In your own example at the top of this bug, it already did report to you that the output directory doesn't exist: DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No such file or directory at D:\R42\Radio-Four\conf\setup_schema.pl line 28 The behavior of the code is that if your output directory does not exist, it attempts a simple mkdir(), which will succeed if the parent of the specified directory exists and you have permissions. If you haven't yet created the parent, don't have permissions, or any other problem occurs with the mkdir() call, then the code throws an exception which includes the textual representation of the errno error returned by the operations system, which in this case clearly indicates "no such file or directory". Is there some other issue here?
Subject: Re: [rt.cpan.org #21316] Simplest example fails
Date: Thu, 12 Oct 2006 23:32:46 +0100
To: bug-DBIx-Class-Schema-Loader [...] rt.cpan.org
From: Lee Goddard <lee [...] leegoddard.net>
via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > On Wed Sep 27 14:18:35 2006, west.finchley@leegoddard.net wrote: >
>> via RT wrote: >>
>>> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > >>> >>> >>> Rejected: need simpler/clearer test case. The best guess I can divine >>> from the bug report itself is that the user failed to create a neccesary >>> output directory. >>> >>> >>>
>> How about having your software -- and I don't remember what it is and >> the current lazy and idiotic rt.cpan.org test-run install doesn't tell >> me -- but how about having your software report when the output >> directory doesn't exist? >>
> > In your own example at the top of this bug, it already did report to you > that the output directory doesn't exist: > > DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No > such file or directory at D:\R42\Radio-Four\conf\setup_schema.pl line > 28 > > The behavior of the code is that if your output directory does not > exist, it attempts a simple mkdir(), which will succeed if the parent of > the specified directory exists and you have permissions. If you haven't > yet created the parent, don't have permissions, or any other problem > occurs with the mkdir() call, then the code throws an exception which > includes the textual representation of the errno error returned by the > operations system, which in this case clearly indicates "no such file or > directory". > > Is there some other issue here?
The issue is best summed up as "insufficient diagnostics available." Shouldn't error codes be self explanatory, at least in the context of the application, or code syntax?

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

On Thu Oct 12 18:33:09 2006, west.finchley@leegoddard.net wrote: Show quoted text
> via RT wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > > > On Wed Sep 27 14:18:35 2006, west.finchley@leegoddard.net wrote: > >
> >> via RT wrote: > >>
> >>> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > >>> > >>> > >>> Rejected: need simpler/clearer test case. The best guess I can divine > >>> from the bug report itself is that the user failed to create a
neccesary Show quoted text
> >>> output directory. > >>> > >>> > >>>
> >> How about having your software -- and I don't remember what it is and > >> the current lazy and idiotic rt.cpan.org test-run install doesn't tell > >> me -- but how about having your software report when the output > >> directory doesn't exist? > >>
> > > > In your own example at the top of this bug, it already did report to you > > that the output directory doesn't exist: > > > > DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No > > such file or directory at D:\R42\Radio-Four\conf\setup_schema.pl line > > 28 > > > > The behavior of the code is that if your output directory does not > > exist, it attempts a simple mkdir(), which will succeed if the parent of > > the specified directory exists and you have permissions. If you haven't > > yet created the parent, don't have permissions, or any other problem > > occurs with the mkdir() call, then the code throws an exception which > > includes the textual representation of the errno error returned by the > > operations system, which in this case clearly indicates "no such file or > > directory". > > > > Is there some other issue here?
> The issue is best summed up as "insufficient diagnostics available." > Shouldn't error codes be self explanatory, at least in the context of > the application, or code syntax?
I still disagree that there is an issue here. How exactly should the error be improved from what it is. This is the error message you received: DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No such file or directory How would you improve it?
Subject: Re: [rt.cpan.org #21316] Simplest example fails
Date: Tue, 24 Oct 2006 21:03:33 +0100
To: bug-DBIx-Class-Schema-Loader [...] rt.cpan.org
From: Lee Goddard <lee [...] leegoddard.net>
via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > On Thu Oct 12 18:33:09 2006, west.finchley@leegoddard.net wrote: >
>> via RT wrote: >>
>>> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > >>> >>> On Wed Sep 27 14:18:35 2006, west.finchley@leegoddard.net wrote: >>> >>>
>>>> via RT wrote: >>>> >>>>
>>>>> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > >>>>> >>>>> >>>>> Rejected: need simpler/clearer test case. The best guess I can divine >>>>> from the bug report itself is that the user failed to create a >>>>>
> neccesary >
>>>>> output directory. >>>>> >>>>> >>>>> >>>>>
>>>> How about having your software -- and I don't remember what it is and >>>> the current lazy and idiotic rt.cpan.org test-run install doesn't tell >>>> me -- but how about having your software report when the output >>>> directory doesn't exist? >>>> >>>>
>>> In your own example at the top of this bug, it already did report to you >>> that the output directory doesn't exist: >>> >>> DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No >>> such file or directory at D:\R42\Radio-Four\conf\setup_schema.pl line >>> 28 >>> >>> The behavior of the code is that if your output directory does not >>> exist, it attempts a simple mkdir(), which will succeed if the parent of >>> the specified directory exists and you have permissions. If you haven't >>> yet created the parent, don't have permissions, or any other problem >>> occurs with the mkdir() call, then the code throws an exception which >>> includes the textual representation of the errno error returned by the >>> operations system, which in this case clearly indicates "no such file or >>> directory". >>> >>> Is there some other issue here? >>>
>> The issue is best summed up as "insufficient diagnostics available." >> Shouldn't error codes be self explanatory, at least in the context of >> the application, or code syntax? >>
> > I still disagree that there is an issue here. How exactly should the > error be improved from what it is. This is the error message you received: > > DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No such > file or directory > > How would you improve it? > >
Making a directory does not seem a logical, or common, consequence of connecting. Hence the confusion. -- Lee Goddard Server-side Systems Ltd London N1 :: 0208 369 6832

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

On Tue Oct 24 16:04:35 2006, west.finchley@leegoddard.net wrote: Show quoted text
> > DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No
> such
> > file or directory > > > > How would you improve it? > > > >
> Making a directory does not seem a logical, or common, consequence of > connecting. Hence the confusion. >
It certainly does make sense in the case that you explicitly *asked* the software to dump files into a bunch of directories on connection, via the dump_to_dir or dump_directory options. Please don't reopen this again unless you have a better argument.
Subject: Re: [rt.cpan.org #21316] Simplest example fails
Date: Wed, 15 Nov 2006 19:29:09 +0000
To: bug-DBIx-Class-Schema-Loader [...] rt.cpan.org
From: Lee Goddard <lee [...] leegoddard.net>
Brandon L Black via RT wrote: Show quoted text
> <URL: http://rt.cpan.org/Ticket/Display.html?id=21316 > > > On Tue Oct 24 16:04:35 2006, west.finchley@leegoddard.net wrote: >
>>> DBIx::Class::Schema::connect(): mkdir('D:/R42/conf/tmp') failed: No >>>
>> such >>
>>> file or directory >>> >>> How would you improve it? >>> >>> >>>
>> Making a directory does not seem a logical, or common, consequence of >> connecting. Hence the confusion. >> >>
> > It certainly does make sense in the case that you explicitly *asked* the > software to dump files into a bunch of directories on connection, via > the dump_to_dir or dump_directory options. Please don't reopen this > again unless you have a better argument. >
Ok.

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

I'm assuming this is just open because the correspondence automatically re-opened it. Re-rejecting.