Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vendoring-compatible imports #316

Merged
merged 18 commits into from
Feb 17, 2021

Commits on Jan 14, 2021

  1. imports: Make exceptions-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    ac99f5d View commit details
    Browse the repository at this point in the history
  2. imports: Make formats-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    fe63e10 View commit details
    Browse the repository at this point in the history
  3. imports: Make hash-imports compatible with vendoring

    Make hash module imports compatible with the vendoring tool.
    
    This is trickier than the other cases:
    * "hash" is a builtin function, overloading that with module name
      seems bad
    * the resulting code "hash.digest(algorithm)" reads like hash is an
      object... Not ideal
    
    Luckily there are few functions in the module: Import the functions
    directly to avoid importing the module.
    Jussi Kukkonen committed Jan 14, 2021
    Configuration menu
    Copy the full SHA
    16dbb1c View commit details
    Browse the repository at this point in the history

Commits on Feb 11, 2021

  1. imports: Make "*keys"-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    787f965 View commit details
    Browse the repository at this point in the history
  2. imports: Make settings-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    dfe9039 View commit details
    Browse the repository at this point in the history
  3. imports: Make storage-imports compatible with vendoring

    Import only the FilesystemBackend class when needed: this is
    compatible with the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    dea2b2a View commit details
    Browse the repository at this point in the history
  4. imports: Make util-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    0f401fb View commit details
    Browse the repository at this point in the history
  5. imports: Make schema-import compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    af6ae6a View commit details
    Browse the repository at this point in the history
  6. gpg: Rename 'process' variables to 'gpg_process'

    The aim is to avoid potential conflict with 'process' module.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    b4a069f View commit details
    Browse the repository at this point in the history
  7. imports: Make process-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    e0f5a35 View commit details
    Browse the repository at this point in the history
  8. imports: Make ed25519-import compatible with vendoring

    Rename the import to make it clear this is the python module, use an
    import line that is compatible with vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    f64ac96 View commit details
    Browse the repository at this point in the history
  9. imports: Make gpg.util-imports compatible with vendoring

    Use gpg_util as local name to avoid potential conflicts with the other
    util module.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    3e2efa5 View commit details
    Browse the repository at this point in the history
  10. imports: Make gpg.exceptions-imports compatible with vendoring

    Importing individual errors avoids conflict with the other exceptions
    module in securesystemslib.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    fdfd258 View commit details
    Browse the repository at this point in the history
  11. imports: Make gpg.constants-imports compatible with vendoring

    Use "from securesystemslib import <mod>" instead of
    "import securesystemslib.<mod>" to make securesystemslib compatible with
    the vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    81d60f3 View commit details
    Browse the repository at this point in the history
  12. imports: Make gpg.common-import compatible with vendoring

    Importing the two functions individually seems reasonable here.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    5150c75 View commit details
    Browse the repository at this point in the history
  13. imports: tweak imports in gpg.constants

    The results of the import is same, but new style is compatible with
    vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    719d315 View commit details
    Browse the repository at this point in the history
  14. imports: Fix external imports (crypto, nacl)

    Modify the way nacl and cryptography imports are made to make them
    compatible with vendoring tool.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    f0fbeb0 View commit details
    Browse the repository at this point in the history
  15. gpg: Remove a circular dependency

    There is a circular dependency in
      gpg.constants -> gpg.rsa -> gpg.util -> gpg.constants
    
    This is not a problem on python3 or python2 when the imports are done
    with "import securesystemslib.<mod>" style. However with the
    "from securesystemslib import <mod>" style python2 decides this is a
    ImportError.
    
    Remove the circular dependency by moving the module variables from
    constants to another file.
    Jussi Kukkonen committed Feb 11, 2021
    Configuration menu
    Copy the full SHA
    25f112b View commit details
    Browse the repository at this point in the history