Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

inconsistent case sensivity #862

Closed
aardgoose opened this issue Aug 17, 2016 · 5 comments
Closed

inconsistent case sensivity #862

aardgoose opened this issue Aug 17, 2016 · 5 comments

Comments

@aardgoose
Copy link

Importing a module in two places using paths that are different only in case, but handled as case insensitive, results in two instances of the imported module in the resultant output. (Windows 10).
, rollup v 0.34.8

ie. file lookup is case insensitive
ie. module instancing is case sensitive based on path name differences.

Eg.

Module 1:

import { Materials } from './materials/Materials.js';
...

module 2:

import { Materials } from './Materials/Materials.js';
...

Resultant output file has

Materials and Materials$1 objects with expected breakage.

@snuggs
Copy link

snuggs commented Aug 20, 2016

I feel the lowest common denominator is POSIX compliance which the following volume formats abide by (for the most part):

Linux and Derivatives ( ! OSX)

√ Files MUST be case sensitive. (http://superuser.com/questions/431342/linux-both-case-sensitive-and-case-insensitive-and-always-inconvenient)

Windows (NTFS)

√ Files MUST be case sensitive (https://support.microsoft.com/en-us/kb/100625)

Windows (VFAT | FAT32)

√ Files MUST NOT be case sensitive
capture d ecran 2016-08-19 a 22 24 22

OSX

√ Files are SHOULD be case sensitive (but aren't).

capture d ecran 2016-08-19 a 22 18 20

Therefore IMHO I feel like we should throw instead of returning a false positive regardless of the solution. "Failing" silently seems too flagrant and would proliforate confusion that is already at a (potential) disagreement on the respective operating system. (I'm lookin' at YOU WIN32 Your thoughts @aardgoose

@pmart123
Copy link

@snuggs I like the idea. From prior experience of being burned in similar situations, throwing the error is a nice gesture in comparison to the amount of potential time spent tracking something like this down.

@Rich-Harris
Copy link
Contributor

I actually opened a PR for this yonks ago – #630 – but forgot about it. Just merged it, will cut a release soon. Thanks

@snuggs
Copy link

snuggs commented Aug 31, 2016

Well that's what i'm here for @Rich-Harris a little healthy nudge. Until can be more productive. Got a great thing going on here. 👍 #FACTS

@aardgoose
Copy link
Author

Many thanks, may save me some head scratching time in future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants