edgetest is a tox-inspired python library that will loop through your project's dependencies, and check if your project is compatible with the latest version of each dependency

Overview

Bleeding edge dependency testing

PyPI - Python Version Code style: black PyPI version Anaconda-Server Badge

Full Documentation

edgetest is a tox-inspired python library that will loop through your project's dependencies, and check if your project is compatible with the latest version of each dependency. It does this by:

  • creating a virtual environment,
  • installing your local package into the environment,
  • upgrading specified dependency package(s), and
  • running your test command.

For example, if you depend on pandas>=0.25.1,<=1.0.0, edgetest will test your project against the most current pandas version (say 1.3.4), so you know if you can safely update your dependency to pandas>=0.25.1,<=1.3.4 or not.

Table Of Contents

Install

Create a conda environment with Python 3.7+ and install from PyPI:

$ python -m pip install edgetest

or conda-forge:

$ conda install -c conda-forge edgetest

Getting Started

edgetest allows multi-package, bleeding edge dependency testing. Suppose you have a package, mypackage, with the following requirements.txt:

pandas>=0.25.1,<=1.0.0
...

edgetest allows you to test your package against the latest version of pandas. If you run

$ edgetest

the package will

  1. Create a virtual environment in the .edgetest folder,
  2. Install the local mypackage: .edgetest/pandas/bin/python -m pip install .,
  3. Upgrade pandas: .edgetest/pandas/bin/python -m pip install pandas --upgrade,
  4. Run .edgetest/pandas/bin/python -m pytest, and
  5. Repeat steps 1-4 for all packages in requirements.txt.

After you run the command, you should get console output similar to the following:

============= =============== =================== =================
 Environment   Passing tests   Upgraded packages   Package version
------------- --------------- ------------------- -----------------
 pandas        True            pandas              1.3.4
============= =============== =================== =================

Options

See the advanced usage page.

Plugins

Current plugins include:

Plugin Description
edgetest-conda Uses conda or mamba for environment creation instead of venv.
edgetest-hub Creates a pull request in your GitHub repository with the dependency updates.
edgetest-pip-tools Refreshes a locked requirements file based on the updated dependency pins.

Contributing

See our developer documentation.

We welcome and appreciate your contributions! Before we can accept any contributions, we ask that you please be sure to sign the Contributor License Agreement (CLA)

This project adheres to the Open Source Code of Conduct. By participating, you are expected to honor this code.

License

Apache-2.0

Roadmap

Roadmap details can be found here.

