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

qri component filename in FSI are case-sensitive #1509

Closed
b5 opened this issue Sep 8, 2020 · 1 comment · Fixed by #1512
Closed

qri component filename in FSI are case-sensitive #1509

b5 opened this issue Sep 8, 2020 · 1 comment · Fixed by #1512
Labels
bug code that is not behaving as expected FSI file system integration

Comments

@b5
Copy link
Member

b5 commented Sep 8, 2020

Environment

What is your OS and version?

OS-X

What version of qri are you using (qri version)?

HEAD

Issue

What did you do?

created an FSI-linked dataset with an upper-case README.md

What happened?

FSI didn't pick up on the readme

What did you expect to happen?

expected Qri to see README.md as a readme component

b5 at b5-2 in ~/datasets/rm_me_3
$ mkdir case_sensitive

b5 at b5-2 in ~/datasets/rm_me_3
$ cd case_sensitive

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ qri init
Name of new dataset [case_sensitive]:
Format of dataset, csv or json [csv]:
initialized working directory for new dataset rm_me_3/case_sensitive

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ qri status
for linked dataset [rm_me_3/case_sensitive]

  add: meta (source: meta.json)
  add: structure (source: structure.json)
  add: body (source: body.csv)

run `qri save` to commit this dataset

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ touch README.md

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ qri status
for linked dataset [rm_me_3/case_sensitive]

  add: meta (source: meta.json)
  add: structure (source: structure.json)
  add: body (source: body.csv)

run `qri save` to commit this dataset

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ mv README.md readme.md

b5 at b5-2 in ~/datasets/rm_me_3/case_sensitive
$ qri status
for linked dataset [rm_me_3/case_sensitive]

  add: meta (source: meta.json)
  add: structure (source: structure.json)
  add: readme (source: readme.md)
  add: body (source: body.csv)
@b5 b5 added bug code that is not behaving as expected FSI file system integration labels Sep 8, 2020
@dustmop
Copy link
Contributor

dustmop commented Sep 8, 2020

Should this be true for all components? Is BODY.csv the same as body.csv? On some filesystems these are different filenames, on some they are not. For example, Windows is case-insensitive, but POSIX is case-sensitive.

Probably the most reasonable thing to do is to treat all component filenames as case-sensitive, and treat it as a conflict to have two files with different casing, just like having a meta.json and a dataset.json which has a meta.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug code that is not behaving as expected FSI file system integration
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants