imports: sort imports everywhere in Spack (#24695)

* fix remaining flake8 errors

* imports: sort imports everywhere in Spack

We enabled import order checking in #23947, but fixing things manually drives
people crazy. This used `spack style --fix --all` from #24071 to automatically
sort everything in Spack so PR submitters won't have to deal with it.

This should go in after #24071, as it assumes we're using `isort`, not
`flake8-import-order` to order things. `isort` seems to be more flexible and
allows `llnl` mports to be in their own group before `spack` ones, so this
seems like a good switch.
This commit is contained in:
Todd Gamblin 2021-07-08 15:12:30 -07:00 committed by GitHub
parent 620836a809
commit 24c01d57cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
797 changed files with 2048 additions and 1442 deletions

View file

@ -370,7 +370,7 @@ jobs:
run: |
pip install --upgrade pip six setuptools
pip install --upgrade codecov coverage
pip install --upgrade flake8 isort>=4.3.5 pep8-naming mypy>=0.800
pip install --upgrade flake8 isort>=4.3.5 mypy>=0.800
- name: Setup Homebrew packages
run: |
brew install dash fish gcc gnupg2 kcov

View file

@ -17,10 +17,10 @@
# All configuration values have a default; values that are commented out
# serve to show the default.
import sys
import os
import re
import subprocess
import sys
from glob import glob
from sphinx.ext.apidoc import main as sphinx_apidoc
@ -82,6 +82,8 @@
# Disable duplicate cross-reference warnings.
#
from sphinx.domains.python import PythonDomain
class PatchedPythonDomain(PythonDomain):
def resolve_xref(self, env, fromdocname, builder, typ, target, node, contnode):
if 'refspecific' in node:
@ -136,6 +138,7 @@ def setup(sphinx):
#
# The short X.Y version.
import spack
version = '.'.join(str(s) for s in spack.spack_version_info[:2])
# The full version, including alpha/beta/rc tags.
release = spack.spack_version
@ -179,7 +182,8 @@ def setup(sphinx):
# We use our own extension of the default style with a few modifications
from pygments.style import Style
from pygments.styles.default import DefaultStyle
from pygments.token import Generic, Comment, Text
from pygments.token import Comment, Generic, Text
class SpackStyle(DefaultStyle):
styles = DefaultStyle.styles.copy()
@ -188,6 +192,7 @@ class SpackStyle(DefaultStyle):
styles[Generic.Prompt] = "bold #346ec9"
import pkg_resources
dist = pkg_resources.Distribution(__file__)
sys.path.append('.') # make 'conf' module findable
ep = pkg_resources.EntryPoint.parse('spack = conf:SpackStyle', dist=dist)

View file

@ -5,9 +5,9 @@
from __future__ import print_function
import re
import argparse
import errno
import re
import sys
from six import StringIO

View file

@ -4,9 +4,9 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import collections
import errno
import hashlib
import glob
import grp
import hashlib
import itertools
import numbers
import os
@ -19,10 +19,11 @@
from contextlib import contextmanager
import six
from llnl.util import tty
from llnl.util.lang import dedupe, memoized
from spack.util.executable import Executable
from spack.util.executable import Executable
if sys.version_info >= (3, 3):
from collections.abc import Sequence # novm

View file

@ -5,14 +5,15 @@
from __future__ import division
import functools
import inspect
import multiprocessing
import os
import re
import functools
import inspect
from datetime import datetime, timedelta
from six import string_types
import sys
from datetime import datetime, timedelta
from six import string_types
if sys.version_info < (3, 0):
from itertools import izip_longest # novm

View file

@ -7,12 +7,12 @@
from __future__ import print_function
import filecmp
import os
import shutil
import filecmp
from llnl.util.filesystem import traverse_tree, mkdirp, touch
import llnl.util.tty as tty
from llnl.util.filesystem import mkdirp, touch, traverse_tree
__all__ = ['LinkTree']

View file

@ -3,16 +3,16 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import fcntl
import errno
import time
import fcntl
import os
import socket
import time
from datetime import datetime
import llnl.util.tty as tty
import spack.util.string
import spack.util.string
__all__ = ['Lock', 'LockTransaction', 'WriteTransaction', 'ReadTransaction',
'LockError', 'LockTimeoutError',

View file

@ -12,12 +12,13 @@
import termios
import textwrap
import traceback
import six
from datetime import datetime
import six
from six import StringIO
from six.moves import input
from llnl.util.tty.color import cprint, cwrite, cescape, clen
from llnl.util.tty.color import cescape, clen, cprint, cwrite
# Globals
_debug = 0

View file

@ -10,10 +10,11 @@
import os
import sys
from six import StringIO, text_type
from llnl.util.tty import terminal_size
from llnl.util.tty.color import clen, cextra
from llnl.util.tty.color import cextra, clen
class ColumnConfig:

View file

@ -60,9 +60,9 @@
To output an @, use '@@'. To output a } inside braces, use '}}'.
"""
from __future__ import unicode_literals
import re
import sys
from contextlib import contextmanager
import six

View file

@ -13,15 +13,14 @@
import os
import re
import select
import signal
import sys
import traceback
import signal
from contextlib import contextmanager
from six import string_types
from six import StringIO
from typing import Optional # novm
from types import ModuleType # novm
from typing import Optional # novm
from six import StringIO, string_types
import llnl.util.tty as tty

View file

@ -14,10 +14,10 @@
"""
from __future__ import print_function
import os
import signal
import multiprocessing
import os
import re
import signal
import sys
import termios
import time

View file

@ -8,9 +8,9 @@
from llnl.util.lang import memoized
import spack.spec
from spack.compilers.clang import Clang
from spack.spec import CompilerSpec
from spack.util.executable import Executable, ProcessError
from spack.compilers.clang import Clang
class ABI(object):

View file

@ -10,11 +10,10 @@
from __future__ import absolute_import
import spack.util.classes
import spack.paths
import llnl.util.tty as tty
import spack.paths
import spack.util.classes
mod_path = spack.paths.analyzers_path
analyzers = spack.util.classes.list_classes("spack.analyzers", mod_path)

View file

@ -7,14 +7,15 @@
and (optionally) interact with a Spack Monitor
"""
import spack.monitor
import spack.hooks
import llnl.util.tty as tty
import spack.util.path
import spack.config
import os
import llnl.util.tty as tty
import spack.config
import spack.hooks
import spack.monitor
import spack.util.path
def get_analyzer_dir(spec, analyzer_dir=None):
"""

View file

@ -8,11 +8,12 @@
directory."""
import spack.monitor
from .analyzer_base import AnalyzerBase
import os
import spack.monitor
from .analyzer_base import AnalyzerBase
class ConfigArgs(AnalyzerBase):

View file

@ -8,11 +8,11 @@
an index of key, value pairs for environment variables."""
from .analyzer_base import AnalyzerBase
import os
from spack.util.environment import EnvironmentModifications
import os
from .analyzer_base import AnalyzerBase
class EnvironmentVariables(AnalyzerBase):

View file

@ -8,11 +8,12 @@
analyzer folder for further processing."""
import spack.monitor
from .analyzer_base import AnalyzerBase
import os
import spack.monitor
from .analyzer_base import AnalyzerBase
class InstallFiles(AnalyzerBase):

View file

@ -4,20 +4,20 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import spack
import spack.error
import spack.bootstrap
import spack.hooks
import spack.monitor
import spack.binary_distribution
import spack.package
import spack.repo
import os
import llnl.util.tty as tty
from .analyzer_base import AnalyzerBase
import spack
import spack.binary_distribution
import spack.bootstrap
import spack.error
import spack.hooks
import spack.monitor
import spack.package
import spack.repo
import os
from .analyzer_base import AnalyzerBase
class Libabigail(AnalyzerBase):

View file

@ -60,20 +60,21 @@
import functools
import warnings
import archspec.cpu
import six
import llnl.util.tty as tty
import archspec.cpu
import llnl.util.lang as lang
import llnl.util.tty as tty
import spack.compiler
import spack.compilers
import spack.config
import spack.paths
import spack.error as serr
import spack.paths
import spack.util.classes
import spack.util.executable
import spack.version
import spack.util.classes
from spack.util.spack_yaml import syaml_dict

View file

@ -37,6 +37,7 @@ def _search_duplicate_compilers(error_cls):
"""
import collections
import itertools
try:
from collections.abc import Sequence # novm
except ImportError:
@ -265,6 +266,7 @@ def _search_duplicate_specs_in_externals(error_cls):
def _unknown_variants_in_directives(pkgs, error_cls):
"""Report unknown or wrong variants in directives for this package"""
import llnl.util.lang
import spack.repo
import spack.spec

View file

@ -4,22 +4,20 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import codecs
import glob
import hashlib
import json
import os
import re
import shutil
import sys
import tarfile
import shutil
import tempfile
import hashlib
import glob
from ordereddict_backport import OrderedDict
from contextlib import closing
import ruamel.yaml as yaml
import json
from six.moves.urllib.error import URLError, HTTPError
from ordereddict_backport import OrderedDict
from six.moves.urllib.error import HTTPError, URLError
import llnl.util.lang
import llnl.util.tty as tty
@ -29,19 +27,18 @@
import spack.config as config
import spack.database as spack_db
import spack.fetch_strategy as fs
import spack.util.file_cache as file_cache
import spack.mirror
import spack.relocate as relocate
import spack.util.file_cache as file_cache
import spack.util.gpg
import spack.util.spack_json as sjson
import spack.util.spack_yaml as syaml
import spack.mirror
import spack.util.url as url_util
import spack.util.web as web_util
from spack.caches import misc_cache_location
from spack.spec import Spec
from spack.stage import Stage
_build_cache_relative_path = 'build_cache'
_build_cache_keys_relative_path = '_pgp'

View file

@ -5,6 +5,7 @@
import contextlib
import os
import sys
try:
import sysconfig # novm
except ImportError:

View file

@ -33,44 +33,52 @@
calls you can make from within the install() function.
"""
import inspect
import re
import multiprocessing
import os
import re
import shutil
import sys
import traceback
import types
from six import StringIO
import llnl.util.tty as tty
from llnl.util.tty.color import cescape, colorize
from llnl.util.filesystem import mkdirp, install, install_tree
from llnl.util.filesystem import install, install_tree, mkdirp
from llnl.util.lang import dedupe
from llnl.util.tty.color import cescape, colorize
from llnl.util.tty.log import MultiProcessFd
import spack.architecture as arch
import spack.build_systems.cmake
import spack.build_systems.meson
import spack.config
import spack.install_test
import spack.main
import spack.paths
import spack.package
import spack.paths
import spack.repo
import spack.schema.environment
import spack.store
import spack.install_test
import spack.subprocess_context
import spack.architecture as arch
import spack.util.path
from spack.util.string import plural
from spack.util.environment import (
env_flag, filter_system_paths, get_path, is_system_path,
EnvironmentModifications, validate, preserve_environment)
from spack.util.environment import system_dirs
from spack.error import NoLibrariesError, NoHeadersError
from spack.util.executable import Executable
from spack.util.module_cmd import load_module, path_from_modules, module
from spack.util.log_parse import parse_log_events, make_log_context
from spack.error import NoHeadersError, NoLibrariesError
from spack.util.cpus import cpus_available
from spack.util.environment import (
EnvironmentModifications,
env_flag,
filter_system_paths,
get_path,
is_system_path,
preserve_environment,
system_dirs,
validate,
)
from spack.util.executable import Executable
from spack.util.log_parse import make_log_context, parse_log_events
from spack.util.module_cmd import load_module, module, path_from_modules
from spack.util.string import plural
#
# This can be set by the user to globally disable parallel builds.
#

View file

@ -6,6 +6,7 @@
# Why doesn't this work for me?
# from spack import *
from llnl.util.filesystem import filter_file
from spack.build_systems.autotools import AutotoolsPackage
from spack.directives import extends
from spack.package import ExtensionError

View file

@ -7,13 +7,13 @@
import os
import os.path
import stat
from subprocess import PIPE
from subprocess import check_call
from subprocess import PIPE, check_call
from typing import List # novm
import llnl.util.tty as tty
import llnl.util.filesystem as fs
from llnl.util.filesystem import working_dir, force_remove
import llnl.util.tty as tty
from llnl.util.filesystem import force_remove, working_dir
from spack.package import PackageBase, run_after, run_before
from spack.util.executable import Executable

View file

@ -4,8 +4,8 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
from llnl.util.filesystem import install, mkdirp
import llnl.util.tty as tty
from llnl.util.filesystem import install, mkdirp
from spack.build_systems.cmake import CMakePackage
from spack.package import run_after

View file

@ -10,10 +10,11 @@
import re
from typing import List # novm
import spack.build_environment
from llnl.util.filesystem import working_dir
from spack.directives import depends_on, variant, conflicts
from spack.package import PackageBase, InstallError, run_after
import spack.build_environment
from spack.directives import conflicts, depends_on, variant
from spack.package import InstallError, PackageBase, run_after
# Regex to extract the primary generator from the CMake generator
# string.

View file

@ -3,10 +3,9 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from spack.package import PackageBase
from spack.directives import depends_on, variant, conflicts
import spack.variant
from spack.directives import conflicts, depends_on, variant
from spack.package import PackageBase
class CudaPackage(PackageBase):

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import spack.util.url
import spack.package
import spack.util.url
class GNUMirrorPackage(spack.package.PackageBase):

View file

@ -4,26 +4,32 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import sys
import glob
import tempfile
import re
import inspect
import os
import re
import sys
import tempfile
import xml.etree.ElementTree as ElementTree
import llnl.util.tty as tty
from llnl.util.filesystem import (
HeaderList,
LibraryList,
ancestor,
filter_file,
find_headers,
find_libraries,
find_system_libraries,
install,
)
from llnl.util.filesystem import \
install, ancestor, filter_file, \
HeaderList, find_headers, \
LibraryList, find_libraries, find_system_libraries
from spack.version import Version, ver
from spack.package import PackageBase, run_after, InstallError
from spack.build_environment import dso_suffix
from spack.package import InstallError, PackageBase, run_after
from spack.util.environment import EnvironmentModifications
from spack.util.executable import Executable
from spack.util.prefix import Prefix
from spack.build_environment import dso_suffix
from spack.version import Version, ver
# A couple of utility functions that might be useful in general. If so, they
# should really be defined elsewhere, unless deemed heretical.

View file

@ -9,6 +9,7 @@
import llnl.util.tty as tty
from llnl.util.filesystem import working_dir
from spack.package import PackageBase, run_after

View file

@ -5,6 +5,7 @@
from llnl.util.filesystem import install_tree, working_dir
from spack.directives import depends_on
from spack.package import PackageBase, run_after
from spack.util.executable import which

View file

@ -9,6 +9,7 @@
from typing import List # novm
from llnl.util.filesystem import working_dir
from spack.directives import depends_on, variant
from spack.package import PackageBase, run_after

View file

@ -8,16 +8,16 @@
"""
import getpass
import shutil
import platform
import shutil
from os.path import basename, dirname, isdir
from llnl.util.filesystem import find_headers, find_libraries, join_path
from spack.package import Package
from spack.util.environment import EnvironmentModifications
from spack.util.executable import Executable
from llnl.util.filesystem import find_headers, find_libraries, join_path
class IntelOneApiPackage(Package):
"""Base class for Intel oneAPI packages."""

View file

@ -7,10 +7,11 @@
import inspect
import os
from llnl.util.filesystem import filter_file
from spack.directives import extends
from spack.package import PackageBase, run_after
from spack.util.executable import Executable
from llnl.util.filesystem import filter_file
class PerlPackage(PackageBase):

View file

@ -6,14 +6,20 @@
import os
import shutil
import llnl.util.tty as tty
from llnl.util.filesystem import (
filter_file,
find,
get_filetype,
path_contains_subdirectory,
same_path,
working_dir,
)
from llnl.util.lang import match_predicate
from spack.directives import extends
from spack.package import PackageBase, run_after
from llnl.util.filesystem import (working_dir, get_filetype, filter_file,
path_contains_subdirectory, same_path, find)
from llnl.util.lang import match_predicate
import llnl.util.tty as tty
class PythonPackage(PackageBase):
"""Specialized class for packages that are built using Python

View file

@ -7,6 +7,7 @@
import inspect
from llnl.util.filesystem import working_dir
from spack.directives import depends_on
from spack.package import PackageBase, run_after

View file

@ -75,10 +75,9 @@
# does not like its directory structure.
#
from spack.package import PackageBase
from spack.directives import depends_on, variant, conflicts
import spack.variant
from spack.directives import conflicts, depends_on, variant
from spack.package import PackageBase
class ROCmPackage(PackageBase):

View file

@ -6,10 +6,11 @@
import inspect
import os
from llnl.util.filesystem import find, working_dir, join_path
import llnl.util.tty as tty
from llnl.util.filesystem import find, join_path, working_dir
from spack.directives import depends_on, extends
from spack.package import PackageBase, run_after
import llnl.util.tty as tty
class SIPPackage(PackageBase):

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import spack.util.url
import spack.package
import spack.util.url
class SourceforgePackage(spack.package.PackageBase):

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import spack.util.url
import spack.package
import spack.util.url
class SourcewarePackage(spack.package.PackageBase):

View file

@ -6,11 +6,11 @@
import inspect
from llnl.util.filesystem import working_dir
from spack.directives import depends_on
from spack.package import PackageBase, run_after
from llnl.util.filesystem import working_dir
class WafPackage(PackageBase):
"""Specialized class for packages that are built using the

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import spack.util.url
import spack.package
import spack.util.url
class XorgPackage(spack.package.PackageBase):

View file

@ -9,10 +9,10 @@
import llnl.util.lang
from llnl.util.filesystem import mkdirp
import spack.error
import spack.paths
import spack.config
import spack.error
import spack.fetch_strategy
import spack.paths
import spack.util.file_cache
import spack.util.path

View file

@ -21,6 +21,7 @@
import llnl.util.filesystem as fs
import llnl.util.tty as tty
import spack
import spack.binary_distribution as bindist
import spack.cmd
@ -39,7 +40,6 @@
from spack.error import SpackError
from spack.spec import Spec
JOB_RETRY_CONDITIONS = [
'always',
]

View file

@ -5,19 +5,20 @@
from __future__ import print_function
import argparse
import os
import re
import sys
import argparse
import ruamel.yaml as yaml
import ruamel.yaml as yaml
import six
from ruamel.yaml.error import MarkedYAMLError
import llnl.util.tty as tty
from llnl.util.filesystem import join_path
from llnl.util.lang import attr_setdefault, index_by
from llnl.util.tty.colify import colify
from llnl.util.tty.color import colorize
from llnl.util.filesystem import join_path
import spack.config
import spack.error
@ -27,8 +28,6 @@
import spack.store
import spack.util.spack_json as sjson
import spack.util.string
from ruamel.yaml.error import MarkedYAMLError
# cmd has a submodule called "list" so preserve the python list module
python_list = list

View file

@ -9,7 +9,6 @@
import spack.cmd.common.arguments as arguments
import spack.environment as ev
description = 'add a spec to an environment'
section = "environments"
level = "long"

View file

@ -17,7 +17,6 @@
import spack.paths
import spack.report
description = "run analyzers on installed packages"
section = "analysis"
level = "long"

View file

@ -8,8 +8,10 @@
import collections
import archspec.cpu
import llnl.util.tty.colify as colify
import llnl.util.tty.color as color
import spack.architecture as architecture
description = "print architecture information about this machine"

View file

@ -3,10 +3,10 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import llnl.util.tty.color as cl
import spack.audit
import spack.repo
description = "audit configuration files, packages, etc."
section = "system"
level = "short"

View file

@ -8,16 +8,15 @@
import sys
import llnl.util.tty as tty
from llnl.util.lang import pretty_date
from llnl.util.filesystem import working_dir
from llnl.util.lang import pretty_date
from llnl.util.tty.colify import colify_table
import spack.util.spack_json as sjson
import spack.paths
import spack.repo
from spack.util.executable import which
import spack.util.spack_json as sjson
from spack.cmd import spack_is_git_repo
from spack.util.executable import which
description = "show contributors to packages"
section = "developer"

View file

@ -8,10 +8,12 @@
import sys
import llnl.util.tty as tty
import spack.architecture
import spack.binary_distribution as bindist
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.config
import spack.environment as ev
import spack.hash_types as ht
import spack.mirror
@ -19,17 +21,12 @@
import spack.repo
import spack.spec
import spack.store
import spack.config
import spack.repo
import spack.store
import spack.util.url as url_util
from spack.cmd import display_specs
from spack.error import SpecError
from spack.spec import Spec, save_dependency_spec_yamls
from spack.util.string import plural
from spack.cmd import display_specs
description = "create, download and install binary packages"
section = "packaging"
level = "long"

View file

@ -15,7 +15,7 @@
import spack.stage
import spack.util.crypto
from spack.util.naming import valid_fully_qualified_module_name
from spack.version import ver, Version
from spack.version import Version, ver
description = "checksum available versions of a package"
section = "packaging"

View file

@ -14,6 +14,7 @@
from six.moves.urllib.parse import urlencode
import llnl.util.tty as tty
import spack.binary_distribution as bindist
import spack.ci as spack_ci
import spack.cmd.buildcache as buildcache
@ -24,7 +25,6 @@
import spack.util.url as url_util
import spack.util.web as web_util
description = "manage continuous integration pipelines"
section = "build"
level = "long"

View file

@ -10,15 +10,14 @@
import llnl.util.tty as tty
import spack.caches
import spack.config
import spack.cmd.test
import spack.cmd.common.arguments as arguments
import spack.cmd.test
import spack.config
import spack.main
import spack.repo
import spack.stage
from spack.paths import lib_path, var_path
description = "remove temporary build files and/or downloaded archives"
section = "build"
level = "long"

View file

@ -14,7 +14,9 @@
import llnl.util.filesystem as fs
import llnl.util.tty as tty
from llnl.util.argparsewriter import (
ArgparseWriter, ArgparseRstWriter, ArgparseCompletionWriter
ArgparseCompletionWriter,
ArgparseRstWriter,
ArgparseWriter,
)
from llnl.util.tty.colify import colify
@ -23,7 +25,6 @@
import spack.paths
from spack.main import section_descriptions
description = "list available spack commands"
section = "developer"
level = "long"

View file

@ -8,10 +8,11 @@
import os
import llnl.util.tty as tty
import spack.build_environment as build_environment
import spack.paths
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.paths
from spack.util.environment import dump_environment, pickle_environment

View file

@ -7,16 +7,18 @@
import argparse
import sys
from six import iteritems
import llnl.util.tty as tty
import spack.compilers
import spack.config
import spack.spec
from llnl.util.lang import index_by
from llnl.util.tty.colify import colify
from llnl.util.tty.color import colorize
from spack.spec import CompilerSpec, ArchSpec
import spack.compilers
import spack.config
import spack.spec
from spack.spec import ArchSpec, CompilerSpec
description = "manage compilers"
section = "system"

View file

@ -10,15 +10,16 @@
import llnl.util.filesystem as fs
import llnl.util.tty as tty
import spack.config
import spack.cmd.common.arguments
import spack.schema.env
import spack.config
import spack.environment as ev
import spack.repo
import spack.schema.env
import spack.schema.packages
import spack.store
import spack.util.spack_yaml as syaml
from spack.util.editor import editor
import spack.store
import spack.repo
description = "get and set configuration options"
section = "config"

View file

@ -4,6 +4,7 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import os.path
import spack.container
import spack.monitor

View file

@ -11,16 +11,23 @@
import llnl.util.tty as tty
from llnl.util.filesystem import mkdirp
import spack.util.web
import spack.repo
import spack.stage
import spack.util.web
from spack.spec import Spec
from spack.url import (
UndetectableNameError,
UndetectableVersionError,
parse_name,
parse_version,
)
from spack.util.editor import editor
from spack.util.executable import which, ProcessError
from spack.util.naming import mod_to_class
from spack.util.naming import simplify_name, valid_fully_qualified_module_name
from spack.url import UndetectableNameError, UndetectableVersionError
from spack.url import parse_name, parse_version
from spack.util.executable import ProcessError, which
from spack.util.naming import (
mod_to_class,
simplify_name,
valid_fully_qualified_module_name,
)
description = "create a new package file"
section = "packaging"

View file

@ -14,18 +14,18 @@
installation and its deprecator.
'''
from __future__ import print_function
import argparse
import os
import llnl.util.tty as tty
import spack.cmd
import spack.store
import spack.cmd.common.arguments as arguments
import spack.environment as ev
from spack.error import SpackError
import spack.store
from spack.database import InstallStatuses
from spack.error import SpackError
description = "Replace one package with another via symlinks"
section = "admin"

View file

@ -3,14 +3,14 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import sys
import os
import sys
import llnl.util.tty as tty
import spack.config
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.config
import spack.repo
description = "developer build: build from code in current working directory"

View file

@ -10,7 +10,6 @@
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
from spack.error import SpackError
description = "add a spec to an environment's dev-build information"

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import glob
import os
import llnl.util.tty as tty

View file

@ -8,22 +8,21 @@
import sys
from collections import namedtuple
import llnl.util.tty as tty
import llnl.util.filesystem as fs
import llnl.util.tty as tty
from llnl.util.tty.colify import colify
from llnl.util.tty.color import colorize
import spack.config
import spack.schema.env
import spack.cmd.common.arguments
import spack.cmd.install
import spack.cmd.uninstall
import spack.cmd.modules
import spack.cmd.common.arguments as arguments
import spack.cmd.install
import spack.cmd.modules
import spack.cmd.uninstall
import spack.config
import spack.environment as ev
import spack.schema.env
import spack.util.string as string
description = "manage virtual environments"
section = "environments"
level = "short"

View file

@ -9,9 +9,9 @@
import llnl.util.tty as tty
from llnl.util.tty.colify import colify
import spack.environment as ev
import spack.cmd as cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.repo
import spack.store
from spack.filesystem_view import YamlFilesystemView

View file

@ -10,10 +10,12 @@
import sys
from collections import defaultdict, namedtuple
import six
import llnl.util.filesystem
import llnl.util.tty as tty
import llnl.util.tty.colify as colify
import six
import spack
import spack.cmd
import spack.cmd.common.arguments

View file

@ -9,17 +9,17 @@
import os
import sys
import llnl.util.lang
import llnl.util.tty as tty
import llnl.util.tty.color as color
import llnl.util.lang
import spack.environment as ev
import spack.repo
import spack.cmd as cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.repo
import spack.user_environment as uenv
from spack.util.string import plural
from spack.database import InstallStatuses
from spack.util.string import plural
description = "list and search installed packages"
section = "basic"

View file

@ -9,7 +9,6 @@
import spack.cmd.style
description = "alias for spack style (deprecated)"
section = spack.cmd.style.section
level = spack.cmd.style.level

View file

@ -3,8 +3,8 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import os
import argparse
import os
import spack.binary_distribution
import spack.cmd.common.arguments as arguments

View file

@ -11,7 +11,7 @@
import spack.cmd.common.arguments as arguments
import spack.config
import spack.store
from spack.graph import graph_dot, graph_ascii
from spack.graph import graph_ascii, graph_dot
description = "generate graphs of package dependency relationships"
section = "basic"

View file

@ -4,6 +4,7 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import sys
from llnl.util.tty.color import colorize
description = "get help on spack and its commands"

View file

@ -6,6 +6,7 @@
from __future__ import print_function
import textwrap
from six.moves import zip_longest
import llnl.util.tty as tty
@ -13,10 +14,9 @@
from llnl.util.tty.colify import colify
import spack.cmd.common.arguments as arguments
import spack.fetch_strategy as fs
import spack.repo
import spack.spec
import spack.fetch_strategy as fs
description = 'get detailed information on a particular package'
section = 'basic'

View file

@ -23,7 +23,6 @@
from spack.error import SpackError
from spack.installer import PackageInstaller
description = "build and install packages"
section = "build"
level = "short"

View file

@ -3,23 +3,22 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
from __future__ import division
from __future__ import division, print_function
import argparse
import fnmatch
import json
import math
import os
import re
import sys
import math
import json
import llnl.util.tty as tty
from llnl.util.tty.colify import colify
import spack.cmd.common.arguments as arguments
import spack.dependency
import spack.repo
import spack.cmd.common.arguments as arguments
from spack.version import VersionList
if sys.version_info > (3, 1):

View file

@ -8,9 +8,9 @@
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.util.environment
import spack.user_environment as uenv
import spack.store
import spack.user_environment as uenv
import spack.util.environment
description = "add package to the user environment"
section = "user environment"

View file

@ -6,12 +6,13 @@
from __future__ import print_function
import os
import llnl.util.tty as tty
import spack.environment as ev
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment
import spack.environment as ev
import spack.paths
import spack.repo
import spack.stage

View file

@ -6,7 +6,8 @@
import sys
import llnl.util.tty as tty
from spack.util.log_parse import parse_log_events, make_log_context
from spack.util.log_parse import make_log_context, parse_log_events
description = "filter errors and warnings from build logs"
section = "build"

View file

@ -12,7 +12,6 @@
import llnl.util.tty.color as color
from llnl.util.tty.colify import colify
import spack.repo
description = "get information about package maintainers"

View file

@ -7,16 +7,16 @@
import sys
from llnl.util import tty
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.error
import spack.package
import spack.cmd.common.arguments as arguments
import spack.repo
import spack.store
from spack.database import InstallStatuses
from llnl.util import tty
description = "mark packages as explicitly or implicitly installed"
section = "admin"
level = "long"

View file

@ -17,9 +17,8 @@
import spack.repo
import spack.util.url as url_util
import spack.util.web as web_util
from spack.spec import Spec
from spack.error import SpackError
from spack.spec import Spec
from spack.util.spack_yaml import syaml_dict
description = "manage mirrors (source and binary)"

View file

@ -4,7 +4,7 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import argparse
from typing import Dict, Callable # novm
from typing import Callable, Dict # novm
import llnl.util.tty as tty

View file

@ -13,12 +13,11 @@
from llnl.util import filesystem, tty
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.config
import spack.modules
import spack.repo
import spack.modules.common
import spack.cmd.common.arguments as arguments
import spack.repo
description = "manipulate module files"
section = "environment"

View file

@ -7,6 +7,7 @@
import os
import llnl.util.filesystem
import spack.cmd.common.arguments
import spack.cmd.modules

View file

@ -5,7 +5,6 @@
import spack.monitor
description = "interact with a monitor server"
section = "analysis"
level = "long"

View file

@ -5,10 +5,9 @@
import llnl.util.tty as tty
import spack.repo
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.repo
description = "patch expanded archive sources in preparation for install"
section = "build"

View file

@ -9,8 +9,8 @@
import re
import llnl.util.tty as tty
from llnl.util.tty.colify import colify
from llnl.util.filesystem import working_dir
from llnl.util.tty.colify import colify
import spack.cmd
import spack.cmd.common.arguments as arguments

View file

@ -3,9 +3,10 @@
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import six
import sys
import six
import llnl.util.tty.colify as colify
import spack.cmd

View file

@ -5,12 +5,12 @@
from __future__ import print_function
import os
import sys
import code
import argparse
import code
import os
import platform
import runpy
import sys
import llnl.util.tty as tty

View file

@ -9,7 +9,6 @@
import spack.cmd.common.arguments as arguments
import spack.environment as ev
description = 'remove specs from an environment'
section = "environments"
level = "long"

View file

@ -8,6 +8,7 @@
import os
import llnl.util.tty as tty
import spack.config
import spack.repo
import spack.util.path

View file

@ -4,6 +4,7 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os
import llnl.util.tty as tty
@ -11,7 +12,6 @@
import spack.repo
description = "list downloadable resources (tarballs, repos, patches, etc.)"
section = "basic"
level = "long"

View file

@ -13,9 +13,9 @@
import spack
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.hash_types as ht
import spack.spec
import spack.store
import spack.hash_types as ht
description = "show what would be installed, given a spec"
section = "build"

View file

@ -7,10 +7,10 @@
import llnl.util.tty as tty
import spack.environment as ev
import spack.repo
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.repo
import spack.stage
description = "expand downloaded archive in preparation for install"

View file

@ -4,22 +4,23 @@
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
from __future__ import print_function
import os
import argparse
import textwrap
import inspect
import fnmatch
import inspect
import os
import re
import shutil
import sys
import textwrap
import llnl.util.tty as tty
import llnl.util.tty.colify as colify
import spack.install_test
import spack.environment as ev
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.install_test
import spack.package
import spack.repo
import spack.report

View file

@ -18,7 +18,6 @@
from spack.util.executable import which
from spack.util.spack_yaml import syaml_dict
description = "set up spack for our tutorial (WARNING: modifies config!)"
section = "config"
level = "long"

View file

@ -9,7 +9,6 @@
import spack.cmd.common.arguments as arguments
import spack.environment as ev
description = 'remove specs from an environment'
section = "environments"
level = "long"

View file

@ -5,21 +5,21 @@
from __future__ import print_function
import sys
import itertools
import spack.cmd
import spack.environment as ev
import spack.error
import spack.package
import spack.cmd.common.arguments as arguments
import spack.repo
import spack.store
from spack.database import InstallStatuses
import sys
from llnl.util import tty
from llnl.util.tty.colify import colify
import spack.cmd
import spack.cmd.common.arguments as arguments
import spack.environment as ev
import spack.error
import spack.package
import spack.repo
import spack.store
from spack.database import InstallStatuses
description = "remove installed packages"
section = "build"
level = "short"

Some files were not shown because too many files have changed in this diff Show more