mirror of
https://github.com/ilri/csv-metadata-quality.git
synced 2025-05-11 15:46:03 +02:00
csv_metadata_quality: Move scoped imports to global
According to PEP8 we should avoid scoped imports unless you have a good reason. Here there are two cases where we do (issn and isbn), but I will move the others to the global scope.
This commit is contained in:
@ -1,7 +1,10 @@
|
||||
import re
|
||||
from unicodedata import normalize
|
||||
|
||||
import pandas as pd
|
||||
|
||||
from csv_metadata_quality.util import is_nfc
|
||||
|
||||
|
||||
def whitespace(field, field_name):
|
||||
"""Fix whitespace issues.
|
||||
@ -212,9 +215,6 @@ def normalize_unicode(field, field_name):
|
||||
Return normalized string.
|
||||
"""
|
||||
|
||||
from csv_metadata_quality.util import is_nfc
|
||||
from unicodedata import normalize
|
||||
|
||||
# Skip fields with missing values
|
||||
if pd.isna(field):
|
||||
return
|
||||
|
Reference in New Issue
Block a user