0

Just installed tup on ubuntu 16.04 and got the following error:

$ tup init  
.tup repository initialized.  
SQL reset error: database is locked  
Statement was: commit  

Also tup upd has error as well.

$ tup upd
.tup/shared: No such file or directory
tup error: Unable to open lockfile.

Any ideas on how I can get tup to work?

EDIT: I downloaded the source from git (https://github.com/gittup/tup) and stepped through it and the error appears to be in src/tup/db.c:tup_db_commit() line 933

rc = sqlite3_step(*stmt);  

sqlite3_step function is returning SQLITE_BUSY(5).
My noob guess is that I'm using a newer version of sqlite and some cleanup isn't being done correctly anymore. But it definitely seems like some sort of sqllite3 issue.

sdstack
  • 185
  • 9
  • Could you try the following: `cd $(mktemp -d) && touch Tupfile && tup init`? This works on ArchLinux. Also post your exact version of tup (`tup --version`). – Freddie Chopin Oct 18 '16 at 17:50
  • @FreddieChopin $ cd $(mktemp -d) && touch Tupfile && tup init .tup repository initialized. It works. Are you suggesting its a directory permission problem? $ tup --version tup 0.7.2-12-ga582fee – sdstack Oct 18 '16 at 17:56
  • I don't know, but it seems that it works fine in one directory, but fails in another one. Maybe just delete the directory you are using, recreate it and see whether the problem persists? Maybe that's just a single glitch, which will go away after deleting the hidden .tup folder (or whatever file/folder causes this problem)? – Freddie Chopin Oct 18 '16 at 18:03
  • @FreddieChopin tried it on a brand new directory and did not work. My top level directory is a mapped (fstab) network drive. My user is the owner and it has full access so I am not sure why it won't work. I'll keep playing around with it. – sdstack Oct 18 '16 at 19:36
  • Have you tried a more recent version? The one you are using is over 2 years old - if there is/was any problem in tup, then maybe its just fixed now... – Freddie Chopin Oct 19 '16 at 06:20
  • @FreddieChopin I Followed the ubuntu install instructions at http://gittup.org/tup/index.html. Didn't realize those were so outdated. I'll look for something more recent. – sdstack Oct 19 '16 at 12:57
  • I changed the settings on my mount to give full access 0777 to everything and still have the same problem. I also tried installing tup from git and got the same error: bootstrap LD tup -lm .tup repository initialized. SQL reset error: database is locked Statement was: commit – sdstack Oct 19 '16 at 13:48
  • It then seems that there's a bug in tup, so the best option is to report it on github. https://github.com/gittup/tup/issues – Freddie Chopin Oct 19 '16 at 15:19

1 Answers1

1

according to multiple other questions/answers on stackoverflow, you are not supposed to use sqlite3 on a network drive. So by association, you should not use tup on a network drive.

sdstack
  • 185
  • 9