class_docstr: Plugin which implements the --lf (run last-failing) option 
class_docstr_tok: ["Plugin","which","implements","the","--","lf","(","run","last-failing",")","option"]
docstr: Ignore this file path if we are in --lf mode and it is not in the list of
  previously failed files.
docstr_tok: ["Ignore","this","file","path","if","we","are","in","--","lf","mode","and","it","is","not","in","the","list","of","previously","failed","files","."]
code: def pytest_ignore_collect(self, path):
      """
      Ignore this file path if we are in --lf mode and it is not in the list of
      previously failed files.
      """
      if self.active and self.config.getoption("lf") and path.isfile():
          last_failed_paths = self.last_failed_paths()
          if last_failed_paths:
              skip_it = Path(path) not in self.last_failed_paths()
              if skip_it:
                  self._skipped_files += 1
              return skip_it
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import json
  import os
  from collections import OrderedDict
  import attr
  import py
  import six
  import pytest
  from .compat import _PY2
  from .pathlib import Path
  from .pathlib import resolve_from_str
  from .pathlib import rm_rf
label_desc: Use image node_id 3 for calling the LFPlugin obj's underlying member method code with example usage: obj.pytest_ignore_collect(path) and returns: skip_it