aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/command/serve.py
Commit message (Collapse)AuthorAgeFilesLines
* Fixed update_copyright.py's subproc import and updated copyrightsW. Trevor King2010-01-011-4/+1
|
* Serve.handle_*() now raise _HandlerError so the .do_*() methods know.W. Trevor King2010-01-011-8/+17
| | | | | Before there wasn't a good way to tell if the handler had experienced an error, or just didn't want to return anything.
* Fixed commit handling in commands.serve and storage.httpW. Trevor King2010-01-011-3/+7
|
* Use more kwargs in libbe.command.serveW. Trevor King2010-01-011-11/+10
| | | | | | | | kwargs make things easier to maintain. Also make sure the .handle_*() methods return two items (content,ctype) even when both are None.
* Improved POST and error handling in `be serve`W. Trevor King2010-01-011-22/+43
| | | | | | | | | | | | | | POST handling: Drop the cgi.FieldStorage() in favor of the old urlparse.parse_qs(). We need a dictionary, which FieldStorage is not. However, I added .read_post_data() since my old self.rfile.read() was hanging. The read_post_data() implementation comes from the FieldStorage.__init__(). Error handling: wrap .handle_*() blocks in try/except to handle Storage errors
* Improved POST parsing, fixed Serve._long_help(), added --read-only.W. Trevor King2010-01-011-49/+40
| | | | | POST parsing via cgi.FieldStorage from Doug Hellmann's http://blog.doughellmann.com/2007/12/pymotw-basehttpserver.html
* Added libbe.command.serve and libbe.storage.http for HTTP backend.W. Trevor King2010-01-011-0/+346
Now the following works: some-BE-dir$ ./be serve $ ./be --repo http://localhost:8000 list I haven't come up with a clean idea for testing this yet, so other commands may be broken, but once we get the testing working, it shouldn't be too hard to get everything working over HTTP :).