~sschwarzer/ftputil#42: 
Install from trunk svn checkout (896) on OS X 10.6 cause error

#sudo python setup.py install

everything goes fine up to:

byte-compiling /Library/Python?/2.6/site-packages/ftputil/lrucache.py to lrucache.pyc running install_data creating /System/Library/Frameworks/Python?.framework/Versions/2.6/doc copying ftputil.txt -> /System/Library/Frameworks/Python?.framework/Versions/2.6/doc error: can't copy 'ftputil.html': doesn't exist or not a regular file

I am reporting this just to make sure it's recorded. I'l track it down right now and supply a patch/fix as soon as I find it.

Status
RESOLVED INVALID
Submitter
ssteiner (unverified)
Assigned to
No-one
Submitted
14 years ago
Updated
14 years ago
Labels
bug

ssteiner (unverified) 14 years ago · edit

The html file, which is present in the ftputil-2.4.2b2.tar.gz file, is missing from svn checkout for some reason.

I guess the "cure" is to just restore the file...

ssteiner (unverified) 14 years ago · edit

This error is caused by the fact that setup.py bdist or sdist must be run to generate the HTML files.

I'm used to libraries being able to be run with setup.py develop which just links back to the current directory in site-packages so the library can be "installed" with an svn checkout being the 'library'.

Running python setup.py bdist or sdist generates the file and the library installs fine.

Sorry for the line noise...

schwa (unverified) 14 years ago · edit

Yes, I haven't included the HTML files because they can be generated automatically from the .txt files. If you just want to make the HTML files, you can run make docs if you have ​docutils installed.

Apart from that, your point in the previous comment in my opinion is a good one. A way to achive the out-of-the-box installation might be to let setup.py generate the HTML docs if they don't exist, but that in turn would still require docutils. On the other hand, just adding the HTML docs to the Subversion repository conceals the presumably automated relationship between the formats and leads to inconsistent documentation files if someone changes a text file without re-generating the HTML.

I'll think about it. What do you think?

schwa (unverified) 14 years ago · edit

I've checked in 897 which contains a check in setup.py: If one or more of the HTML files is missing on attempted installation, setup.py prints a message to run "make docs" and exits. I think that's reasonable enough.

I'll revoke the change before I release 2.4.2, and include the code afterwards. It would be embarrassing to make something I haven't thought of fail because of such a change. And I don't want to make another beta release.

So please use revision 897 specifically,

$ svn up -r897

and test it. :)

schwa (unverified) 14 years ago · edit

I re-added the patch in [bb727f02e5d0f6d1ebd76bb5904b01b9f53ec596](https://git.sr.ht/~sschwarzer/ftputil/commit/bb727f02e5d0f6d1ebd76bb5904b01b9f53ec596 "Re-added the patch which used to be svn rev 897 (see ticket #42)."). The Subversion revision which used to be 897 is now a5c494724c8d8f6cf5753c9fbcab9d7cb657533e.

Register here or Log in to comment, or comment via email.