~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/ui/__init__.py

  • Committer: Martin Pool
  • Date: 2010-02-23 07:43:11 UTC
  • mfrom: (4797.2.20 2.1)
  • mto: This revision was merged to the branch mainline in revision 5055.
  • Revision ID: mbp@sourcefrog.net-20100223074311-gnj55xdhrgz9l94e
Merge 2.1 back to trunk

Show diffs side-by-side

added added

removed removed

Lines of Context:
183
183
        if not self._task_stack:
184
184
            warnings.warn("%r finished but nothing is active"
185
185
                % (task,))
186
 
        elif task != self._task_stack[-1]:
187
 
            warnings.warn("%r is not the active task %r"
188
 
                % (task, self._task_stack[-1]))
 
186
        if task in self._task_stack:
 
187
            self._task_stack.remove(task)
189
188
        else:
190
 
            del self._task_stack[-1]
 
189
            warnings.warn("%r is not in active stack %r"
 
190
                % (task, self._task_stack))
191
191
        if not self._task_stack:
192
192
            self._progress_all_finished()
193
193
 
295
295
            "same format for better performance.\n" %
296
296
            (from_format, to_format))
297
297
 
 
298
    def warn_experimental_format_fetch(self, inter):
 
299
        """Warn about fetching into experimental repository formats."""
 
300
        if inter.target._format.experimental:
 
301
            trace.warning("Fetching into experimental format %s.\n"
 
302
                "This format may be unreliable or change in the future "
 
303
                "without an upgrade path.\n" % (inter.target._format,))
 
304
 
 
305
 
298
306
 
299
307
class SilentUIFactory(UIFactory):
300
308
    """A UI Factory which never prints anything.