be.git
5 years agoIncorrect accquiring bugdir command line argument master
Matěj Cepl [Thu, 31 Oct 2013 17:46:09 +0000 (18:46 +0100)]
Incorrect accquiring bugdir command line argument

The calling below seems like a typo to me. How can we index with
a variable which has not been initialized yet?

6 years agosetup.py: Add a '# Copyright' stub for update-copyright.py
W. Trevor King [Fri, 2 Aug 2013 18:07:14 +0000 (11:07 -0700)]
setup.py: Add a '# Copyright' stub for update-copyright.py

6 years agoadd a comma to the classifiers
Thomas Levine [Fri, 28 Jun 2013 17:26:55 +0000 (10:26 -0700)]
add a comma to the classifiers

6 years agoMerge remote-tracking branch 'esr/master'
W. Trevor King [Fri, 2 Aug 2013 17:51:52 +0000 (10:51 -0700)]
Merge remote-tracking branch 'esr/master'

* esr/master:
  Typo fix.

6 years agoMerge remote-tracking branch 'mcepl/utf8_user'
W. Trevor King [Mon, 29 Jul 2013 17:09:38 +0000 (10:09 -0700)]
Merge remote-tracking branch 'mcepl/utf8_user'

* mcepl/utf8_user:
  Make BE working with non-ASCII username.

6 years agoMake BE working with non-ASCII username.
Matěj Cepl [Mon, 22 Jul 2013 18:38:45 +0000 (20:38 +0200)]
Make BE working with non-ASCII username.

Signed-off-by: Matěj Cepl <mcepl@redhat.com>
6 years agocommand:target: Print full ID (bugdir/bug) on --resolve
W. Trevor King [Wed, 10 Jul 2013 14:07:37 +0000 (10:07 -0400)]
command:target: Print full ID (bugdir/bug) on --resolve

The old implementation just printed the bug UUID (without the bugdir/
prefix).  This lead to the command we suggest in `be target --help`:

  $ be depend --status -closed,fixed,wontfix --severity -target \
    $(be target --resolve)

failing with an invalid ID.

Reported-by: Michael Sperber <sperber@deinprogramm.de>
6 years agocommand:html: Rework comment <div> closing
W. Trevor King [Wed, 13 Mar 2013 03:04:56 +0000 (23:04 -0400)]
command:html: Rework comment <div> closing

Comment nesting wasn't working properly before, where you could get
things like:

  <div class="comment root" id="a">
  </div>  <!-- close a -->
  <div class="comment" id="a/b">
  <div class="comment" id="a/b/c">
  <div class="comment root" id="d">
  </div>  <!-- close d -->
  </div>  <!-- close a/b/c -->
  </div>  <!-- close a/b -->