Comments
  • Better support for extras in the upgrade portion

    Better support for extras in the upgrade portion

    Right now if you want to upgrade a package which has mypackage[extras] you need to update it as mypackage. I think we can provide better support for the extras to align better as there could be cases where the items in extras are not being bumped properly.

    @ak-gupta thoughts?

    bug enhancement help wanted 
    opened by fdosani 4
  • Toml support

    Toml support

    Closes #47

    This feature adds in TOML support to co-exist along side setup.cfg support:

    • created mirrored functions between the 2 to keep the logic separate.
      • _convert_toml_array_to_string, parse_toml, and upgrade_pyproject_toml
    • new dependency is added with tomlkit.
    • added in some new unit tests
    opened by fdosani 3
  • Upgrade hook

    Upgrade hook

    Description

    Adding in a new hook specifically for the update/upgrade portion. this will enable plugins to inject custom code

    Fixes #39

    Type of change

    • [ ] Bug fix (non-breaking change which fixes an issue)
    • [x] New feature (non-breaking change which adds functionality)
    • [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
    • [x] This change requires a documentation update

    Checklist:

    • [x] I have performed a self-review of my own code
    • [x] I have commented my code, particularly in hard-to-understand areas
    • [x] I have made corresponding changes to the documentation
    • [x] My changes generate no new warnings
    • [x] I have added tests that prove my fix is effective or that my feature works
    • [x] New and existing unit tests pass locally with my changes
    • [x] New and existing integration tests pass locally with my changes
    • [ ] Any dependent changes have been merged and published in downstream modules
    opened by fdosani 2
  • Support for pyproject.toml

    Support for pyproject.toml

    Based on PEP 518 here: https://peps.python.org/pep-0518/#overview-of-file-formats-considered It seems like pyproject.toml is preferred over setup.cfg. We should include some support here for various types. So far:

    • setup.cfg (existing)
    • pyproject.toml (new)

    @ak-gupta thoughts?

    enhancement help wanted question 
    opened by fdosani 1
  • edgetest force pushes overwrite user commits

    edgetest force pushes overwrite user commits

    edgetest opened this PR to update the dask[dataframe] version yesterday

    https://github.com/capitalone/rubicon-ml/pull/221

    I had to manually apply those version updates to the environment files in my repo, which caused the whitesource scan to fail. so, I left the PR open overnight to come back to it today and finish. overnight, edgetest again noticed that dask[dataframe] needed to be updated so it created a branch with the same name as the one I had committed my manual changes to yesterday and forced pushed, overwriting the branch

    edgetest should be able to recognize that it already opened the PR to update dask[dataframe] and not force push the same update

    I also imagine that if a second library needed to be updated while the PR for a previous one is still open we'd see the same behavior since the branch always seems to be named edgetest-patch

    opened by ryanSoley 1
  • Create a new plugin hook for Upgrading packages

    Create a new plugin hook for Upgrading packages

    So currently the packages are always upgraded via pip here.

    Proposal is to make this a hook, something like:

    @hookspec(firstresult=True)
    def run_update(python_path: str, upgrade: List):
        """Update packages from upgrade list.
    
        Parameters
        ----------
        python_path : str
            The path to the python executable.
        upgrade : list
            The list of packages to upgrade
       
        Raises
        ------
        RuntimeError
            Error raised if the packages cannot be updated.
        """
    

    This directly links back to a request in the conda plugin: https://github.com/capitalone/edgetest-conda/issues/30 Enabling this functionality will enable the plugin to provide a spec to upgrade via conda.

    enhancement help wanted question 
    opened by fdosani 0
  • Release 2022.6.0

    Release 2022.6.0

    Release 2022.6.0

    Feature:

    • github report format output option (#36)

    House keeping:

    • edgetest bumps (#24, #29, #33)
    • pre-commit bumps (#34)
    • WhiteSource Configuration Migration (#31)
    opened by fdosani 0
  • Update gen_report to print out in the github format

    Update gen_report to print out in the github format

    This feature is needed more of a result for providing the report output in the github format and tied to a request in edgetest-hub: https://github.com/capitalone/edgetest-hub/issues/28

    enhancement 
    opened by fdosani 0
  • inherit additional deps from an environment in `[edgetest.envs.core]`

    inherit additional deps from an environment in `[edgetest.envs.core]`

    it'd be nice if I only had to specify my library's dependencies in [edgetest.envs.core] instead of needing to remember to add every new test dependency. there's already a considerable amount of env declaration duplication required throughout the various package managing tools, so it'd be nice if there wasn't another layer of duplication here

    I'd like to only need to specify the libraries I want to try updating in [edgetest.envs.core]. I'd like to inherit the rest of the dependencies from an environment file. for example:

    [edgetest.envs.core]
    python_version = 3.9
    conda_install = 
    	./environment.yml
    extras = 
    	all
    upgrade = 
    	click
    	dask[dataframe]
    	fsspec
    	intake[dataframe]
    	pandas
    	pyarrow
    	PyYAML
    	s3fs
    	prefect
    	dash
    	dash-bootstrap-components
    
    opened by ryanSoley 2
  • specify which versioning scheme parts to test & auto-update

    specify which versioning scheme parts to test & auto-update

    I'm imagining a scenario where packages using edgetest with a lot of dependencies may need to release their package quite frequently to account for updated dependencies. for example, if I have pyarrow<=7.0.0,>=0.18.0 defined in my setup with the upper bound as required by edgetest and all of a sudden a major bug is found in pyarrow 7.0.0 that needs an immediate upgrade to 7.0.1, I now require an immediate update to and release of my package before users can use it with the fixed pyarrow

    I think it could be useful to be able to specify pyarrow<=7.0,>=0.18.0 (explicitly leaving off the patch version) and having that mean that edgetest will only look for, test, and PR upgrades to the major/minor versions and my setup can automatically allow any update to the patch version to be useable. (I'm assuming that if I were to say pyarrow<=7.0,>=0.18.0 edgetest would currently look for pyarrow 7.0.1 next time it ran, not 7.1 - if that's incorrect then let me know)

    I'm coming from a mindset of avoiding upper pins in general to avoid issues like this, but I absolutely see the value in having them (and especially in having them tested) so I think it'd be nice to be able to configure some kind of "compromise" between the two ideas

    I'm also aware that different versioning schemes could cause headaches here if we were to try something super automatic, so that's something to consider

    thoughts @fdosani @ak-gupta ?

    enhancement question 
    opened by ryanSoley 3
Releases(v2022.11.0)
  • v2022.11.0(Nov 7, 2022)

    What's Changed

    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/46
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/49
    • Toml support by @fdosani in https://github.com/capitalone/edgetest/pull/48
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/51
    • Docs housekeeping by @fdosani in https://github.com/capitalone/edgetest/pull/52
    • Update mypy setting for empty-body by @fdosani in https://github.com/capitalone/edgetest/pull/54
    • Release 2022.11.0 by @fdosani in https://github.com/capitalone/edgetest/pull/53

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2022.7.0...v2022.11.0

    Source code(tar.gz)
    Source code(zip)
  • v2022.7.0(Jul 15, 2022)

    What's Changed

    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/38
    • Upgrade hook by @fdosani in https://github.com/capitalone/edgetest/pull/40
    • adding in conf to run_udate hookspec by @fdosani in https://github.com/capitalone/edgetest/pull/41
    • Bump 2022.6.0 to 2022.7.0 by @fdosani in https://github.com/capitalone/edgetest/pull/42
    • Release 2022.7.0 by @fdosani in https://github.com/capitalone/edgetest/pull/43

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2022.6.0...v2022.7.0

    Source code(tar.gz)
    Source code(zip)
  • v2022.6.0(Jun 23, 2022)

    What's Changed

    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/24
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/29
    • WhiteSource Configuration Migration by @mend-for-github-com in https://github.com/capitalone/edgetest/pull/31
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/33
    • bump pre-commit versions by @fdosani in https://github.com/capitalone/edgetest/pull/34
    • adding logic to handle github report format by @fdosani in https://github.com/capitalone/edgetest/pull/36
    • Release 2022.6.0 by @fdosani in https://github.com/capitalone/edgetest/pull/37

    New Contributors

    • @mend-for-github-com made their first contribution in https://github.com/capitalone/edgetest/pull/31

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2022.4.0...v2022.6.0

    Source code(tar.gz)
    Source code(zip)
  • v2022.4.0(Apr 19, 2022)

    What's Changed

    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/18
    • updating black version in precommit file by @fdosani in https://github.com/capitalone/edgetest/pull/19
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/20
    • bumping version to 2022.4.0 by @fdosani in https://github.com/capitalone/edgetest/pull/21
    • Release 2022.4.0 by @fdosani in https://github.com/capitalone/edgetest/pull/23

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2022.3.1...v2022.4.0

    Source code(tar.gz)
    Source code(zip)
  • v2022.3.1(Mar 28, 2022)

    What's Changed

    • Extras upgrade bug fix by @fdosani in https://github.com/capitalone/edgetest/pull/15
    • Release v2022.3.1 by @fdosani in https://github.com/capitalone/edgetest/pull/16

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2022.3.0...v2022.3.1

    Source code(tar.gz)
    Source code(zip)
  • v2022.3.0(Mar 22, 2022)

    What's Changed

    • meta edgetest run by @fdosani in https://github.com/capitalone/edgetest/pull/6
    • edgetest action by @fdosani in https://github.com/capitalone/edgetest/pull/8
    • Changes by run-edgetest action by @github-actions in https://github.com/capitalone/edgetest/pull/9
    • Bump 2021.12.5 to 2022.3.0 by @fdosani in https://github.com/capitalone/edgetest/pull/11
    • Release v2022.3.0 by @fdosani in https://github.com/capitalone/edgetest/pull/12

    New Contributors

    • @github-actions made their first contribution in https://github.com/capitalone/edgetest/pull/9

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2021.12.5...v2022.3.0

    Source code(tar.gz)
    Source code(zip)
  • v2021.12.5(Dec 18, 2021)

    What's Changed

    • setup.cfg fix by @fdosani in https://github.com/capitalone/edgetest/pull/4
    • Release v2021.12.5 by @fdosani in https://github.com/capitalone/edgetest/pull/5

    Full Changelog: https://github.com/capitalone/edgetest/compare/v2021.12.4...v2021.12.5

    Source code(tar.gz)
    Source code(zip)
  • v2021.12.4(Dec 17, 2021)

    What's Changed

    • Bump 2021.12.3 to 2021.12.4 by @fdosani in https://github.com/capitalone/edgetest/pull/2
    • Release v2021.12.4 by @fdosani in https://github.com/capitalone/edgetest/pull/3

    New Contributors

    • @fdosani made their first contribution in https://github.com/capitalone/edgetest/pull/2

    Full Changelog: https://github.com/capitalone/edgetest/commits/v2021.12.4

    Source code(tar.gz)
    Source code(zip)
Owner
Capital One
We’re an open source-first organization — actively using, contributing to and managing open source software projects.
Capital One
A quick experiment to demonstrate Metamath formula parsing, where the grammar is embedded in a few additional 'syntax axioms'.

Warning: Hacked-up code ahead. (But it seems to work...) What it does This demonstrates an idea which I posted about several times on the Metamath mai

Marnix Klooster 1 Oct 21, 2021
A multi-platform fuzzer for poking at userland binaries and servers

litefuzz A multi-platform fuzzer for poking at userland binaries and servers litefuzz intro why how it works what it does what it doesn't do support p

52 Nov 18, 2022
A check numbers python module

Made with Python3 (C) @FayasNoushad Copyright permission under MIT License License - https://github.com/FayasNoushad/Numbers/blob/main/LICENSE Deplo

Fayas Noushad 3 Nov 28, 2021
A modern message based async agent framework

Munggoggo A modern message based async agent framework An asyncio based agent platform written in Python and based on RabbitMQ. Agents are isolated pr

24 Dec 28, 2022
Navigate to your directory of choice the proceed as follows

Installation 🚀 Navigate to your directory of choice the proceed as follows; 1 .Clone the git repo and create a virtual environment Depending on your

Ondiek Elijah Ochieng 2 Jan 31, 2022
An implementation of multimap with per-item expiration backed up by Redis.

MultiMapWithTTL An implementation of multimap with per-item expiration backed up by Redis. Documentation: https://loggi.github.io/python-multimapwitht

Loggi 2 Jan 17, 2022
Goal: Enable awesome tooling for Bazel users of the C language family.

Hedron's Compile Commands Extractor for Bazel — User Interface What is this project trying to do for me? First, provide Bazel users cross-platform aut

Hedron Vision 290 Dec 26, 2022
A minimalist production ready plugin system

pluggy - A minimalist production ready plugin system This is the core framework used by the pytest, tox, and devpi projects. Please read the docs to l

pytest-dev 876 Jan 05, 2023
Example teacher bot for deployment to Chai app.

Create and share your own chatbot Here is the code for uploading the popular "Ms Harris (Teacher)" chatbot to the Chai app. You can tweak the config t

Chai 1 Jan 10, 2022
JLC2KICAD_lib is a python script that generate a component library for KiCad from the JLCPCB/easyEDA library.

JLC2KiCad_lib is a python script that generate a component library (schematic, footprint and 3D model) for KiCad from the JLCPCB/easyEDA library. This script requires Python 3.6 or higher.

Nicolas Toussaint 73 Dec 26, 2022
Moji sends text and fun facts from different APIs wit da use of a notification deamon

Moji sends text and fun facts from different APIs wit da use of a notification deamon. Can be runned via dmenu or rofi.

kshly 2 Jan 12, 2022
SWS Filters App - SWS Filters App With Python

SWS Filters App Fun 😅 ... Fun 😅 Click On photo and see 😂 😂 😂 Your Video rec

Sagar Jangid 3 Jul 07, 2022
RELATE is an Environment for Learning And TEaching

RELATE Relate is an Environment for Learning And TEaching RELATE is a web-based courseware package. It is set apart by the following features: Focus o

Andreas Klöckner 311 Dec 25, 2022
CaskDB is a disk-based, embedded, persistent, key-value store based on the Riak's bitcask paper, written in Python.

CaskDB - Disk based Log Structured Hash Table Store CaskDB is a disk-based, embedded, persistent, key-value store based on the Riak's bitcask paper, w

886 Dec 27, 2022
This is a simple SV calling package for diploid assemblies.

dipdiff This is a simple SV calling package for diploid assemblies. It uses a modified version of svim-asm. The package includes its own version minim

Mikhail Kolmogorov 11 Jan 05, 2023
My solutions for Advent of Code 2021 🌟🎄

🌟 Advent of Code 2021 🎄 My solutions for Advent of Code 2021. About · What is Advent of Code? · Contents · Usage · Table of puzzles (TODO: add final

Amanda P. Pinha 2 Dec 05, 2022
An a simple sistem code in python

AMS OS An a simple code in python ⁕¿What is AMS OS? AMS OS is an a simple sistem code writed in python. This code helps you with the cotidian task, yo

1 Nov 10, 2021
Canim1 - Simple python tool to search for packages without m1 wheels in poetry lockfiles

canim1 Usage Clone the repo. Run poetry install. Then you can use the tool: ❯ po

Korijn van Golen 1 Jan 25, 2022
The repository for AnyMacro: a Fusion360 Add-In

AnyMacro AnyMacro is an Autodesk® Fusion 360™ add-in for chaining multiple commands in a row to form Macros. Macros are created from a set of commands

1 Jan 07, 2022
This library attempts to abstract the handling of Sigma rules in Python

This library attempts to abstract the handling of Sigma rules in Python. The rules are parsed using a schema defined with pydantic, and can be easily loaded from YAML files into a structured Python o

Caleb Stewart 44 Oct 29, 2022