aboutsummaryrefslogtreecommitdiffstats
path: root/fatcat_scholar
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@archive.org>2021-10-27 14:39:27 -0700
committerBryan Newbold <bnewbold@archive.org>2021-10-27 18:25:58 -0700
commit4362e60383bef09d5989830b19ae2d5dec506620 (patch)
tree3d1d51b6fa88084ce64895ec92c821d7a3d81844 /fatcat_scholar
parentb4d0bfb643842e6070a4ee36cfc52e2292e3b5ba (diff)
downloadfatcat-scholar-4362e60383bef09d5989830b19ae2d5dec506620.tar.gz
fatcat-scholar-4362e60383bef09d5989830b19ae2d5dec506620.zip
lint: remove all 'import *' uses
Diffstat (limited to 'fatcat_scholar')
-rw-r--r--fatcat_scholar/search.py2
-rw-r--r--fatcat_scholar/transform.py22
-rw-r--r--fatcat_scholar/work_pipeline.py2
3 files changed, 22 insertions, 4 deletions
diff --git a/fatcat_scholar/search.py b/fatcat_scholar/search.py
index 7bb7424..5c7aba0 100644
--- a/fatcat_scholar/search.py
+++ b/fatcat_scholar/search.py
@@ -18,7 +18,7 @@ from elasticsearch_dsl.response import Response
from pydantic import BaseModel
from fatcat_scholar.config import settings
-from fatcat_scholar.identifiers import *
+from fatcat_scholar.identifiers import clean_doi, clean_pmcid
from fatcat_scholar.query_citation import try_fuzzy_match
from fatcat_scholar.query_parse import pre_parse_query, sniff_citation_query
from fatcat_scholar.schema import ScholarDoc
diff --git a/fatcat_scholar/transform.py b/fatcat_scholar/transform.py
index db631cf..3213b8d 100644
--- a/fatcat_scholar/transform.py
+++ b/fatcat_scholar/transform.py
@@ -1,5 +1,6 @@
import argparse
import datetime
+import json
import sys
import xml.etree.ElementTree
import xml.etree.ElementTree as ET
@@ -8,11 +9,28 @@ from typing import Any, Dict, List, Optional, Sequence
import sentry_sdk
from fatcat_openapi_client import FileEntity, ReleaseEntity, WebcaptureEntity
-from fatcat_scholar.api_entities import *
from fatcat_scholar.config import GIT_REVISION, settings
from fatcat_scholar.grobid2json import teixml2json
from fatcat_scholar.identifiers import clean_doi, clean_pmcid
-from fatcat_scholar.schema import *
+from fatcat_scholar.schema import (
+ AccessType,
+ DocType,
+ IntermediateBundle,
+ RefBiblio,
+ RefStructured,
+ ScholarAbstract,
+ ScholarAccess,
+ ScholarBiblio,
+ ScholarDoc,
+ ScholarFulltext,
+ ScholarSim,
+ clean_small_int,
+ clean_url_conservative,
+ es_abstracts_from_grobid,
+ es_abstracts_from_release,
+ es_biblio_from_release,
+ es_release_from_release,
+)
MAX_BODY_CHARS = 512 * 1024
diff --git a/fatcat_scholar/work_pipeline.py b/fatcat_scholar/work_pipeline.py
index 92b0943..191e898 100644
--- a/fatcat_scholar/work_pipeline.py
+++ b/fatcat_scholar/work_pipeline.py
@@ -11,7 +11,7 @@ import sentry_sdk
import urllib3.exceptions
from fatcat_openapi_client import FileEntity, ReleaseEntity, WebcaptureEntity
-from fatcat_scholar.api_entities import *
+from fatcat_scholar.api_entities import entity_from_json
from fatcat_scholar.config import GIT_REVISION, settings
from fatcat_scholar.djvu import djvu_extract_leaf_texts
from fatcat_scholar.issue_db import IssueDB, SimIssueRow, SimPubRow