~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/__init__.py

  • Committer: Robey Pointer
  • Date: 2006-07-01 19:03:33 UTC
  • mfrom: (1829 +trunk)
  • mto: This revision was merged to the branch mainline in revision 1830.
  • Revision ID: robey@lag.net-20060701190333-f58465aec4bd3412
merge from bzr.dev

Show diffs side-by-side

added added

removed removed

Lines of Context:
30
30
from collections import deque
31
31
from copy import deepcopy
32
32
import re
33
 
from stat import *
 
33
from stat import S_ISDIR
34
34
import sys
35
35
from unittest import TestSuite
36
36
import urllib
37
37
import urlparse
 
38
import warnings
38
39
 
39
40
import bzrlib
40
41
import bzrlib.errors as errors
41
42
from bzrlib.errors import DependencyNotPresent
42
43
import bzrlib.osutils as osutils
43
44
from bzrlib.osutils import pumpfile
44
 
from bzrlib.symbol_versioning import *
 
45
from bzrlib.symbol_versioning import (deprecated_passed, deprecated_method, deprecated_function, 
 
46
        DEPRECATED_PARAMETER,
 
47
        zero_eight)
45
48
from bzrlib.trace import mutter, warning
46
49
import bzrlib.urlutils as urlutils
47
50
 
63
66
    # working, etc.
64
67
    global _protocol_handlers
65
68
    if deprecated_passed(override):
66
 
        warn("register_transport(override) is deprecated")
 
69
        warnings.warn("register_transport(override) is deprecated")
67
70
    _protocol_handlers.setdefault(prefix, []).insert(0, klass)
68
71
 
69
72
 
703
706
            raise errors.InvalidURL(base, error_str % m.group('proto'))
704
707
        # This doesn't look like a protocol, consider it a local path
705
708
        new_base = urlutils.local_path_to_url(base)
706
 
        mutter('converting os path %r => url %s' , base, new_base)
 
709
        mutter('converting os path %r => url %s', base, new_base)
707
710
        return new_base
708
711
 
709
712
    # Catch any URLs which are passing Unicode rather than ASCII