from a comment tree (using fake ids) of:

  .
  |-- a
  |   `-- a/b
  |       `-- a/b/c
  `-- d

The new handling pushes the `div_close(depth)` call to the front of
the comment block, because a comment's depth tells us how many of the
already-rendered comments we need to close.  Closing comments at the
top of the block means that we'll always have at least one unclosed
comment to close after the comment loop completes.  With the new
handling, we'll get a more appropriate:

  <div class="comment root" id="a">
  <div class="comment" id="a/b">
  <div class="comment" id="a/b/c">
  </div>  <!-- close a/b/c -->
  </div>  <!-- close a/b -->
  </div>  <!-- close a -->
  <div class="comment root" id="C29a03522-ed6e-4a9a-8823-23a1c513865f">
  </div>  <!-- close d -->

Reported-by: Owen Jacobson <owen.jacobson@grimoire.ca>
6 years agoTypo fix.
Eric S. Raymond [Wed, 20 Feb 2013 17:34:39 +0000 (12:34 -0500)]
Typo fix.

6 years agoutil:wsgi: Don't clobber `handler` when clearing StreamHandlers
W. Trevor King [Thu, 31 Jan 2013 23:39:48 +0000 (18:39 -0500)]
util:wsgi: Don't clobber `handler` when clearing StreamHandlers

This bug was introduced in:

  commit 400c9251eedbd1caa3b28135b4bc5d2bf2124ac5
  Author: W. Trevor King <wking@tremily.us>
  Date:   Thu Jan 24 02:43:53 2013 -0500

    util:wsgi: If we're logging to a file, shift libbe.LOG too

where the removed handlers clobbered our initial
TimedRotatingFileHandler.

6 years agoutil:wsgi: If we're logging to a file, shift libbe.LOG too
W. Trevor King [Thu, 24 Jan 2013 07:43:53 +0000 (02:43 -0500)]
util:wsgi: If we're logging to a file, shift libbe.LOG too

This avoids attempts to log to stderr if we're daemonizing the server.

6 years agoTransition to libbe.LOG for logging
W. Trevor King [Thu, 24 Jan 2013 07:31:52 +0000 (02:31 -0500)]
Transition to libbe.LOG for logging

This makes it easier to tweak log verbosity and redirect logs to other
handlers.  For example, the WSGI servers are unstable with stderr
closed, and crash with an IOError if they try to print a warning to
stderr.

6 years agoMANIFEST.in: Distribute AUTHORS with the BE source
W. Trevor King [Thu, 24 Jan 2013 03:32:41 +0000 (22:32 -0500)]
MANIFEST.in: Distribute AUTHORS with the BE source

6 years agoMANIFEST.in: Distribute COPYING with the BE source
W. Trevor King [Thu, 24 Jan 2013 03:17:48 +0000 (22:17 -0500)]
MANIFEST.in: Distribute COPYING with the BE source

6 years agosetup.py: Mention Jinja and CherryPy as requirements
W. Trevor King [Thu, 24 Jan 2013 03:12:59 +0000 (22:12 -0500)]
setup.py: Mention Jinja and CherryPy as requirements

Unfortunately, none of the current Python installation tools
(easy_install, pip, others?) actaully use the `Requires` field that
this populates [1,2], and it's gone since PEP 345, replaced by
`Requires-Dist` [2,3,4].  Eventually a new packaging library
(distutils2, packaging, distlib, ...) will land in the Python standard
library and we can use whatever interface it provides for specifying
dependencies [5].

[1]: http://blog.doughellmann.com/2007/11/requiring-packages-with-distutils.html
[2]: http://ziade.org/2010/02/10/pep-345-and-386-accepted-summary-of-changes/
[3]: http://www.python.org/dev/peps/pep-0345/#requires-dist-multiple-use
[4]: http://www.python.org/dev/peps/pep-0426/#requires-dist-multiple-use
[5]: http://ncoghlan_devs-python-notes.readthedocs.org/en/latest/pep_ideas/core_packaging_api.html

6 years agostorage:util:upgrade: Strip any trailing space from the version
W. Trevor King [Thu, 24 Jan 2013 01:56:57 +0000 (20:56 -0500)]
storage:util:upgrade: Strip any trailing space from the version

Not just '\n'.  Mark Mikofski reported an error on the upgrade from
1.4 to 1.5 on MS Windows:
> upgrading bugdir from "Bugs Everywhere Directory v1.4" to "Bugs Everywhere Directory v1.5"
> Traceback (most recent call last):
>   ...
>   File "c:\...\libbe\storage\util\upgrade.py", line 141, in check_initial_version
>     assert version == self.initial_version, '%s: %s' % (path, version)
> AssertionError: c:\...\.be\version: Bugs Everywhere Directory v1.4
>
> **notes:** I set a breakpoint and it does seem that they are not the same
> (Pdb) self.initial_version
> 'Bugs Everywhere Directory v1.4'
> (Pdb) version
> u'Bugs Everywhere Directory v1.4\r'

We don't need to convert to Unicode, because on Python 2.7:

  $ python2.7 -c "print('a' == u'a')"
  True

Strange, but true ;).  One day we'll migrate BE to Python 3...

6 years agoupdate-copyright: Bump to version 0.5 (requires Python 3)
W. Trevor King [Thu, 24 Jan 2013 01:46:14 +0000 (20:46 -0500)]
update-copyright: Bump to version 0.5 (requires Python 3)

Upgrade to match our configuration file.

6 years agolibbe:command:util: fix bugdir access for complete_status and complete_severity
W. Trevor King [Thu, 13 Dec 2012 16:04:45 +0000 (11:04 -0500)]
libbe:command:util: fix bugdir access for complete_status and complete_severity

Fix a bug introduced by:

  commit 4db1a045a0606bead191a563abc54dfa8352efe0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Wed Aug 29 23:26:17 2012 -0400

    Rewrite commands to use bugdirs instead of a single bugdir.

Reported-by: James Spencer <james.s.spencer@gmail.com>
6 years agoui:util:pager: cleanup pager implementation
W. Trevor King [Fri, 30 Nov 2012 02:18:11 +0000 (21:18 -0500)]
ui:util:pager: cleanup pager implementation

Changes:

* Import libraries with an underscore prefix to avoid polluting the
  module's public namespace.
* Use a copy `env` to avoid messing with the child process'
  environment.
* Pass the tweaked environment on to the PAGER (e.g. for PATH).
* Handle PAGER='' (by not paging).
* Use shlex.split to handle cases like PAGER='less -FRSX' (thanks to
  Da_Blitz from pocketnix.org for the bug report and shlex idea).

6 years agoui:util:pager: document Nathan Weizenbaum as author of Ruby inspiration
W. Trevor King [Fri, 30 Nov 2012 01:07:07 +0000 (20:07 -0500)]
ui:util:pager: document Nathan Weizenbaum as author of Ruby inspiration

Nathan's post is released under CC BY-SA 3.0 Unported.  According the
the FSF, the CC BY-SA 2.0 Generic was not compatible with BE's GPLv2+
[1].  I expect my Python implementation is sufficiently different from
Nathan's original notes to be classified as "fair use" and not an
"adaptation".

[1]: http://www.gnu.org/licenses/license-list.html#ccbysa

6 years agorelease.py: use Python 2.7 for sphinx-build
W. Trevor King [Mon, 12 Nov 2012 18:07:44 +0000 (13:07 -0500)]
release.py: use Python 2.7 for sphinx-build

6 years agodoc:Makefile: use Python 2.7 for generate-libbe-txt.py
W. Trevor King [Mon, 12 Nov 2012 17:20:40 +0000 (12:20 -0500)]
doc:Makefile: use Python 2.7 for generate-libbe-txt.py

6 years agostorage:base: convert to Python 3.3 compatibility
W. Trevor King [Mon, 12 Nov 2012 17:18:50 +0000 (12:18 -0500)]
storage:base: convert to Python 3.3 compatibility

6 years agostorage: convert to Python 3 compatibility
W. Trevor King [Mon, 12 Nov 2012 17:18:43 +0000 (12:18 -0500)]
storage: convert to Python 3 compatibility

6 years agoversion: convert to Python 3 compatibility
W. Trevor King [Mon, 12 Nov 2012 17:18:32 +0000 (12:18 -0500)]
version: convert to Python 3 compatibility

6 years agotest: convert to Python 3 compatibility
W. Trevor King [Mon, 12 Nov 2012 17:18:23 +0000 (12:18 -0500)]
test: convert to Python 3 compatibility

6 years agorelease.py: build HTML docs when cutting releases
W. Trevor King [Mon, 12 Nov 2012 16:54:47 +0000 (11:54 -0500)]
release.py: build HTML docs when cutting releases

6 years agoutil:wsgi: handle all dispatch() exceptions in BEExceptionApp
W. Trevor King [Mon, 29 Oct 2012 00:20:27 +0000 (20:20 -0400)]
util:wsgi: handle all dispatch() exceptions in BEExceptionApp

This brings BEExceptionApp into closer agreement with
libbe.ui.command_line.dispatch(), and avoids having the server go down
when a user submits a silly command.

6 years agoutil:http: special handling for HTTP_USER_ERROR in get_post_url().
W. Trevor King [Mon, 29 Oct 2012 00:08:30 +0000 (20:08 -0400)]
util:http: special handling for HTTP_USER_ERROR in get_post_url().

6 years agoUse libbe.util.http.HTTP_USER_ERROR everywhere instead of hardcoding 418
W. Trevor King [Sun, 28 Oct 2012 23:59:41 +0000 (19:59 -0400)]
Use libbe.util.http.HTTP_USER_ERROR everywhere instead of hardcoding 418

6 years agoutil:wsgi: catch NoIDMatches in BEExceptionApp
W. Trevor King [Sun, 28 Oct 2012 23:00:32 +0000 (19:00 -0400)]
util:wsgi: catch NoIDMatches in BEExceptionApp

6 years agoutil:wsgi: add --daemon, --pidfile, and --logfile
W. Trevor King [Sat, 27 Oct 2012 23:46:41 +0000 (19:46 -0400)]
util:wsgi: add --daemon, --pidfile, and --logfile

This allows you to manage BE servers from inetd scripts, etc.
Shortcomings of the current implementation:

* ServerCommand._daemonize() currently only sets a SIGTERM handler and
  double forks.  If you want to do this right, see PEP 3143.
  Unfortunately, the PEP seems to have stalled, python-daemon appears
  unmaintained, and I don't care enough at the moment to do this
  right.

* ServerCommand._get_pidfile() races between checking for an existing
  PID file and claiming the file itself.  It is possible that two
  processes would check around the same time, and both see no existing
  file.  Then they would both open the PID file and write their pid,
  without noticing that the other process was contending for the file.
  Solving this requires file locking, which is difficult to do
  portably.  This shouldn't be an issue in normal operation, where
  each server will be using its own PID file path.

6 years agoutil:wsgi: fix From -> from typo in pyOpenSSL comment
W. Trevor King [Sat, 27 Oct 2012 20:16:50 +0000 (16:16 -0400)]
util:wsgi: fix From -> from typo in pyOpenSSL comment

6 years agoutil:wsgi: fix get_cert_filenames -> _get_cert_filenames typo
W. Trevor King [Sat, 27 Oct 2012 20:14:45 +0000 (16:14 -0400)]
util:wsgi: fix get_cert_filenames -> _get_cert_filenames typo

This was broken in the creation of libbe.util.wsgi from
libbe.command.serve:

  commit 0fa17f6bf6a809df14ae1930542059a9e62066b0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Mon Aug 27 13:37:58 2012 -0400

    libbe:util:wsgi: extract WSGI utilities into a separate module.

6 years agoutil:wsgi: import os.path for _get_cert_filenames()
W. Trevor King [Sat, 27 Oct 2012 20:11:57 +0000 (16:11 -0400)]
util:wsgi: import os.path for _get_cert_filenames()

This was lost in the creation of libbe.util.wsgi from
libbe.command.serve:

  commit 0fa17f6bf6a809df14ae1930542059a9e62066b0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Mon Aug 27 13:37:58 2012 -0400

    libbe:util:wsgi: extract WSGI utilities into a separate module.

6 years agodoc:install: CherryPy is *not* used for HTTP, only for HTTPS.
W. Trevor King [Sat, 27 Oct 2012 20:01:01 +0000 (16:01 -0400)]
doc:install: CherryPy is *not* used for HTTP, only for HTTPS.

For plain HTTP, we use wsgiref.simple_server from the stdlib.

Also include the `html` command as a WSGI-based command.

6 years agoutil:wsgi: fix Clossing -> Closing typo.
W. Trevor King [Sat, 27 Oct 2012 19:41:08 +0000 (15:41 -0400)]
util:wsgi: fix Clossing -> Closing typo.

6 years agoutil:wsgi: remove %default from option help strings
W. Trevor King [Sat, 27 Oct 2012 19:29:12 +0000 (15:29 -0400)]
util:wsgi: remove %default from option help strings

6 years agocommand:html: remove %default from option help strings
W. Trevor King [Sat, 27 Oct 2012 19:29:00 +0000 (15:29 -0400)]
command:html: remove %default from option help strings

6 years agoREADME: Update NumPy/SciPy doc link
W. Trevor King [Sat, 27 Oct 2012 16:39:47 +0000 (12:39 -0400)]
README: Update NumPy/SciPy doc link

6 years agoREADME: wrap doc/index.txt reference in backticks
W. Trevor King [Sat, 27 Oct 2012 16:38:55 +0000 (12:38 -0400)]
README: wrap doc/index.txt reference in backticks

File names, code, etc., should have special markup so they aren't
confused with regular text.

6 years agostorage:util:upgrade: use YAML parser to get BE Tree 1 0 settings
W. Trevor King [Sat, 27 Oct 2012 16:27:16 +0000 (12:27 -0400)]
storage:util:upgrade: use YAML parser to get BE Tree 1 0 settings

This fixes the "Bugs Everywhere Tree 1 0" -> "Bugs Everywhere
Directory v1.1" upgrade broken by the switch to JSON in:

  commit a95915c6c7d6a4e29c1e5547580e0c1fed2467e1
  Author: W. Trevor King <wking@tremily.us>
  Date:   Mon Sep 17 08:14:21 2012 -0400

    storage:util:mapfile: convert YAML settings to JSON.

6 years agomisc:completion:be.zsh: update import-xml --comment-root -> --root
W. Trevor King [Sat, 27 Oct 2012 15:51:05 +0000 (11:51 -0400)]
misc:completion:be.zsh: update import-xml --comment-root -> --root

This catches the script up with:

  commit 4db1a045a0606bead191a563abc54dfa8352efe0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Wed Aug 29 23:26:17 2012 -0400

    Rewrite commands to use bugdirs instead of a single bugdir.

6 years agotest_usage.sh: update import-xml --comment-root -> --root
W. Trevor King [Sat, 27 Oct 2012 15:49:19 +0000 (11:49 -0400)]
test_usage.sh: update import-xml --comment-root -> --root

This catches the tests up with:

  commit 4db1a045a0606bead191a563abc54dfa8352efe0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Wed Aug 29 23:26:17 2012 -0400

    Rewrite commands to use bugdirs instead of a single bugdir.

6 years agostorage:vcs:git: don't accept pygit2 version 0.17.3.
W. Trevor King [Sat, 27 Oct 2012 15:38:20 +0000 (11:38 -0400)]
storage:vcs:git: don't accept pygit2 version 0.17.3.

My Repository.revparse_single() series was merged into pygit2 with:

  Merge: 3e9daa4 0238fb7
  Author: J. David Ibáñez <jdavid.ibp@gmail.com>
  Date:   Tue Sep 25 15:10:55 2012 +0200

    Merge remote-tracking branch 'wking/revparse'

But this happened after the 0.17.3 release.  The next pygit2 release
should contain the .revparse_single() code.

The getattr() hackery works because versions of pygit2 before 0.17.3
lacked a __version__ attribute.

6 years agodoc:power: add Zsh completion location and update Bash install location
W. Trevor King [Sat, 27 Oct 2012 11:47:29 +0000 (07:47 -0400)]
doc:power: add Zsh completion location and update Bash install location

This puts both scripts in the right spot on Gentoo, and shows the
suggested installed filename (not just the suggested directory).

6 years agocommand:serve_*: remove wordy "with, for example" from help message
W. Trevor King [Sat, 27 Oct 2012 10:56:52 +0000 (06:56 -0400)]
command:serve_*: remove wordy "with, for example" from help message

6 years agocommand:serve_commands: fix --repo -> --server in help message
W. Trevor King [Sat, 27 Oct 2012 10:55:46 +0000 (06:55 -0400)]
command:serve_commands: fix --repo -> --server in help message

6 years agodoc:tutorial: use a Git tag for the `be diff` example
W. Trevor King [Fri, 26 Oct 2012 18:17:21 +0000 (14:17 -0400)]
doc:tutorial: use a Git tag for the `be diff` example

I haven't tagged 1.1.0 yet, but earlier tags do not use Bugs
Everywhere Directory v1.5, and we don't have on-the-fly storage
updates yet.

6 years agodoc:tutorial: fix ReST formatting for `be show --xml` example
W. Trevor King [Fri, 26 Oct 2012 17:52:53 +0000 (13:52 -0400)]
doc:tutorial: fix ReST formatting for `be show --xml` example

6 years agodoc:tutorial: move "you think" before quote in initialization section
W. Trevor King [Fri, 26 Oct 2012 17:46:11 +0000 (13:46 -0400)]
doc:tutorial: move "you think" before quote in initialization section

6 years agodoc:tutorial: fix ReST formatting for first `be comment` example
W. Trevor King [Fri, 26 Oct 2012 17:28:56 +0000 (13:28 -0400)]
doc:tutorial: fix ReST formatting for first `be comment` example

6 years agodoc:install: mention that we *do* post releases now
W. Trevor King [Fri, 26 Oct 2012 17:26:55 +0000 (13:26 -0400)]
doc:install: mention that we *do* post releases now

6 years agodoc:install: mention that PyYAML is now optional
W. Trevor King [Fri, 26 Oct 2012 17:26:18 +0000 (13:26 -0400)]
doc:install: mention that PyYAML is now optional

6 years agostorage:util:upgrade: make yaml import optional (unless it isn't)
W. Trevor King [Fri, 26 Oct 2012 17:18:21 +0000 (13:18 -0400)]
storage:util:upgrade: make yaml import optional (unless it isn't)

Importing `yaml` may fail (if the user doesn't have PyYAML installed),
but don't die until we need to use it.  This way users without the old
YAML formats on disk can run BE without installing PyYAML.

6 years agocommand: use mapfiles (JSON) instead of YAML for the command server
W. Trevor King [Fri, 26 Oct 2012 17:09:21 +0000 (13:09 -0400)]
command: use mapfiles (JSON) instead of YAML for the command server

6 years agostorage:util:mapfile: add `context` argument to generate()
W. Trevor King [Fri, 26 Oct 2012 17:08:54 +0000 (13:08 -0400)]
storage:util:mapfile: add `context` argument to generate()

6 years agodoc/install: fix paragraph indentation in man page installation discussion
W. Trevor King [Fri, 26 Oct 2012 16:52:29 +0000 (12:52 -0400)]
doc/install: fix paragraph indentation in man page installation discussion

6 years agodoc/install: point out relevant Debian bugs in a comment
W. Trevor King [Fri, 26 Oct 2012 16:50:27 +0000 (12:50 -0400)]
doc/install: point out relevant Debian bugs in a comment

6 years agodoc:install: fix dependency table ReST formatting
W. Trevor King [Fri, 26 Oct 2012 16:39:32 +0000 (12:39 -0400)]
doc:install: fix dependency table ReST formatting

The header had been broken by

  commit f174d8943c2edea25306ab522c27f69bbebd0be3
  Author: W. Trevor King <wking@tremily.us>
  Date:   Thu May 10 08:56:02 2012 -0400

    Update CherryPy dependency package to python-cherrypy3 on Debian.

6 years agodoc:index: mention that in-branch-bugs are not the only way
W. Trevor King [Fri, 26 Oct 2012 16:36:36 +0000 (12:36 -0400)]
doc:index: mention that in-branch-bugs are not the only way

6 years agodoc: clean up top level module docstrings
W. Trevor King [Fri, 26 Oct 2012 12:55:42 +0000 (08:55 -0400)]
doc: clean up top level module docstrings

6 years agolibbe:bugdir: avoid SimpleBugDir is not a item name
W. Trevor King [Fri, 26 Oct 2012 12:48:30 +0000 (08:48 -0400)]
libbe:bugdir: avoid SimpleBugDir is not a item name

This happens because SimpleBugDir is not defined if libbe.TESTING is
not set before importing libbe.bugdir.

6 years agodoc: update :attr: to :py:attr: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:43:04 +0000 (08:43 -0400)]
doc: update :attr: to :py:attr: for modern Sphinx.

6 years agodoc: update :data: to :py:data: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:42:14 +0000 (08:42 -0400)]
doc: update :data: to :py:data: for modern Sphinx.

6 years agodoc: update :meth: to :py:meth: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:41:21 +0000 (08:41 -0400)]
doc: update :meth: to :py:meth: for modern Sphinx.

6 years agodoc:config: use :file: to markup filenames.
W. Trevor King [Fri, 26 Oct 2012 12:40:09 +0000 (08:40 -0400)]
doc:config: use :file: to markup filenames.

6 years agodoc: update :class: to :py:class: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:37:54 +0000 (08:37 -0400)]
doc: update :class: to :py:class: for modern Sphinx.

6 years agostorage:vcs:base: avoid `is not a item name` Sphinx error.
W. Trevor King [Fri, 26 Oct 2012 12:36:09 +0000 (08:36 -0400)]
storage:vcs:base: avoid `is not a item name` Sphinx error.

6 years agodoc:conf: use `version (date)` in Sphinx docs
W. Trevor King [Fri, 26 Oct 2012 12:22:32 +0000 (08:22 -0400)]
doc:conf: use `version (date)` in Sphinx docs

Since

  commit bed7587fe4910f8e4b892a09675279c5a4ab5484
  Author: W. Trevor King <wking@tremily.us>
  Date:   Thu Oct 25 19:07:09 2012 -0400

    version: use abbreviated SHA instead of  explicit _VERSION in master branch

the version SHA will either be explicit in version(), or version()
will return a release tag.  This makes the long SHA in the Sphinx docs
unnecessary, so we can replace it with the more interesting commit
date.

6 years agodoc: update :mod: to :py:mod: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:13:13 +0000 (08:13 -0400)]
doc: update :mod: to :py:mod: for modern Sphinx.

6 years agodoc: update :func: to :py:func: for modern Sphinx.
W. Trevor King [Fri, 26 Oct 2012 12:12:08 +0000 (08:12 -0400)]
doc: update :func: to :py:func: for modern Sphinx.

6 years agostorage:util:config: path() now defaults to ~/.config/bugs-everywhere
W. Trevor King [Fri, 26 Oct 2012 12:00:31 +0000 (08:00 -0400)]
storage:util:config: path() now defaults to ~/.config/bugs-everywhere

Add a documentation section discussing the config file, respect
XDG_CONFIG_HOME, and add BE_CONFIG_PATH.

6 years agorelease.py: strip trailing whitespace from ChangeLog.
W. Trevor King [Fri, 26 Oct 2012 02:40:49 +0000 (22:40 -0400)]
release.py: strip trailing whitespace from ChangeLog.

6 years agorelease.py: sign tags when cutting releases.
W. Trevor King [Thu, 25 Oct 2012 23:46:13 +0000 (19:46 -0400)]
release.py: sign tags when cutting releases.

6 years agorelease.py: use current Python executable for ./be invocation
W. Trevor King [Thu, 25 Oct 2012 23:37:37 +0000 (19:37 -0400)]
release.py: use current Python executable for ./be invocation

This allow you to cut a release where your system Python is not
compatible with be.  For example:

  $ python --version
  Python 3.2.3
  $ python2.7 ./release.py 1.1.0

6 years agosetup.py: flesh out setup in preparation for PyPI posting
W. Trevor King [Thu, 25 Oct 2012 23:34:06 +0000 (19:34 -0400)]
setup.py: flesh out setup in preparation for PyPI posting

6 years agosetup.py: change setup.py name to something more PyPI friendly.
W. Trevor King [Thu, 25 Oct 2012 23:13:47 +0000 (19:13 -0400)]
setup.py: change setup.py name to something more PyPI friendly.

6 years agosetup.py: don't put the date in the setup.py version (PyPI gets mad).
W. Trevor King [Thu, 25 Oct 2012 23:11:19 +0000 (19:11 -0400)]
setup.py: don't put the date in the setup.py version (PyPI gets mad).

6 years agoversion: use abbreviated SHA instead of explicit _VERSION in master branch
W. Trevor King [Thu, 25 Oct 2012 23:07:09 +0000 (19:07 -0400)]
version: use abbreviated SHA instead of  explicit _VERSION in master branch

Only official releases get a version number, which should help avoid
confusion.  If you're running a live checkout, you shouldn't be scared
off by SHAs.

6 years agorelease.py: pull main code into main().
W. Trevor King [Thu, 25 Oct 2012 22:44:22 +0000 (18:44 -0400)]
release.py: pull main code into main().

6 years agoupdate-copyright: update to the python3 branch.
W. Trevor King [Thu, 25 Oct 2012 21:57:39 +0000 (17:57 -0400)]
update-copyright: update to the python3 branch.

6 years agorelease.py: remove dependency on deprecated libbe.subproc.Pipe
W. Trevor King [Thu, 25 Oct 2012 20:56:03 +0000 (16:56 -0400)]
release.py: remove dependency on deprecated libbe.subproc.Pipe

Pipe has been gone since:

  commit f1ae4b7f3fea6fb78a54ee5073aee648a3d73179
  Author: W. Trevor King <wking@drexel.edu>
  Date:   Sat Feb 25 11:16:01 2012 -0500

    Remove util.subproc.Pipe, as we no longer use it in BE.

6 years agointerfaces:web:web: use bugdir_bug_comment_from_user_id() in CFBE.
W. Trevor King [Thu, 25 Oct 2012 12:19:42 +0000 (08:19 -0400)]
interfaces:web:web: use bugdir_bug_comment_from_user_id() in CFBE.

This gets CFBE working with:

  commit 4db1a045a0606bead191a563abc54dfa8352efe0
  Author: W. Trevor King <wking@tremily.us>
  Date:   Wed Aug 29 23:26:17 2012 -0400

    Rewrite commands to use bugdirs instead of a single bugdir.

I'm not sure how much work it would take to rewrite CFBE to use
multiple bugdirs.

6 years agobugdir|bug|comment: update default settings string to be value JSON.
W. Trevor King [Thu, 25 Oct 2012 12:12:59 +0000 (08:12 -0400)]
bugdir|bug|comment: update default settings string to be value JSON.

6 years agostorage:util:mapfile: fix YAML -> JSON in docstrings.
W. Trevor King [Thu, 25 Oct 2012 12:03:30 +0000 (08:03 -0400)]
storage:util:mapfile: fix YAML -> JSON in docstrings.

This should have been done back in:

  commit a95915c6c7d6a4e29c1e5547580e0c1fed2467e1
  Author: W. Trevor King <wking@tremily.us>
  Date:   Mon Sep 17 08:14:21 2012 -0400

    storage:util:mapfile: convert YAML settings to JSON.

I also add an empty-settings generation as a sanity check.

6 years agosetup.py: make libbe._version optional.
W. Trevor King [Thu, 25 Oct 2012 11:00:42 +0000 (07:00 -0400)]
setup.py: make libbe._version optional.

Thanks to Timmie for pointing this out:

From: Timmie <timmichelsen@gmx-topmail.de>
Date: Thu, 25 Oct 2012 09:42:23 +0000 (UTC)
Subject: Re: [Be-devel] NotImplementedError with Bazaar

...
I notices the following glichtes during the install:

D:\be-be-master\be-be>python setup.py install
WARNING:root:unable to import libbe._version: No module named _version
Traceback (most recent call last):
  File "setup.py", line 6, in <module>
    from libbe import _version, version
ImportError: cannot import name _version
...

6 years ago.update-copyright.conf: update to pipe separators.
W. Trevor King [Sat, 20 Oct 2012 11:18:40 +0000 (07:18 -0400)]
.update-copyright.conf: update to pipe separators.

This brings the config file up to speed with the following
update-copyright commit:

  commit 3c68a1a48419d8b2bbc2ce0e7f1700b996ec30e9
  Author: W. Trevor King <wking@tremily.us>
  Date:   Fri Oct 19 21:52:48 2012 -0400

    project: for consistency, also separate ignored paths with pipes

6 years agoRan update-copyright.py.
W. Trevor King [Tue, 16 Oct 2012 14:58:37 +0000 (10:58 -0400)]
Ran update-copyright.py.

6 years ago.mailmap: consilidate Niall Douglas' addresses.
W. Trevor King [Tue, 16 Oct 2012 14:54:58 +0000 (10:54 -0400)]
.mailmap: consilidate Niall Douglas' addresses.

6 years agoupdate-copyright: update to current update-copyright (v0.4+).
W. Trevor King [Tue, 16 Oct 2012 14:36:53 +0000 (10:36 -0400)]
update-copyright: update to current update-copyright (v0.4+).

7 years agodoc:tutorial: fix typos in the attachment examples.
Nicolas Bigaouette [Wed, 19 Sep 2012 15:12:37 +0000 (11:12 -0400)]
doc:tutorial: fix typos in the attachment examples.

I wrote the actual patch, but Nicolas gave pretty unambiguous
directions, so I'm making him the author.

On Wed, Sep 19, 2012 at 11:03:39AM -0400, Nicolas Bigaouette wrote:
> Hi all,
>
> I'm trying out Bugs Everywhere, pretty neat!
>
> Reading the documentation, I see it's possible to add attachment to the bug
> report. The "commenting on bugs" section of the tutorial[1] gives the
> command for the attachment:
>
> > $ cat screenshot.png | be comment --content-type image/png bea/28f
> >
> or the following to reply to a specific comment:
>
> > $ be comment bea/28f “Whosit dissapears when you mouse-over whatsit.”
> > $ cat screenshot.png | be comment --content-type image/png bea/28f/41d
> >
>
> Both these commands fail as they will try to open the editor for entering
> the comment.
>
> The fix is simply to append a single dash "-" at the end of the attachment
> command to tell "be comment" to read the comment from stdin (see "be help
> comment").
>
> Also, the second example has not the same formatting as the first one. The
> first one seems to have a "code" formatting, while the second is just
> indented without any line breaks.
>
> Thanks!
>
> Nicolas
>
> [1] http://docs.bugseverywhere.org/tutorial.html#commenting-on-bugs

7 years agostorage:vcs:git: check for existence of pygit2.__version__.
W. Trevor King [Mon, 17 Sep 2012 15:13:36 +0000 (11:13 -0400)]
storage:vcs:git: check for existence of pygit2.__version__.

Now that my pull request has been accepted, we can be fairly confident
that future releases of pygit2 will expose this attribute.  The
accepted patch was a bit different from the original submission:

Add 'pygit2.__version__' for easy access from client software.
  https://github.com/libgit2/pygit2/pull/128
  commit f10d2b7b3f0c67d81b175326035e4813420156bd

7 years agocommand:html: convert -moz-border-radius to border-radius.
W. Trevor King [Mon, 17 Sep 2012 13:35:10 +0000 (09:35 -0400)]
command:html: convert -moz-border-radius to border-radius.

border-radius and friends are standard CSS3 [1].

[1]: http://www.w3.org/TR/css3-background/#the-border-radius

7 years agocommand.html: display "Target:" detail for bugs with targets.
W. Trevor King [Mon, 17 Sep 2012 13:25:07 +0000 (09:25 -0400)]
command.html: display "Target:" detail for bugs with targets.

7 years agocommand:html: fix two auto% -> auto typos in CSS.
W. Trevor King [Mon, 17 Sep 2012 13:21:18 +0000 (09:21 -0400)]
command:html: fix two auto% -> auto typos in CSS.

These were introduced in

  commit d61d54ce33022f0613c5e19e2f52be4ab77c4664
  Author: Gianluca Montecchi <gian@grys.it>
  Date:   Mon Jan 24 22:47:32 2011 +0100

    New html output for html command

and propogated in

  commit 5b6be7a511670cdf1961d13040cddcb34e70b8a1
  Author: W. Trevor King <wking@drexel.edu>
  Date:   Sun Apr 17 02:41:07 2011 -0400

    Rework `be html` to use Jinja2 templates.

7 years agobea864: upgrade to Bugs Everywhere Directory v1.5 (YAML -> JSON).
W. Trevor King [Mon, 17 Sep 2012 13:01:20 +0000 (09:01 -0400)]
bea864: upgrade to Bugs Everywhere Directory v1.5 (YAML -> JSON).

7 years agostorage:util:mapfile: convert YAML settings to JSON.
W. Trevor King [Mon, 17 Sep 2012 12:14:21 +0000 (08:14 -0400)]
storage:util:mapfile: convert YAML settings to JSON.

This is faster and still readable.  I also add an upgrader to convert
bug directories from:
  Bugs Everywhere Directory v1.4
to:
  Bugs Everywhere Directory v1.5
but I haven't upgraded the local bugdir yet.

7 years agostorage:vcs:git: move Git to ExecGit and add PygitGit using pygit2.
W. Trevor King [Thu, 13 Sep 2012 23:07:59 +0000 (19:07 -0400)]
storage:vcs:git: move Git to ExecGit and add PygitGit using pygit2.

If `pygit2` is installed, use it (via PygitGit) rather than calling
the stand-alone `git` executable for all the Git (via ExecGit) for all
the Git storage stuff.  This saves one serializing/deserializing and
process setup/teardown.  I timed each test suite by commenting out one
of the `make_vcs_testcase_subclasses()` calls at the end of `git.py`
and running

  $ time python test.py libbe.storage.vcs.git

The ExecGit tests ran in 13.7s and the PygitGit tests ran in 3.6s for
a 3.8x speedup.

I had to stretch pygit2 a bit to get a clean fit, so if you want to
test this, you'll need to build pygit2 with the following merge
requests:

  Add 'pygit2.__version__' for easy access from client software.
    https://github.com/libgit2/pygit2/pull/128
    commit 0238fb72dfdf2a2308f2da347717cbaafddc4b83
  signature: Add keyword argument parsing to Signature().
    https://github.com/libgit2/pygit2/pull/129
    commit c934858b629f40221406f34166dd77e881b9d5fd
  repository: add Repository.revparse_single()
    https://github.com/libgit2/pygit2/pull/131
    commit 3afdc8b2f59ed137531671fedde36f3a39cbcc9d

7 years agostorage:vcs:base: fix _gets_ -> _get_ typo in test_gets_existing_user_id.
W. Trevor King [Thu, 13 Sep 2012 16:08:10 +0000 (12:08 -0400)]
storage:vcs:base: fix _gets_ -> _get_ typo in test_gets_existing_user_id.

VCS_get_user_id_TestCase.test_gets_existing_user_id is now
VCS_get_user_id_TestCase.test_get_existing_user_id