Project

General

Profile

Actions

Bug #5179

closed

[Workbench] [SDKs] Incorrect collection display when stream has entries with subdirectories

Added by Bryan Cosca about 9 years ago. Updated almost 9 years ago.

Status:
Resolved
Priority:
Normal
Assigned To:
Radhika Chippada
Category:
Workbench
Target version:
Story points:
0.5

Description

Here, temp_admix_files-PATHOMAP_P00553_1k should be a directory with those files tempAut.bed (etc) in it. this is collection: qr1hi-4zz18-4ea12pbiq1zaf08. This can be reproduced locally and should be a directory.


Files

directorystructuredoesnthold.png (24.4 KB) directorystructuredoesnthold.png Bryan Cosca, 02/09/2015 06:25 AM

Subtasks 1 (0 open1 closed)

Task #5773: Review branch: 5179-dirs-in-filenamesResolvedRadhika Chippada04/19/2015Actions

Related issues

Related to Arvados - Bug #5682: [Workbench] Can't view/download files under subdirectories in streamResolvedRadhika Chippada05/07/2015Actions
Blocked by Arvados - Feature #5104: [SDKs] Add Ruby SDK methods for manipulating collection contents (rename, delete, copy file from another collection)ResolvedBrett Smith03/08/2015Actions
Actions #1

Updated by Brett Smith about 9 years ago

  • Subject changed from Creating a directory in the output directory and merging to a collection does not hold the directory structure to [Workbench] Incorrect collection display when stream has entries with subdirectories
  • Category set to Workbench
  • Target version set to Bug Triage
Actions #2

Updated by Tom Clegg about 9 years ago

  • Target version changed from Bug Triage to 2015-04-01 sprint
Actions #3

Updated by Tom Clegg about 9 years ago

  • Story points set to 0.5
Actions #4

Updated by Tom Clegg about 9 years ago

Best fix for this is probably to use the new SDK from #5104.

Actions #5

Updated by Brett Smith about 9 years ago

  • Assigned To set to Brett Smith
Actions #6

Updated by Brett Smith about 9 years ago

  • Assigned To deleted (Brett Smith)
  • Target version changed from 2015-04-01 sprint to Arvados Future Sprints
Actions #7

Updated by Tom Clegg about 9 years ago

Looks like this is a bug in Keep#files in source:sdk/ruby/lib/arvados/keep.rb#L164 -- each_file_spec provides [stream_name, pos, size, filename] and #files needs to split filename by '/' and move the dir parts onto streamname in order to consistently return [dirname, basename, size] regardless of whether streams===dirs.

(Obviously need a test case for this too!)

Actions #8

Updated by Radhika Chippada about 9 years ago

  • Subject changed from [Workbench] Incorrect collection display when stream has entries with subdirectories to [Workbench] [SDKs] Incorrect collection display when stream has entries with subdirectories
  • Status changed from New to In Progress
  • Assigned To set to Radhika Chippada
  • Target version changed from Arvados Future Sprints to 2015-04-29 sprint
Actions #9

Updated by Radhika Chippada about 9 years ago

Implementation notes:

  • Updated Keep#files method as per Tom's note. Added test fixture and test.
  • Updated workbench Gemfile* to use the newer gem version. (Note: Please let me know if I did not get this right. Thanks.)
  • Manual test performed on the collection qr1hi-4zz18-4ea12pbiq1zaf08 and it now displays directory structure. And the files in directories are viewable and downloadable (#5682)
Actions #10

Updated by Tom Clegg almost 9 years ago

comments on 5179-dirs-in-filenames @ 17e59fe

Code looks good. (The "rpartition" threw me off for a bit by using the "/" from "dir1/file1" to build the "./dir1" string... but then I got it.)

I think it would be worthwhile to add a test case like this:

. #{random_block(10)} 0:3:file1 3:3:dir1/file1 6:4:dir1/dir2/file1
./dir1 #{random_block(10)} 0:3:file1 3:7:dir2/file1

→ check that manifest.files contains ["./dir1", "file1", 6] and ["./dir1/dir2", "file1", 11]

Unfortunately this will mean doing the Gemfile.lock thing over again. If that's too painful, and assuming the actual sdk code doesn't have to change to make that test pass (as I suspect) you could merge 17e59fe and then add this test in another commit after jenkins has had a chance to build/publish the 0.1.20150419022214 package.

Actions #11

Updated by Radhika Chippada almost 9 years ago

  • Status changed from In Progress to Resolved

Applied in changeset arvados|commit:da705110826943b04151f959e059b5f4ffcc4c5e.

Actions

Also available in: Atom PDF