Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions CIME/BuildTools/configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,20 +15,22 @@
COMPILER, MPILIB, and DEBUG, respectively.
"""

from CIME.XML.standard_module_setup import *
import glob
import logging
import os
import shutil

from CIME.build import CmakeTmpBuildDir
from CIME.utils import (
copy_local_macros_to_dir,
expect,
safe_copy,
get_model,
get_src_root,
safe_copy,
stringify_bool,
copy_local_macros_to_dir,
)
from CIME.XML.env_mach_specific import EnvMachSpecific
from CIME.XML.files import Files
from CIME.build import CmakeTmpBuildDir

import shutil, glob

logger = logging.getLogger(__name__)

Expand Down
13 changes: 9 additions & 4 deletions CIME/Servers/ftp.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,20 @@
"""
FTP Server class. Interact with a server using FTP protocol
"""

# pylint: disable=super-init-not-called
from CIME.XML.standard_module_setup import *
from CIME.Servers.generic_server import GenericServer
from CIME.utils import Timeout
import logging
import os
import socket
from ftplib import FTP as FTPpy
from ftplib import all_errors as all_ftp_errors
import socket

from CIME.Servers.generic_server import GenericServer
from CIME.utils import Timeout, expect

logger = logging.getLogger(__name__)


# I think that multiple inheritence would be useful here, but I couldnt make it work
# in a py2/3 compatible way.
class FTP(GenericServer):
Expand Down
3 changes: 2 additions & 1 deletion CIME/Servers/generic_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
to make sure that specific server classes maintain a consistant argument list and functionality
so that they are interchangable objects
"""

# pylint: disable=unused-argument

from CIME.XML.standard_module_setup import *
import logging
from socket import _GLOBAL_DEFAULT_TIMEOUT

logger = logging.getLogger(__name__)
Expand Down
5 changes: 4 additions & 1 deletion CIME/Servers/gftp.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
"""
GridFTP Server class. Interact with a server using GridFTP protocol
"""

# pylint: disable=super-init-not-called
from CIME.XML.standard_module_setup import *
import logging
import os

from CIME.Servers.generic_server import GenericServer
from CIME.utils import run_cmd

Expand Down
6 changes: 5 additions & 1 deletion CIME/Servers/svn.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
"""
SVN Server class. Interact with a server using SVN protocol
"""

# pylint: disable=super-init-not-called
from CIME.XML.standard_module_setup import *
import logging
import os

from CIME.Servers.generic_server import GenericServer
from CIME.utils import run_cmd

logger = logging.getLogger(__name__)

Expand Down
6 changes: 5 additions & 1 deletion CIME/Servers/wget.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
"""
WGET Server class. Interact with a server using WGET protocol
"""

# pylint: disable=super-init-not-called
from CIME.XML.standard_module_setup import *
import logging
import os

from CIME.Servers.generic_server import GenericServer
from CIME.utils import run_cmd

logger = logging.getLogger(__name__)

Expand Down
5 changes: 3 additions & 2 deletions CIME/SystemTests/dae.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,15 @@

"""

import os.path
import logging
import glob
import gzip
import logging
import os.path

from CIME.SystemTests.system_tests_compare_two import SystemTestsCompareTwo
from CIME.utils import expect


###############################################################################
class DAE(SystemTestsCompareTwo):
###############################################################################
Expand Down
11 changes: 7 additions & 4 deletions CIME/SystemTests/eri.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@
CIME ERI test This class inherits from SystemTestsCommon
"""

from CIME.XML.standard_module_setup import *
from CIME.utils import safe_copy
from CIME.SystemTests.system_tests_common import SystemTestsCommon
import glob
import logging
import os
import shutil
from stat import S_ISDIR, ST_CTIME, ST_MODE
import shutil, glob, os

from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.utils import expect, safe_copy

logger = logging.getLogger(__name__)

Expand Down
5 changes: 4 additions & 1 deletion CIME/SystemTests/erio.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@

This class inherits from SystemTestsCommon
"""
from CIME.XML.standard_module_setup import *

import logging

from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.utils import expect

logger = logging.getLogger(__name__)

Expand Down
3 changes: 2 additions & 1 deletion CIME/SystemTests/erp.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
(2) Do a restart test with half the number of tasks and threads (suffix rest)
"""

from CIME.XML.standard_module_setup import *
import logging

from CIME.SystemTests.restart_tests import RestartTest

logger = logging.getLogger(__name__)
Expand Down
8 changes: 5 additions & 3 deletions CIME/SystemTests/err.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,12 @@
ERR tests short term archiving and restart capabilities
"""

import glob, os
from CIME.XML.standard_module_setup import *
import glob
import logging
import os

from CIME.SystemTests.restart_tests import RestartTest
from CIME.utils import safe_copy, ls_sorted_by_fname
from CIME.utils import expect, ls_sorted_by_fname, safe_copy

logger = logging.getLogger(__name__)

Expand Down
9 changes: 6 additions & 3 deletions CIME/SystemTests/erri.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@
ERRI tests short term archiving and restart capabilities with "incomplete" (unzipped) log files
"""

from CIME.XML.standard_module_setup import *
from CIME.SystemTests.err import ERR
import glob
import gzip
import logging
import os
import shutil

import shutil, glob, gzip
from CIME.SystemTests.err import ERR

logger = logging.getLogger(__name__)

