| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
| |
This fixes .test_get_initial_value for the HTTP backend, because the
tests use TestingHTTP.getURL, which only catch HandlerError, not the
more specific storage exceptions.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This is analagous to the earlier change to get_post_url:
commit 0cd072b9710ee964e6f449abd9265d85e02f34d2
Author: W. Trevor King <wking@tremily.us>
Date: Fri Aug 24 09:29:58 2012 -0400
util:http: add ability to pass raw POST data with get_post_url.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is an initial step towards improving BE's efficiency.
Previously, BE gets slow as the bug count increases for several
commands (e.g. `be list`), because it takes time to load the bugdir
information from disk at each invocation. If you use a remote repo
(`be --repo http://localhost:8000/ list`), the server process may have
already loaded the repo from disk, but now your listing process has to
fetch everything over the wire. This is even worse than loading it
from disk.
With the new `be serve-commands` and `be --server URL ...` pair, the
bugdir loading happens once on the server, and all the processing is
also carried out on the server. This means that calls like `be
--server http://localhost:8000/ list` will scale much better than
other methods. For example:
$ time be --server http://localhost:8000/ list > /dev/null
real 0m2.234s
user 0m0.548s
sys 0m0.114s
$ time be --server http://localhost:8000/ list > /dev/null
real 0m0.730s
user 0m0.548s
sys 0m0.112s
$ time be list > /dev/null
real 0m2.453s
user 0m2.289s
sys 0m0.166s
$ time be list > /dev/null
real 0m2.521s
user 0m2.350s
sys 0m0.172s
The first call to a cold server takes about the same time as a local
call, because you need to load the bugs from the filesystem. However,
later calls to a warm server are 3x faster, while later local calls
are still slow.
This is currently a minimal working implementation. There's a good
deal of code in libbe.command.serve that I'd like to abstract out into
a libbe.util library (since there's still a bunch of duplication
between libbe.command.serve and libbe.command.serve_commands). The
remote calls are also not as fast as I'd like, likely due to library
load times. This commit just locks in an initial working
implementation.
|
|
|
|
|
| |
It's hard to see why it wouldn't be, but .setup_command handles the
case where it's missing, so we should be consistent here.
|
|
|
|
| |
More Pythonic.
|
|
|
|
| |
Previously, only the SSL server was using ExceptionApp.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
They were being logged by the request handler, and then logged again
by WSGI_Object.log_request. After this patch, requests are only
logged when logger.level is at a <= level (e.g. closer to DEBUG)
than the WSGI_Object.log_level (usually INFO). For example, in
Serve_setup_logging,
self.logger.setLevel(logging.INFO)
will get request logs printed, but
self.logger.setLevel(logging.WARNING)
will not.
|
|
|
|
|
| |
This makes the default output less threatening for new users, while
still supplying the full UUIDs for driving BE from external software.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some temporary changes to encoding.py seem to have been added to
commit 1512c0e2a64e19c8d4e5697257a4df5ddd8bc727
Author: W. Trevor King <wking@drexel.edu>
Date: Tue Nov 8 07:14:43 2011 -0500
by accident.
The initial change came from discussions with Niall Douglas, during
which I realized that "filesystem encoding" ususally means the
encoding for the *path*, not the *contents*. To avoid further
confusion I'd renamed `get_filesystem_encoding` to the less ambiguous
`get_text_file_encoding`. This commit should complete the transition.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This catches the test result up after:
Commit: 0d5c9c68e947617c9d073d5f19351bdd8f3866db
Author: W. Trevor King <wking@drexel.edu>
Date: Wed May 25 10:30:19 2011 -0400
Attach ImportError message to UnknownCommand to aid debugging.
|
|
|
|
|
|
|
|
|
| |
If the user doesn't provide the summary on the command line, through
stdin, or through editor_string, raise an error. This will generally
happen with
$ be commit
(user doesn't enter any text in the editory)
|
| |
|
|
|
|
|
|
| |
Now you can run `be commit` with no options and have the summary split
off the body automatically. This should be more familiar to most VCS
users.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Because "be set severity blah" does not actually work, referring users
there to set custom severity levels is just cruel (I spent a half hour
trying to figure out what I was doing wrong). Thus, it is much easier
to, at least for now, state in the help message what they must do in
order to get custom severities and statuses.
|
|
|
|
|
|
| |
Again, there is discrepancy between severity.py and status.py. I thought
this feature was extremely useful in severity.py and it should be put
into status.py too.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The code structure was vastly different in severity.py to status.py, so
I mostly copied the structure from there and adjusted it to suit
severity.
The structure in status.py looked (to me) cleaner, more organised, and
easier to work with.
Also, users are now referred by "be severity --help" to "be set --help",
in a manner similar to "be status --help".
For those that don't know that severity can be adjusted on a per
repository basis, this seems extremely helpful. A similar message
appears for status, but not here.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
UsageError was removed back in
commit bf3d434b244c57556bec979acbc658c30eb58221
Author: W. Trevor King <wking@drexel.edu>
Date: Sat Dec 12 00:31:55 2009 -0500
Added libbe.command.base (with Command class)...
because the distinction between UsageError and UserError was unclear.
I've brought it back to satisfy a request by Christian Heinrich:
On Sun, May 01, 2011 at 02:52:13AM +0200, Christian Heinrich wrote:
> 3.) Using wrong syntax should receive better help messages.
>
> Current:
>
> "be new" -> ERROR:
> Missing required argument SUMMARY
>
> Should be:
>
> "be new" -> usage: be new [options] SUMMARY
> ...
He suggested we print the full option list as well, but I've decided
to just print the usage summary and remind the user how to get the
full help message if they want it.
|
|
|
|
| |
Thanks to Christian Heinrich for pointing this out.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|\ |
|
| | |
|
| | |
|
|/ |
|
| |
|
| |
|
| |
|
|\ |
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
After a bug has been assigned from status `open' it is no longer
eligible for that status as described:
A working bug that has not been assigned to a developer.
|
| | |
|
| | |
|
| | |
|
| | |
|