remove unused python token parser method
This commit is contained in:
parent
beca130634
commit
694205ebee
|
@ -1,5 +1,5 @@
|
||||||
[run]
|
[run]
|
||||||
branch = false
|
branch = true
|
||||||
omit =
|
omit =
|
||||||
wakatime/cli.py
|
wakatime/cli.py
|
||||||
wakatime/packages/*
|
wakatime/packages/*
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
|
|
||||||
|
|
||||||
import os, sys
|
import os, sys
|
||||||
import django
|
import django.forms.monstertruck
|
||||||
from app import *
|
from app import *
|
||||||
from flask import session
|
from flask import session
|
||||||
import simplejson as json
|
import simplejson as json
|
||||||
|
|
|
@ -49,9 +49,7 @@ class PythonParser(TokenParser):
|
||||||
self._process_import(token, content)
|
self._process_import(token, content)
|
||||||
|
|
||||||
def _process_operator(self, token, content):
|
def _process_operator(self, token, content):
|
||||||
if self.state is not None:
|
pass
|
||||||
if content == '.':
|
|
||||||
self.nonpackage = True
|
|
||||||
|
|
||||||
def _process_punctuation(self, token, content):
|
def _process_punctuation(self, token, content):
|
||||||
if content == '(':
|
if content == '(':
|
||||||
|
|
|
@ -234,7 +234,7 @@ def get_file_head(file_name):
|
||||||
except:
|
except:
|
||||||
try:
|
try:
|
||||||
with open(file_name, 'r', encoding=sys.getfilesystemencoding()) as fh:
|
with open(file_name, 'r', encoding=sys.getfilesystemencoding()) as fh:
|
||||||
text = fh.read(512000)
|
text = fh.read(512000) # pragma: nocover
|
||||||
except:
|
except:
|
||||||
log.traceback('debug')
|
log.traceback('debug')
|
||||||
return text
|
return text
|
||||||
|
|
Loading…
Reference in New Issue