~hopem/charms/trusty/keystone/fix-legacy-import-error

« back to all changes in this revision

Viewing changes to hooks/charmhelpers/fetch/archiveurl.py

  • Committer: Edward Hope-Morley
  • Date: 2015-02-16 13:35:14 UTC
  • mfrom: (117.1.3 keystone.strbools)
  • Revision ID: edward.hope-morley@canonical.com-20150216133514-byi9r8zk30a4ffz2
[hopem,r=gnuoy]

Synced charm-helpers to get core.strutils and replaced
str-to-bool logic with bool_from_string()

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
import hashlib
19
19
import re
20
20
 
 
21
from charmhelpers.fetch import (
 
22
    BaseFetchHandler,
 
23
    UnhandledSource
 
24
)
 
25
from charmhelpers.payload.archive import (
 
26
    get_archive_handler,
 
27
    extract,
 
28
)
 
29
from charmhelpers.core.host import mkdir, check_hash
 
30
 
21
31
import six
22
32
if six.PY3:
23
33
    from urllib.request import (
35
45
    )
36
46
    from urlparse import urlparse, urlunparse, parse_qs
37
47
 
38
 
from charmhelpers.fetch import (
39
 
    BaseFetchHandler,
40
 
    UnhandledSource
41
 
)
42
 
from charmhelpers.payload.archive import (
43
 
    get_archive_handler,
44
 
    extract,
45
 
)
46
 
from charmhelpers.core.host import mkdir, check_hash
47
 
 
48
48
 
49
49
def splituser(host):
50
50
    '''urllib.splituser(), but six's support of this seems broken'''