Hi Simon,

this problem exists also for windows users that develop on windows and  
deploy on linux. It's a booby trap that explodes when you deploy. This  
is not an easy problem to tackle and I guess there's no way we can  
really fix that. It might be worth giving that a little thought,  
that's why I asked for a bug report. We can always close it as "can't  
fix" and explain the issue but then it's at least documented.

We try to be as cross-platform as possible, so we should at least try  
here as well. Maybe a "warn me if case is different" option in  
development might be an option. Or even "fail if case of model file is  
different". That would defuse the booby trap by showing you what would  
happen if you deployed on a case sensitive FS.

felix


On Oct 26, 2009, at 11:21 AM, Simon Cornelius P Umacob wrote:

> Hi Michal,
>
> On Mon, Oct 26, 2009 at 6:02 PM, Michal Charemza
> <[email protected]> wrote:
>>
>> This surprises me.  As:
>>
>> - It leads to inconsistent behaviour between OS X and Linux. For the
>> model "Records" getModel('Records') and getModel('records') both work
>> on OS X but only getModel('Records') on Linux. It took me a while to
>> figure this one out when moving a project.
>
> To your point of view, that may be inconsistent; however, this
> behavior is consistent to others.
>
> By default, Apples ships their machines with HFS+ volumes that are
> case-insensitive, but case-preserving.  With this setup,
> recordsModel.class.php will be stored correctly in its file system,
> but you can access it via RecordsModel.class.php or
> recordsmodel.class.php.
>
> PHP is just a C application.  Thus, fread() or file_get_contents()
> will use standard C calls such as fopen() underneath.  Under Mac OS X,
> the C calls will not fail if it is given a wrong capitalization
> because the file system doesn't care.  This is expected behavior.
>
> By default, Linux and Unix systems use case-sensitive and
> case-preserving file systems.  With this setup, recordsModel.class.php
> and RecordsModel.class.php are two different files, and can co-exist
> within a single directory.  In this environment, the C calls will fail
> if it is given a wrong capitalization because the file system cares.
> This is expected behavior.
>
> In my world, as a FreeBSD user, getModel('records') should fail for
> model "Records".  I strongly disagree that Agavi's behavior be changed
> to adapt to wrong expected behavior.
>
>
> Regards,
>
> [ simon.cpu ]
>
> _______________________________________________
> users mailing list
> [email protected]
> http://lists.agavi.org/mailman/listinfo/users
>

--
Felix Gilcher

Bitextender GmbH
Paul-Heyse-Str. 6
D-80336 München

T: +49 89 57 08 15 16
F: +49 89 57 08 15 17
M: +49 172 840 88 28

[email protected]
http://www.bitextender.com/

Amtsgericht München, HRB 174280
Geschäftsführer: David Zülke, Florian Clever


_______________________________________________
users mailing list
[email protected]
http://lists.agavi.org/mailman/listinfo/users

Reply via email to