daltonserey / tst

Students assignments testing

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

I can't commit an empty question

mirnacarelli opened this issue · comments

mirna@splab:~/Dropbox/Doutorado Mirna/tst
$ tst new mc5
mirna@splab:~/Dropbox/Doutorado Mirna/tst
$ tst commit2
This is not a tst directory
mirna@splab:~/Dropbox/Doutorado Mirna/tst
$ tst commit2 mc5
This is not a tst directory
mirna@splab:~/Dropbox/Doutorado Mirna/tst
$ 

When I run checkout2 command for the same activity to check if it has already been created, but It didn't work.
$ tst checkout2 mc5
Traceback (most recent call last):
File "/home/mirna/.tst/commands/tst-checkout2", line 117, in
main(text_in_file)
File "/home/mirna/.tst/commands/tst-checkout2", line 86, in main
if config['user'] != response_json['owner'] and config['user'] not in response_json['collaborators']:
KeyError: u'owner'
mirna@splab:~/Dropbox/Doutorado Mirna/tst

Really do not like running.
Once you create the activity, you must enter the directory.
See the correct sequence:

tst new filename
cd filename
tst commit2

The commit command showed the message because he researched the tst files in the current directory but not found. So we should always run the commit within the directory where are the yaml and json files.

As for the checkout if the commit was not run properly, obviously does not to download the files if they have not gone up.

As @sormanydantas said, by the sequence of commands you posted above, it seems you are creating the activity, and then you are running the commit in the same directory. However, remember that when you create an activity, a new directory is created with the name you passed as argument to the new command. Thus, the correct sequence of commands should be the one @sormanydantas mentioned above.

Observation. I couldn't understando what you meant in your second message.

I said that...
You can not do a checkout first if it was not been committed for the first time.
Sorry for the poorly written English. The google translate does not help much.