From b3126a8cfb50a992b3326190d4e6b9a02f18e1c5 Mon Sep 17 00:00:00 2001 From: Spiros Delviniotis Date: Thu, 4 May 2017 13:09:57 +0200 Subject: [PATCH] global: uniform __future__ imports * Adds: uniform `__future__` imports. * Adds: update copyright year. * Removes: unused imports Closes #103 Signed-off-by: Spiros Delviniotis --- INSTALL.rst | 2 +- LICENSE | 2 +- MANIFEST.in | 2 +- README.rst | 2 +- RELEASE-NOTES.rst | 2 +- docker-compose.deps.yml | 2 +- docker-compose.test.yml | 2 +- docs/Makefile | 11 ++++++++++- docs/api.rst | 2 +- docs/authors.rst | 2 +- docs/changes.rst | 2 +- docs/conf.py | 2 +- docs/contributing.rst | 2 +- docs/guide.rst | 2 +- docs/index.rst | 2 +- docs/installation.rst | 2 +- docs/license.rst | 2 +- docs/operations.rst | 2 +- docs/overview.rst | 2 +- docs/releasenotes.rst | 2 +- hepcrawl/__init__.py | 3 ++- hepcrawl/crawler2hep.py | 2 ++ hepcrawl/dateutils.py | 2 +- hepcrawl/extensions.py | 4 +++- hepcrawl/extractors/__init__.py | 4 +++- hepcrawl/extractors/jats.py | 4 ++-- hepcrawl/extractors/nlm.py | 4 ++-- hepcrawl/inputs.py | 5 +++-- hepcrawl/items.py | 4 +++- hepcrawl/loaders.py | 4 +++- hepcrawl/mappings.py | 3 ++- hepcrawl/middlewares.py | 3 ++- hepcrawl/outputs.py | 3 ++- hepcrawl/pipelines.py | 7 +++---- hepcrawl/settings.py | 4 +++- hepcrawl/spiders/__init__.py | 2 ++ hepcrawl/spiders/alpha_spider.py | 2 +- hepcrawl/spiders/aps_spider.py | 6 ++---- hepcrawl/spiders/arxiv_spider.py | 4 +++- hepcrawl/spiders/base_spider.py | 4 ++-- hepcrawl/spiders/brown_spider.py | 4 ++-- hepcrawl/spiders/dnb_spider.py | 4 ++-- hepcrawl/spiders/edp_spider.py | 5 +++-- hepcrawl/spiders/elsevier_spider.py | 4 ++-- hepcrawl/spiders/hindawi_spider.py | 4 ++-- hepcrawl/spiders/infn_spider.py | 4 ++-- hepcrawl/spiders/iop_spider.py | 4 ++-- hepcrawl/spiders/magic_spider.py | 4 ++-- hepcrawl/spiders/mit_spider.py | 4 ++-- hepcrawl/spiders/phenix_spider.py | 4 ++-- hepcrawl/spiders/phil_spider.py | 4 ++-- hepcrawl/spiders/pos_spider.py | 2 ++ hepcrawl/spiders/t2k_spider.py | 4 ++-- hepcrawl/spiders/wsp_spider.py | 2 +- hepcrawl/testlib/__init__.py | 2 +- hepcrawl/testlib/celery_monitor.py | 2 +- hepcrawl/testlib/scrapyd_coverage_runner.py | 1 + hepcrawl/testlib/tasks.py | 2 +- hepcrawl/utils.py | 2 +- hepcrawl/version.py | 4 ++-- setup.cfg | 2 +- setup.py | 2 ++ tests/Dockerfile.hepcrawl_base | 2 +- tests/functional/WSP/test_wsp.py | 2 +- tests/unit/test_alpha.py | 4 ++-- tests/unit/test_aps.py | 4 ++-- tests/unit/test_arxiv_all.py | 4 ++-- tests/unit/test_arxiv_single.py | 4 ++-- tests/unit/test_base.py | 4 ++-- tests/unit/test_brown.py | 4 ++-- tests/unit/test_dateutils.py | 4 ++-- tests/unit/test_dnb.py | 4 ++-- tests/unit/test_edp.py | 4 ++-- tests/unit/test_elsevier.py | 4 ++-- tests/unit/test_extensions.py | 4 ++-- tests/unit/test_hindawi.py | 4 ++-- tests/unit/test_infn.py | 4 ++-- tests/unit/test_inputs.py | 4 ++-- tests/unit/test_iop.py | 4 ++-- tests/unit/test_magic.py | 4 ++-- tests/unit/test_mit.py | 4 ++-- tests/unit/test_phenix.py | 4 ++-- tests/unit/test_phil.py | 4 ++-- tests/unit/test_pipelines.py | 4 ++-- tests/unit/test_pos.py | 4 ++-- tests/unit/test_t2k.py | 4 ++-- tests/unit/test_utils.py | 4 ++-- tests/unit/test_world_scientific.py | 4 ++-- 88 files changed, 163 insertions(+), 130 deletions(-) diff --git a/INSTALL.rst b/INSTALL.rst index dcf5fe23..aa7e24c9 100644 --- a/INSTALL.rst +++ b/INSTALL.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/LICENSE b/LICENSE index 77d7938c..a8be50a3 100644 --- a/LICENSE +++ b/LICENSE @@ -1,7 +1,7 @@ hepcrawl is free software; you can redistribute it and/or modify it under the terms of the Revised BSD License quoted below. -Copyright (c) 2015, 2016 CERN. +Copyright (c) 2015, 2016, 2017 CERN. All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/MANIFEST.in b/MANIFEST.in index f4333531..c67b27a6 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for diff --git a/README.rst b/README.rst index c81dc848..e1194a3d 100644 --- a/README.rst +++ b/README.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/RELEASE-NOTES.rst b/RELEASE-NOTES.rst index ebf4f18d..6f0e1900 100644 --- a/RELEASE-NOTES.rst +++ b/RELEASE-NOTES.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docker-compose.deps.yml b/docker-compose.deps.yml index 7127c491..711344cb 100644 --- a/docker-compose.deps.yml +++ b/docker-compose.deps.yml @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016, 2017 CERN. +# Copyright (C) 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for diff --git a/docker-compose.test.yml b/docker-compose.test.yml index 64836380..7103d032 100644 --- a/docker-compose.test.yml +++ b/docker-compose.test.yml @@ -33,7 +33,7 @@ services: unit: image: hepcrawl_base environment: *env_variables - command: bash -c "py.test tests/unit && sphinx-build -nNW docs docs/_build/html && python setup.py sdist && ls dist/*" + command: bash -c "py.test tests/unit -vv && sphinx-build -nNW docs docs/_build/html && python setup.py sdist && ls dist/*" volumes: *common_volumes doc: diff --git a/docs/Makefile b/docs/Makefile index a120544f..c04393cf 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -1,5 +1,14 @@ -# Makefile for Sphinx documentation +# -*- coding: utf-8 -*- +# +# This file is part of hepcrawl. +# Copyright (C) 2015, 2016, 2017 CERN. # +# hepcrawl is a free software; you can redistribute it and/or modify it +# under the terms of the Revised BSD License; see LICENSE file for +# more details. + +# Makefile for Sphinx documentation + # You can set these variables from the command line. SPHINXOPTS = diff --git a/docs/api.rst b/docs/api.rst index b29320dc..910af6c5 100644 --- a/docs/api.rst +++ b/docs/api.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2016 CERN. + Copyright (C) 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/authors.rst b/docs/authors.rst index 0f4b5a52..b479de24 100644 --- a/docs/authors.rst +++ b/docs/authors.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/changes.rst b/docs/changes.rst index 0c2d0037..aea73283 100644 --- a/docs/changes.rst +++ b/docs/changes.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/conf.py b/docs/conf.py index dca7fa12..5b90c001 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # HEPCrawl documentation build configuration file, created by -# sphinx-quickstart on Thu Jun 2 13:24:46 2016. +# sphinx-quickstart on Thu Jun 2 13:24:46 2016 - 2017. # # This file is execfile()d with the current directory set to its # containing dir. diff --git a/docs/contributing.rst b/docs/contributing.rst index 9818d758..460bce01 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/guide.rst b/docs/guide.rst index 71a16b44..826e661b 100644 --- a/docs/guide.rst +++ b/docs/guide.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/index.rst b/docs/index.rst index 3ff43245..3703f232 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/installation.rst b/docs/installation.rst index 7ca4caac..528d57ea 100644 --- a/docs/installation.rst +++ b/docs/installation.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2016 CERN. + Copyright (C) 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/license.rst b/docs/license.rst index c6120ef3..ba024793 100644 --- a/docs/license.rst +++ b/docs/license.rst @@ -3,7 +3,7 @@ License hepcrawl is free software; you can redistribute it and/or modify it under the terms of the Revised BSD License quoted below. -Copyright (c) 2015, 2016 CERN. +Copyright (c) 2015, 2016, 2017 CERN. All rights reserved. Redistribution and use in source and binary forms, with or without diff --git a/docs/operations.rst b/docs/operations.rst index 31f71246..b2e653d4 100644 --- a/docs/operations.rst +++ b/docs/operations.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2016 CERN. + Copyright (C) 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/overview.rst b/docs/overview.rst index f9b5b4c5..1cdabbbf 100644 --- a/docs/overview.rst +++ b/docs/overview.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/docs/releasenotes.rst b/docs/releasenotes.rst index 2add05fa..07f8855b 100644 --- a/docs/releasenotes.rst +++ b/docs/releasenotes.rst @@ -1,6 +1,6 @@ .. This file is part of hepcrawl. - Copyright (C) 2015, 2016 CERN. + Copyright (C) 2015, 2016, 2017 CERN. hepcrawl is a free software; you can redistribute it and/or modify it under the terms of the Revised BSD License; see LICENSE file for diff --git a/hepcrawl/__init__.py b/hepcrawl/__init__.py index 82cf1c26..2da4a152 100644 --- a/hepcrawl/__init__.py +++ b/hepcrawl/__init__.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,7 @@ """Call a crawler from Python.""" +from __future__ import absolute_import, division, print_function from scrapy.crawler import CrawlerProcess from scrapy.utils.project import get_project_settings diff --git a/hepcrawl/crawler2hep.py b/hepcrawl/crawler2hep.py index 9322cbff..0f073f65 100644 --- a/hepcrawl/crawler2hep.py +++ b/hepcrawl/crawler2hep.py @@ -13,6 +13,8 @@ See: http://doc.scrapy.org/en/latest/topics/item-pipeline.html """ +from __future__ import absolute_import, division, print_function + from inspire_schemas.api import LiteratureBuilder diff --git a/hepcrawl/dateutils.py b/hepcrawl/dateutils.py index 7f49e8a5..0b180c7b 100644 --- a/hepcrawl/dateutils.py +++ b/hepcrawl/dateutils.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for diff --git a/hepcrawl/extensions.py b/hepcrawl/extensions.py index b30b54a4..0b1b426c 100644 --- a/hepcrawl/extensions.py +++ b/hepcrawl/extensions.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,8 @@ """Define extensions here.""" +from __future__ import absolute_import, division, print_function + from scrapy import signals diff --git a/hepcrawl/extractors/__init__.py b/hepcrawl/extractors/__init__.py index 6f312df7..0f16bf56 100644 --- a/hepcrawl/extractors/__init__.py +++ b/hepcrawl/extractors/__init__.py @@ -1,10 +1,12 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. """Contains common extractor mixins for use in spiders.""" + +from __future__ import absolute_import, division, print_function diff --git a/hepcrawl/extractors/jats.py b/hepcrawl/extractors/jats.py index dfe3a1d6..0c9d85a7 100644 --- a/hepcrawl/extractors/jats.py +++ b/hepcrawl/extractors/jats.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Common extraction from the JATS XML format.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import datetime diff --git a/hepcrawl/extractors/nlm.py b/hepcrawl/extractors/nlm.py index 69dc6340..f86fbbe9 100644 --- a/hepcrawl/extractors/nlm.py +++ b/hepcrawl/extractors/nlm.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Common extraction from the NLM XML format.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function class NLM(object): diff --git a/hepcrawl/inputs.py b/hepcrawl/inputs.py index 23958b5e..9ab7e78c 100644 --- a/hepcrawl/inputs.py +++ b/hepcrawl/inputs.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,8 @@ """Define your input and output processors here.""" -import datetime +from __future__ import absolute_import, division, print_function + import re from w3lib.html import ( diff --git a/hepcrawl/items.py b/hepcrawl/items.py index c9ea8ff0..1de0ca17 100644 --- a/hepcrawl/items.py +++ b/hepcrawl/items.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -13,6 +13,8 @@ http://doc.scrapy.org/en/latest/topics/items.html """ +from __future__ import absolute_import, division, print_function + import scrapy diff --git a/hepcrawl/loaders.py b/hepcrawl/loaders.py index 0e68c21f..2a68d527 100644 --- a/hepcrawl/loaders.py +++ b/hepcrawl/loaders.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -13,6 +13,8 @@ See documentation in: http://doc.scrapy.org/en/latest/topics/items.html """ +from __future__ import absolute_import, division, print_function + from scrapy.loader import ItemLoader from scrapy.loader.processors import Join, MapCompose, TakeFirst from scrapy.utils.url import canonicalize_url diff --git a/hepcrawl/mappings.py b/hepcrawl/mappings.py index 09cb5f2b..8828c4aa 100644 --- a/hepcrawl/mappings.py +++ b/hepcrawl/mappings.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,7 @@ """Contains mappings.""" +from __future__ import absolute_import, division, print_function COMMON_ACRONYMS = [ 'LHC', diff --git a/hepcrawl/middlewares.py b/hepcrawl/middlewares.py index 94bbb104..dab5c7e4 100644 --- a/hepcrawl/middlewares.py +++ b/hepcrawl/middlewares.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,7 @@ """Define middlewares here.""" +from __future__ import absolute_import, division, print_function class ErrorHandlingMiddleware(object): diff --git a/hepcrawl/outputs.py b/hepcrawl/outputs.py index 4c06e638..08bb861a 100644 --- a/hepcrawl/outputs.py +++ b/hepcrawl/outputs.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,7 @@ """Define output processors here.""" +from __future__ import absolute_import, division, print_function class FreeKeywords(object): diff --git a/hepcrawl/pipelines.py b/hepcrawl/pipelines.py index 1ea92bb1..dea24b9e 100644 --- a/hepcrawl/pipelines.py +++ b/hepcrawl/pipelines.py @@ -13,15 +13,14 @@ See: http://doc.scrapy.org/en/latest/topics/item-pipeline.html """ +from __future__ import absolute_import, division, print_function + import datetime -import json import os import requests -from crawler2hep import crawler2hep - -from .utils import get_temporary_file +from .crawler2hep import crawler2hep def has_publication_info(item): diff --git a/hepcrawl/settings.py b/hepcrawl/settings.py index 521b6e82..71dcfc75 100644 --- a/hepcrawl/settings.py +++ b/hepcrawl/settings.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -17,6 +17,8 @@ http://scrapy.readthedocs.org/en/latest/topics/spider-middleware.html """ +from __future__ import absolute_import, division, print_function + import os diff --git a/hepcrawl/spiders/__init__.py b/hepcrawl/spiders/__init__.py index be36ef72..074204ee 100644 --- a/hepcrawl/spiders/__init__.py +++ b/hepcrawl/spiders/__init__.py @@ -6,3 +6,5 @@ # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. + +from __future__ import absolute_import, division, print_function diff --git a/hepcrawl/spiders/alpha_spider.py b/hepcrawl/spiders/alpha_spider.py index 4ef89137..b7c5de93 100644 --- a/hepcrawl/spiders/alpha_spider.py +++ b/hepcrawl/spiders/alpha_spider.py @@ -9,7 +9,7 @@ """Spider for ALPHA.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import re diff --git a/hepcrawl/spiders/aps_spider.py b/hepcrawl/spiders/aps_spider.py index 9932aa0e..eecb6381 100644 --- a/hepcrawl/spiders/aps_spider.py +++ b/hepcrawl/spiders/aps_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,9 +9,7 @@ """Spider for APS.""" -from __future__ import absolute_import, print_function - -import re +from __future__ import absolute_import, division, print_function import json import link_header diff --git a/hepcrawl/spiders/arxiv_spider.py b/hepcrawl/spiders/arxiv_spider.py index 59b11358..d2a0ce02 100644 --- a/hepcrawl/spiders/arxiv_spider.py +++ b/hepcrawl/spiders/arxiv_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,6 +9,8 @@ """Spider for arXiv.""" +from __future__ import absolute_import, division, print_function + import re from scrapy import Request, Selector diff --git a/hepcrawl/spiders/base_spider.py b/hepcrawl/spiders/base_spider.py index d78a4f80..9e4af8c9 100644 --- a/hepcrawl/spiders/base_spider.py +++ b/hepcrawl/spiders/base_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for BASE.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from urlparse import urljoin diff --git a/hepcrawl/spiders/brown_spider.py b/hepcrawl/spiders/brown_spider.py index 5e12fa5e..54fca6a9 100644 --- a/hepcrawl/spiders/brown_spider.py +++ b/hepcrawl/spiders/brown_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for Brown University Digital Repository""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import re diff --git a/hepcrawl/spiders/dnb_spider.py b/hepcrawl/spiders/dnb_spider.py index 4a9db042..1e9b6c6d 100644 --- a/hepcrawl/spiders/dnb_spider.py +++ b/hepcrawl/spiders/dnb_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for DNB Dissonline.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from scrapy import Request from scrapy.spiders import XMLFeedSpider diff --git a/hepcrawl/spiders/edp_spider.py b/hepcrawl/spiders/edp_spider.py index 79edb3a4..2d710e05 100644 --- a/hepcrawl/spiders/edp_spider.py +++ b/hepcrawl/spiders/edp_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,8 @@ """Spider for EDP Sciences.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function + import os import urlparse import tarfile diff --git a/hepcrawl/spiders/elsevier_spider.py b/hepcrawl/spiders/elsevier_spider.py index ab994e2e..de1a53c4 100644 --- a/hepcrawl/spiders/elsevier_spider.py +++ b/hepcrawl/spiders/elsevier_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for Elsevier.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import os import re diff --git a/hepcrawl/spiders/hindawi_spider.py b/hepcrawl/spiders/hindawi_spider.py index 9923e1b3..f86f42eb 100644 --- a/hepcrawl/spiders/hindawi_spider.py +++ b/hepcrawl/spiders/hindawi_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for Hindawi.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from scrapy import Request from scrapy.spiders import XMLFeedSpider diff --git a/hepcrawl/spiders/infn_spider.py b/hepcrawl/spiders/infn_spider.py index 65658f26..42a7f273 100644 --- a/hepcrawl/spiders/infn_spider.py +++ b/hepcrawl/spiders/infn_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for INFN.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from urlparse import urljoin diff --git a/hepcrawl/spiders/iop_spider.py b/hepcrawl/spiders/iop_spider.py index 4ed8f8d0..e9a993ce 100644 --- a/hepcrawl/spiders/iop_spider.py +++ b/hepcrawl/spiders/iop_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for IOP.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import os diff --git a/hepcrawl/spiders/magic_spider.py b/hepcrawl/spiders/magic_spider.py index a515a0f5..a72405a4 100644 --- a/hepcrawl/spiders/magic_spider.py +++ b/hepcrawl/spiders/magic_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for MAGIC.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from urlparse import urljoin diff --git a/hepcrawl/spiders/mit_spider.py b/hepcrawl/spiders/mit_spider.py index 26924fab..7f316d0f 100644 --- a/hepcrawl/spiders/mit_spider.py +++ b/hepcrawl/spiders/mit_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for MIT.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import re diff --git a/hepcrawl/spiders/phenix_spider.py b/hepcrawl/spiders/phenix_spider.py index 03f0d89c..6593a9b6 100644 --- a/hepcrawl/spiders/phenix_spider.py +++ b/hepcrawl/spiders/phenix_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for PHENIX.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from urlparse import urljoin diff --git a/hepcrawl/spiders/phil_spider.py b/hepcrawl/spiders/phil_spider.py index 83a72149..eae309c6 100644 --- a/hepcrawl/spiders/phil_spider.py +++ b/hepcrawl/spiders/phil_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for Philpapers.org""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import json from urlparse import urljoin diff --git a/hepcrawl/spiders/pos_spider.py b/hepcrawl/spiders/pos_spider.py index 5ff1191c..951e2e13 100644 --- a/hepcrawl/spiders/pos_spider.py +++ b/hepcrawl/spiders/pos_spider.py @@ -9,6 +9,8 @@ """Spider for POS.""" +from __future__ import absolute_import, division, print_function + import re from scrapy import Request, Selector diff --git a/hepcrawl/spiders/t2k_spider.py b/hepcrawl/spiders/t2k_spider.py index d67c42f5..5ca7cc84 100644 --- a/hepcrawl/spiders/t2k_spider.py +++ b/hepcrawl/spiders/t2k_spider.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -9,7 +9,7 @@ """Spider for T2K.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from urlparse import urljoin diff --git a/hepcrawl/spiders/wsp_spider.py b/hepcrawl/spiders/wsp_spider.py index 6a5b02c8..cfb1b66d 100644 --- a/hepcrawl/spiders/wsp_spider.py +++ b/hepcrawl/spiders/wsp_spider.py @@ -9,7 +9,7 @@ """Spider for World Scientific.""" -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import os import urlparse diff --git a/hepcrawl/testlib/__init__.py b/hepcrawl/testlib/__init__.py index 9d0c62af..8d470392 100644 --- a/hepcrawl/testlib/__init__.py +++ b/hepcrawl/testlib/__init__.py @@ -7,4 +7,4 @@ # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals diff --git a/hepcrawl/testlib/celery_monitor.py b/hepcrawl/testlib/celery_monitor.py index 12cb86b4..6c720550 100644 --- a/hepcrawl/testlib/celery_monitor.py +++ b/hepcrawl/testlib/celery_monitor.py @@ -9,7 +9,7 @@ """Celery monitor dealing with celery tasks for functional tests.""" -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals from itertools import islice diff --git a/hepcrawl/testlib/scrapyd_coverage_runner.py b/hepcrawl/testlib/scrapyd_coverage_runner.py index 1cd9ddc3..951f0730 100644 --- a/hepcrawl/testlib/scrapyd_coverage_runner.py +++ b/hepcrawl/testlib/scrapyd_coverage_runner.py @@ -7,6 +7,7 @@ # under the terms of the Revised BSD License; see LICENSE file for # more details. +from __future__ import absolute_import, division, print_function from scrapyd.runner import main diff --git a/hepcrawl/testlib/tasks.py b/hepcrawl/testlib/tasks.py index d76588fc..e4da5e01 100644 --- a/hepcrawl/testlib/tasks.py +++ b/hepcrawl/testlib/tasks.py @@ -9,7 +9,7 @@ """Celery tasks for dealing with crawler.""" -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import json diff --git a/hepcrawl/utils.py b/hepcrawl/utils.py index 6b27a5d0..7767cb70 100644 --- a/hepcrawl/utils.py +++ b/hepcrawl/utils.py @@ -7,7 +7,7 @@ # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function import os import re diff --git a/hepcrawl/version.py b/hepcrawl/version.py index 906a014e..c01fccaa 100644 --- a/hepcrawl/version.py +++ b/hepcrawl/version.py @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for @@ -13,7 +13,7 @@ and parsed by ``setup.py``. """ -from __future__ import absolute_import, print_function +from __future__ import absolute_import, division, print_function from autosemver.packaging import get_current_version diff --git a/setup.cfg b/setup.cfg index 9bd32fb7..0996d0ae 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for diff --git a/setup.py b/setup.py index d064a673..b4a40a36 100644 --- a/setup.py +++ b/setup.py @@ -9,6 +9,8 @@ """Scrapy project for feeds into INSPIRE-HEP (http://inspirehep.net).""" +from __future__ import absolute_import, division, print_function + from setuptools import setup, find_packages readme = open('README.rst').read() diff --git a/tests/Dockerfile.hepcrawl_base b/tests/Dockerfile.hepcrawl_base index bc8c6f90..02be4ce5 100644 --- a/tests/Dockerfile.hepcrawl_base +++ b/tests/Dockerfile.hepcrawl_base @@ -1,7 +1,7 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016, 2017 CERN. +# Copyright (C) 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for diff --git a/tests/functional/WSP/test_wsp.py b/tests/functional/WSP/test_wsp.py index 8df90ab6..bde29e9a 100644 --- a/tests/functional/WSP/test_wsp.py +++ b/tests/functional/WSP/test_wsp.py @@ -9,7 +9,7 @@ """Functional tests for WSP spider""" -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function import pytest import json diff --git a/tests/unit/test_alpha.py b/tests/unit/test_alpha.py index eaa32bf4..eef140b1 100644 --- a/tests/unit/test_alpha.py +++ b/tests/unit/test_alpha.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_aps.py b/tests/unit/test_aps.py index 4e774e91..eb53269d 100644 --- a/tests/unit/test_aps.py +++ b/tests/unit/test_aps.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_arxiv_all.py b/tests/unit/test_arxiv_all.py index f0e8d07e..1974744a 100644 --- a/tests/unit/test_arxiv_all.py +++ b/tests/unit/test_arxiv_all.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_arxiv_single.py b/tests/unit/test_arxiv_single.py index 700a1517..fbf7b2e4 100644 --- a/tests/unit/test_arxiv_single.py +++ b/tests/unit/test_arxiv_single.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_base.py b/tests/unit/test_base.py index 18110426..d04dfa16 100644 --- a/tests/unit/test_base.py +++ b/tests/unit/test_base.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_brown.py b/tests/unit/test_brown.py index 42f34573..7ee6daaa 100644 --- a/tests/unit/test_brown.py +++ b/tests/unit/test_brown.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import json diff --git a/tests/unit/test_dateutils.py b/tests/unit/test_dateutils.py index 76c6fa5b..041fda14 100644 --- a/tests/unit/test_dateutils.py +++ b/tests/unit/test_dateutils.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import datetime diff --git a/tests/unit/test_dnb.py b/tests/unit/test_dnb.py index efb34094..0d99a563 100644 --- a/tests/unit/test_dnb.py +++ b/tests/unit/test_dnb.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import os diff --git a/tests/unit/test_edp.py b/tests/unit/test_edp.py index 8331a6e8..cc7885bd 100644 --- a/tests/unit/test_edp.py +++ b/tests/unit/test_edp.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import os diff --git a/tests/unit/test_elsevier.py b/tests/unit/test_elsevier.py index 9f2c7a8b..486d6c7b 100644 --- a/tests/unit/test_elsevier.py +++ b/tests/unit/test_elsevier.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import fnmatch diff --git a/tests/unit/test_extensions.py b/tests/unit/test_extensions.py index a378f641..fe83d93c 100644 --- a/tests/unit/test_extensions.py +++ b/tests/unit/test_extensions.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_hindawi.py b/tests/unit/test_hindawi.py index 05593a52..37e5e183 100644 --- a/tests/unit/test_hindawi.py +++ b/tests/unit/test_hindawi.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_infn.py b/tests/unit/test_infn.py index b54cc91a..0c60799a 100644 --- a/tests/unit/test_infn.py +++ b/tests/unit/test_infn.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_inputs.py b/tests/unit/test_inputs.py index 7551ea16..41e2bbe8 100644 --- a/tests/unit/test_inputs.py +++ b/tests/unit/test_inputs.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals from hepcrawl.inputs import ( translate_language, diff --git a/tests/unit/test_iop.py b/tests/unit/test_iop.py index d07b6abb..4342a08a 100644 --- a/tests/unit/test_iop.py +++ b/tests/unit/test_iop.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import os diff --git a/tests/unit/test_magic.py b/tests/unit/test_magic.py index 15539ff7..eeb574fe 100644 --- a/tests/unit/test_magic.py +++ b/tests/unit/test_magic.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_mit.py b/tests/unit/test_mit.py index 4dee43e8..0253d91f 100644 --- a/tests/unit/test_mit.py +++ b/tests/unit/test_mit.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_phenix.py b/tests/unit/test_phenix.py index 19efa2da..75384350 100644 --- a/tests/unit/test_phenix.py +++ b/tests/unit/test_phenix.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_phil.py b/tests/unit/test_phil.py index 326a7c8b..a2596d43 100644 --- a/tests/unit/test_phil.py +++ b/tests/unit/test_phil.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import json diff --git a/tests/unit/test_pipelines.py b/tests/unit/test_pipelines.py index 1cbde74b..df189837 100644 --- a/tests/unit/test_pipelines.py +++ b/tests/unit/test_pipelines.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import json import mock diff --git a/tests/unit/test_pos.py b/tests/unit/test_pos.py index 32ac588e..cd150b2d 100644 --- a/tests/unit/test_pos.py +++ b/tests/unit/test_pos.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import os import pkg_resources diff --git a/tests/unit/test_t2k.py b/tests/unit/test_t2k.py index c228b88b..283a02e5 100644 --- a/tests/unit/test_t2k.py +++ b/tests/unit/test_t2k.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2016 CERN. +# Copyright (C) 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest diff --git a/tests/unit/test_utils.py b/tests/unit/test_utils.py index 07efbbb1..42e6fd6f 100644 --- a/tests/unit/test_utils.py +++ b/tests/unit/test_utils.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import os diff --git a/tests/unit/test_world_scientific.py b/tests/unit/test_world_scientific.py index f0785384..c15a3c09 100644 --- a/tests/unit/test_world_scientific.py +++ b/tests/unit/test_world_scientific.py @@ -1,13 +1,13 @@ # -*- coding: utf-8 -*- # # This file is part of hepcrawl. -# Copyright (C) 2015, 2016 CERN. +# Copyright (C) 2015, 2016, 2017 CERN. # # hepcrawl is a free software; you can redistribute it and/or modify it # under the terms of the Revised BSD License; see LICENSE file for # more details. -from __future__ import absolute_import, print_function, unicode_literals +from __future__ import absolute_import, division, print_function, unicode_literals import pytest import os