         @nextPromise
 
     startTailing: ->
+        if @taskHistory.get('task').isStopped
+            @stopTailing()
+            return
+
         @parent.$el.addClass('tailing')
 
         if @tailing is null

    render: ->
        @$el.addClass 'loading'

        # seek to the end of the file
        @lines.fetchEndOffset().then (offset) =>
            @handleEmpty(offset)
            @tail Math.max(0, offset - @readLength)

        @


View = require './view'

TaskHistory = require '../models/TaskHistory'
LogLines = require '../collections/LogLines'

class TailerView extends Backbone.View
