~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/codehosting/vfs/transport.py

  • Committer: Launchpad Patch Queue Manager
  • Date: 2011-07-18 20:55:27 UTC
  • mfrom: (13463.2.1 revert-13420)
  • Revision ID: launchpad@pqm.canonical.com-20110718205527-gxsmcc8tn7d89swk
[r=wgrant][rollback=13420] Revert r13420 (the relanding of r13292,
 which broke production in similar ways).

Show diffs side-by-side

added added

removed removed

Lines of Context:
102
102
        """Return the absolute, escaped path to `relpath` without the schema.
103
103
        """
104
104
        return urlutils.joinpath(
105
 
            self.base[len(self.server.get_url()) - 1:], relpath)
 
105
            self.base[len(self.server.get_url())-1:], relpath)
106
106
 
107
107
    def _getUnderylingTransportAndPath(self, relpath):
108
108
        """Return the underlying transport and path for `relpath`."""
178
178
 
179
179
    def iter_files_recursive(self):
180
180
        deferred = self._getUnderylingTransportAndPath('.')
181
 
 
182
181
        @no_traceback_failures
183
182
        def iter_files((transport, path)):
184
183
            return transport.clone(path).iter_files_recursive()
187
186
 
188
187
    def listable(self):
189
188
        deferred = self._getUnderylingTransportAndPath('.')
190
 
 
191
189
        @no_traceback_failures
192
190
        def listable((transport, path)):
193
191
            return transport.listable()
429
427
            return
430
428
        self._is_started = False
431
429
        unregister_transport(self.get_url(), self._transportFactory)
432
 
 
433
 
    def __enter__(self):
434
 
        self.start_server()
435
 
        return self
436
 
 
437
 
    def __exit__(self, exc_type, exc_value, traceback):
438
 
        self.stop_server()