#441 closed defect (fixed)

CLI: "tahoe put $MUTABLE" doesn't work

Reported by: warner Owned by:
Priority: major Milestone: 1.3.0
Component: code-frontend-cli Version: 1.2.0
Keywords: mutable cli Cc:
Launchpad Bug:

Description

Once you've created an unlinked mutable file with "cat DATA | tahoe put --mutable" (which returns a $MUTABLE write-cap), you ought to be able to replace the contents of that file with "cat NEWDATA | tahoe put $MUTABLE". But it doesn't work.

% cat setup.py |./bin/tahoe put URI:SSK:4ng7..:dxw..
waiting for file data on stdin..
error, got 400 Bad Request
Cannot create directory '', because its parent is a file, not a directory

Change History (5)

comment:1 Changed at 2008-07-14T22:38:13Z by warner

  • Milestone changed from eventually to 1.1.1

this might be fixed in 1.1.0, I remember doing work on the 'put' command.

comment:2 Changed at 2008-07-22T02:03:30Z by warner

  • Version changed from 1.0.0 to 1.2.0

nope, it's still broken, in 1.2.0

% ./bin/tahoe put setup.py URI:SSK:o5we7beiivu4kbshm65qf7hl2y:u4rfoy2kawiay75t6fyiksbrwqsv3746up4jsmvxhfuprkf34keq
error, got 400 Bad Request
Cannot create directory '', because its parent is a file, not a directory
% ./bin/tahoe --version
allmydata: 1.2.0, foolscap: 0.2.9, pycryptopp: 0.5.1, zfec: 1.1, twisted: 8.1.0, nevow: 0.9.31, simplejson: 1.9.2, pyopenssl: 0.6, setuptools: 0.6c8

comment:3 Changed at 2008-08-04T20:20:15Z by warner

f7d2fcc233d4ec02 fixes the original bug, although the syntax for "tahoe put ONEARG" has changed, so the way you copy stdin to a mutable filecap is:

cat setup.py | ./bin/tahoe put - URI:SSK:4ng7...

you can also do tahoe put setup.py URI:SSK:4ng7....

I'm holding off on closing this bug until I write a test that creates a mutable file and then overwrites it in-place, using the vdrive filename instead of the writecap:

tahoe put --mutable foo.txt alias:foo.txt
tahoe put bar.txt alias:foo.txt

comment:4 Changed at 2008-08-04T20:27:51Z by warner

  • Resolution set to fixed
  • Status changed from new to closed

Ok, 45d12baba2449fc1 adds the test that covers that case.

comment:5 Changed at 2008-09-03T01:17:21Z by warner

  • Milestone changed from 1.3.1 to 1.3.0
Note: See TracTickets for help on using tickets.