Merge pull request #423 from oasis-open/fix-six-version

Fix six version
pull/1/head
Chris Lenk 2020-07-07 09:32:53 -04:00 committed by GitHub
commit 2fff3a6d45
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 4 additions and 6 deletions

View File

@ -1,6 +1,5 @@
[settings] [settings]
skip = workbench.py skip = workbench.py
not_skip = __init__.py
known_third_party = known_third_party =
antlr4, antlr4,
dateutil, dateutil,

View File

@ -51,7 +51,7 @@ setup(
'pytz', 'pytz',
'requests', 'requests',
'simplejson', 'simplejson',
'six', 'six>=1.13.0',
'stix2-patterns', 'stix2-patterns',
], ],
project_urls={ project_urls={

View File

@ -1,5 +1,4 @@
"""Python STIX2 Environment API.""" """Python STIX2 Environment API."""
import copy import copy
import logging import logging
import time import time
@ -463,7 +462,7 @@ def partial_location_distance(lat1, long1, lat2, long2, threshold):
float: Number between 0.0 and 1.0 depending on match. float: Number between 0.0 and 1.0 depending on match.
""" """
from haversine import haversine, Unit from haversine import Unit, haversine
distance = haversine((lat1, long1), (lat2, long2), unit=Unit.KILOMETERS) distance = haversine((lat1, long1), (lat2, long2), unit=Unit.KILOMETERS)
result = 1 - (distance / threshold) result = 1 - (distance / threshold)
logger.debug( logger.debug(

View File

@ -30,8 +30,8 @@ max-line-length = 160
[testenv:isort-check] [testenv:isort-check]
deps = isort deps = isort
commands = commands =
isort -rc stix2 examples -df isort stix2 examples --df
isort -rc stix2 examples -c isort stix2 examples -c
[testenv:packaging] [testenv:packaging]
deps = deps =