Merge lp:~gertburger/ibid/source_loading into lp:ibid

Proposed by Gert Burger
Status: Merged
Approved by: Stefano Rivera
Approved revision: 1057
Merged at revision: 1058
Proposed branch: lp:~gertburger/ibid/source_loading
Merge into: lp:ibid
Diff against target: 24 lines (+14/-0)
1 file modified
ibid/source/__init__.py (+14/-0)
To merge this branch: bzr merge lp:~gertburger/ibid/source_loading
Reviewer Review Type Date Requested Status
Stefano Rivera Approve
Review via email: mp+145058@code.launchpad.net

Commit message

Allow out of tree plugins in the ibid.source module, like ibid.plugins

To post a comment you must log in.
Revision history for this message
Stefano Rivera (stefanor) wrote :

Looks like it works. Thanks!

review: Approve
Revision history for this message
Ibid Branch Auto-Lander (ibid-tarmac) wrote :
Download full text (15.6 KiB)

The attempt to merge lp:~gertburger/ibid/source_loading into lp:ibid failed. Below is the output from the failed tests.

ibid.test.plugins.test_calc
  CalcTest
    test_basic ... [SKIPPED]
    test_too_big ... [SKIPPED]
ibid.test.plugins.test_conversions
  CurrencyConversionTest
    test_conversion ... [SKIPPED]
  CurrencyLookupTest
    test_common_currencies ... [ERROR]
    test_country ... [ERROR]
    test_country_association ... [ERROR]
    test_fallthrough ... [ERROR]
    test_tld ... [ERROR]
  UnihanTest
    test_simp_trad ... [SKIPPED]
ibid.test.plugins.test_core
  TestAddressed
    test_happy_prefix_names ... [OK]
    test_happy_suffix_names ... [OK]
    test_non_messages ... [OK]
    test_sad_prefix_names ... [OK]
    test_sad_suffix_names ... [OK]
    test_strip_punct ... [OK]
ibid.test.plugins.test_factoid
  FactoidTest
    test_also ... [SKIPPED]
    test_append ... [SKIPPED]
    test_duplicate_names ... [SKIPPED]
    test_empty ... [SKIPPED]
    test_forget_multiple ... [SKIPPED]
    test_forget_wildcard ... [SKIPPED]
    test_get_case ... [SKIPPED]
    test_modify_nothing ... [SKIPPED]
    test_multiple_copula ... [SKIPPED]
    test_name_punctuation ... [SKIPPED]
    test_same_as_nothing ... [SKIPPED]
    test_search_case ... [SKIPPED]
    test_search_unescape ... [SKIPPED]
    test_string_replace ... [SKIPPED]
    test_string_transliterate ... [SKIPPED]
    test_unicode_name ... [SKIPPED]
    test_wildcard_tamecard ... [SKIPPED]
ibid.test.plugins.test_google
  GDefineTest
    test_basic ... [SKIPPED]
    test_unicode_latin ... [SKIPPED]
ibid.test.plugins.test_url
  TestURLGrabber
    test_bad_grabs ... ...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ibid/source/__init__.py'
2--- ibid/source/__init__.py 2010-01-18 22:53:52 +0000
3+++ ibid/source/__init__.py 2013-01-26 10:46:24 +0000
4@@ -3,6 +3,20 @@
5
6 from copy import copy
7
8+try:
9+ from twisted.plugin import pluginPackagePaths
10+except ImportError:
11+ # Not available in Twisted 2.5.0 in Ubuntu hardy
12+ # This is straight from twisted.plugin
13+ import os.path
14+ import sys
15+ def pluginPackagePaths(name):
16+ package = name.split('.')
17+ return [os.path.abspath(os.path.join(x, *package)) for x in sys.path
18+ if not os.path.exists(os.path.join(x, *package + ['__init__.py']))]
19+
20+__path__ = pluginPackagePaths(__name__) + __path__
21+
22 class IbidSourceFactory(object):
23
24 supports = ()

Subscribers

People subscribed via source and target branches

to all changes: