1
0
mirror of https://github.com/QData/TextAttack.git synced 2021-10-13 00:05:06 +03:00

fix github flow and import issues

This commit is contained in:
Jin Yong Yoo
2020-10-30 21:54:04 -04:00
parent dcce7b3434
commit 46ef3bcac5
4 changed files with 5 additions and 4 deletions

View File

@@ -28,7 +28,7 @@ jobs:
python -m pip install --upgrade pip setuptools wheel
pip install black flake8 isort # Testing packages
python setup.py install_egg_info # Workaround https://github.com/pypa/pip/issues/4537
pip install -e . ["dev"]
pip install -e .[dev]
- name: Check code format with black and isort
run: |
make lint

View File

@@ -29,7 +29,7 @@ jobs:
pip install pytest pytest-xdist # Testing packages
pip uninstall textattack --yes # Remove TA if it's already installed
python setup.py install_egg_info # Workaround https://github.com/pypa/pip/issues/4537
pip install -e . ["dev"]
pip install -e .[dev]
pip freeze
- name: Test with pytest
run: |

View File

@@ -17,3 +17,4 @@ tokenizers==0.8.1-rc2
tqdm
word2number
num2words
more-itertools

View File

@@ -1,4 +1,4 @@
import textattack
from .importing import LazyLoader
def has_letter(word):
@@ -202,7 +202,7 @@ def zip_flair_result(pred, tag_type="pos-fast"):
return word_list, pos_list
stanza = textattack.shared.utils.LazyLoader("stanza", globals(), "stanza")
stanza = LazyLoader("stanza", globals(), "stanza")
def zip_stanza_result(pred, tagset="universal"):