Expand Down
8 changes: 6 additions & 2 deletions CIME/SystemTests/ers.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
"""
CIME restart test This class inherits from SystemTestsCommon
"""
from CIME.XML.standard_module_setup import *
from CIME.SystemTests.system_tests_common import SystemTestsCommon

import glob
import logging
import os

from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.utils import expect

logger = logging.getLogger(__name__)

Expand Down
3 changes: 2 additions & 1 deletion CIME/SystemTests/ert.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
Exact restart from startup, default 2 month + 1 month
"""

from CIME.XML.standard_module_setup import *
import logging

from CIME.SystemTests.system_tests_common import SystemTestsCommon

logger = logging.getLogger(__name__)
Expand Down
11 changes: 7 additions & 4 deletions CIME/SystemTests/funit.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,15 @@
CIME FUNIT test. This class inherits from SystemTestsCommon. It runs
the fortran unit tests; grid and compset are ignored.
"""
from CIME.XML.standard_module_setup import *
from CIME.SystemTests.system_tests_common import SystemTestsCommon

import logging
import os

from CIME.build import post_build
from CIME.status import append_testlog
from CIME.utils import get_cime_root
from CIME.test_status import *
from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.test_status import BASELINE_PHASE, GENERATE_PHASE, TEST_PASS_STATUS
from CIME.utils import expect, get_cime_root, run_cmd

logger = logging.getLogger(__name__)

Expand Down
20 changes: 14 additions & 6 deletions CIME/SystemTests/hommebaseclass.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,22 @@
CIME HOMME test. This class inherits from SystemTestsCommon
"""

from CIME.XML.standard_module_setup import *
from CIME.SystemTests.system_tests_common import SystemTestsCommon
import logging
import os
import shutil

from CIME.build import post_build
from CIME.status import append_testlog
from CIME.utils import SharedArea, new_lid, gzip_existing_file
from CIME.test_status import *

import shutil
from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.test_status import BASELINE_PHASE, GENERATE_PHASE, TEST_PASS_STATUS
from CIME.utils import (
SharedArea,
expect,
gzip_existing_file,
new_lid,
run_cmd,
run_cmd_no_fail,
)

logger = logging.getLogger(__name__)

Expand Down
2 changes: 1 addition & 1 deletion CIME/SystemTests/icp.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
"""
CIME ICP test This class inherits from SystemTestsCommon
"""
from CIME.XML.standard_module_setup import *

from CIME.SystemTests.system_tests_common import SystemTestsCommon


Expand Down
6 changes: 4 additions & 2 deletions CIME/SystemTests/irt.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,11 @@

"""

import logging
import os

from CIME.SystemTests.restart_tests import RestartTest
from CIME.XML.standard_module_setup import *
from CIME.utils import ls_sorted_by_fname
from CIME.utils import expect, ls_sorted_by_fname

logger = logging.getLogger(__name__)

Expand Down
11 changes: 6 additions & 5 deletions CIME/SystemTests/ldsta.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,20 @@
The test verifies the archive directory contains the expected files
"""

from CIME.XML.standard_module_setup import *
from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.utils import expect
from CIME.date import get_file_date

import datetime
import glob
import logging
import os
import random
import shutil

from CIME.date import get_file_date
from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.utils import expect

logger = logging.getLogger(__name__)


# datetime objects can't be used anywhere else
def _date_to_datetime(date_obj):
return datetime.datetime(
Expand Down
4 changes: 3 additions & 1 deletion CIME/SystemTests/mcc.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
This does two runs: In the first we run a three member ensemble using the
MULTI_DRIVER capability, then we run a second single instance case and compare
"""
from CIME.XML.standard_module_setup import *

import logging

from CIME.SystemTests.system_tests_compare_two import SystemTestsCompareTwo

logger = logging.getLogger(__name__)
Expand Down
19 changes: 9 additions & 10 deletions CIME/SystemTests/mvk.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,22 @@
This class inherits from SystemTestsCommon.
"""

import os
import json
import logging
import os
from shutil import copytree

from CIME import test_status
from CIME import utils
from CIME.status import append_testlog
from CIME.SystemTests.system_tests_common import SystemTestsCommon
import evv4esm # pylint: disable=import-error
from evv4esm.__main__ import main as evv # pylint: disable=import-error

from CIME import test_status, utils
from CIME.case.case_setup import case_setup
from CIME.XML.machines import Machines
from CIME.config import ConfigBase
from CIME.SystemTests import test_mods
from CIME.namelist import Namelist

import evv4esm # pylint: disable=import-error
from evv4esm.__main__ import main as evv # pylint: disable=import-error
from CIME.status import append_testlog
from CIME.SystemTests import test_mods
from CIME.SystemTests.system_tests_common import SystemTestsCommon
from CIME.XML.machines import Machines

version = evv4esm.__version_info__

Expand Down
3 changes: 2 additions & 1 deletion CIME/SystemTests/nck.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
Lay all of the components out sequentially
"""

from CIME.XML.standard_module_setup import *
import logging

from CIME.SystemTests.system_tests_compare_two import SystemTestsCompareTwo

logger = logging.getLogger(__name__)
Expand Down
4 changes: 3 additions & 1 deletion CIME/SystemTests/ncr.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@

NOTE: This is currently untested, and may not be working properly
"""
from CIME.XML.standard_module_setup import *

import logging

from CIME.SystemTests.system_tests_compare_two import SystemTestsCompareTwo

logger = logging.getLogger(__name__)
Expand Down
Loading
Loading