зеркало из
1
0
Форкнуть 0
Граф коммитов

39 Коммитов

Автор SHA1 Сообщение Дата
Scott Beddall 689bac0896
Remove unnecessary variable defaults (#37604)
* apply black and prepare for parsing the ci.yml so that we can understand if testproxy is enabled or disabled
* The language specific cert trust in Language-Settings has been updated to no longer globally set environment variables SSL_CERT_DIR, SSL_CERT_FILE, and REQUEST_CA_BUNDLE. These are dynamically set in proxy_startup.py
2024-09-27 11:59:35 -07:00
Scott Beddall f322ad3a5d
Fix `azure-sdk-tools` tests bitrot, add tools gh action check (#37580)
* encode the fact that azure-eventhub does not support pypy machines
* add azure-sdk-tools test workflow
* update cspell to account for new workflow
* fix matrix generation when no direct packages are present
* fix a test relying on folder ordering to NOT depend on that folder ordering
2024-09-26 14:53:34 -07:00
Scott Beddall 6697c47571
Nightly RC Verification Build for Python 3.13 (#37400)
* refactor the steps a bit. can we still build and test?
2024-09-20 16:53:26 -07:00
Jacob Lauzon df2d3973ab
Allow replace_dev_reqs to pull from prebuilt wheels (#34924) 2024-03-26 10:28:32 -07:00
Scott Beddall eb9924675b
Handle package-specific warning suppressions (#34289)
* handle package-specific suppressions. enable our 
un() to **fail** in the build stage
* suppressed build warnings -> suppressed skip warnings
2024-02-13 14:03:12 -08:00
Scott Beddall da947a9fce
Add `Optional` Environment (#32332)
* updates to eng/ci_tools and eng/test_tools.txt to allow necessary additions for compatibility
* added new namespace to azure-sdk-tools: ci_tools.scenario.
  * ci_tools.scenario is used to emplace any code that actually does the action of installing a dependency, replacing requirements, building on the fly, etc. This means that create_package_and_install and replace_dev_reqs both are moved into this module
* created tox environment 'optional'. This tox environment utilizes array items of pyproject.toml config item 'tool.azure-sdk-build.optional' to install requirements for specific test scenarios before invoking tests against them. These tests are run within a custom venv for each optional configuration item in pyproject.toml, location .tox/optional/<envname>/
  * the new 'optional' environment is enhanced to allow users to pass in the target environment EG: 'tox -e optional --root . -c ../../../eng/tox/tox.ini -- --optional no_requests'

Co-authored-by: Laurent Mazuel <laurent.mazuel@gmail.com>
Co-authored-by: McCoy Patiño <39780829+mccoyp@users.noreply.github.com>
2023-11-13 17:01:58 -08:00
Scott Beddall d88fdea88b
Adjust Build of Relative Dependencies (#32883)
* updated replace_dev_reqs to handle all cases of relative installs to handle local relative deeps _deeper_ than the target package. Previously only handled relative deps starting with ../
* added unit tests for replace_dev_reqs to ensure that packages are replaced (or left alone) as expected
* apply black
* update scenario to include 'here'. update test to use automatic tempdir cleanup per Kevin's feedback

---------

Co-authored-by: kdestin <101366538+kdestin@users.noreply.github.com>
2023-10-31 16:07:36 -07:00
kdestin ed8e8aba88
[engsys] ci: Fix `tox_harness.py` dropping package extras when rewriting dev_requirements.txt (#32864)
* ci: Don't drop extras when rewriting dev_requirements.txt
* fix: Preserve log that shows original and modified dev-requirements
2023-10-30 17:18:04 -07:00
Scott Beddall abe583dcc3
Cleaning up tox dispatch script (#32456)
* cleaning up setup_execute_tests. 
* removing code paths that have gone completely unused since being implemented (to mirror previous methodology if necessary). 
* cleaning up arguments that aren't used. cleaning up imports. 
* generally just tightening up of the script and clarifying it's purpose.
Co-authored-by: Scott Beddall <45376673+scbedd@users.noreply.github.com>
Co-authored-by: McCoy Patiño <39780829+mccoyp@users.noreply.github.com>
2023-10-12 17:16:03 -07:00
Scott Beddall a28103b2e4
Add Python 3.12 to build matrix (#31758)
* Add python 3.12 to platform matrix for tests
* Various updates to test_tools.txt and ci_tools.txt to enable compatibility with python 3.12 at test run time
* Adjust build matrix for metricsadvisor and tables to route python 3.11 from windows to ubuntu machine, bypassing issue #32409 
* Add manually built cffi and aiohttp to test_tools.txt to enable async recorded tests on python 3.12
* Various updates to minimum range in install_depend_packages.py. All due to various levels of support for py 3.12
* Add the concept of platform specific override for minimum version, allowing the invoking platform to further refine the selection from pypi
* Updates and extensions to tools/azure-sdk-tools to handle cleanup of git idx files with wonky permissions
* Disable latestdependency and mindependency in azure-eventhub-checkpointstoreblob-aio. Follow-up issue #32422 
* Various other small updates to enable further compatibility

Co-authored-by: Krista Pratico <krpratic@microsoft.com>
2023-10-10 17:19:22 -07:00
kdestin 982234bf05
[engsys] Migrate to tox4 (#30159)
* Remove references to {envbindir}

    tox prepends the {env_bin_dir} to $PATH, so commands
    will default to using the virtual environment first.

    See: https://tox.wiki/en/4.4.11/config.html#commands

    One of tox's core maintainers also discourages its use:
      https://github.com/tox-dev/tox/issues/2909#issuecomment-1409806654

* refactor: Write paths relative to git root, instead of package dir

    Uses an inline plugin (toxfile.py) to make a computed config
    value avaiable to tox environments.

* refactor: Rename {toxinidir} to {tox_root}

    {toxinidir} is an alias for {tox_root}, but {tox_root} is:
      * More clear: {tox_root} isn't necessarily where the ini file is
      * Shorter

* refactor: Flatten some commands that are no longer super long

* refactor: Make a pytest section

* refactor: Remove `changedir = {tox_root}`

    This is the default behavior, see:

    https://tox.wiki/en/4.4.11/config.html#change_dir-external

* fix: {distdir} is deprecated

    See: https://tox.wiki/en/latest/upgrading.html#removed-tox-ini-keys

* fix: Remove --ignore-installed from pip command

    --ignore-installed can break a python installation if multiple
    conflicting versions of a package are installed

* refactor: Add descriptions to all tox environments

* fix: Remove ineffective platform config

    platform = linux: linux
               macos: darwin
               windows: win32

    Setting the above in the base environment has no effect:
        * None of the environments have {linux,macos,windows} in the
          name, so the platform config is always empty.

* chore: Bump `tox` to `>4.4.11` and no longer install `tox-monorepo`

    tox4 natively solves what `tox-monorepo` was written to solve:
    `--root` lets you set `toxinidir` independently of the config
    file in use.

    4.4.11 was chosen as the cutoff since it was the first release to
    include a fix to `--root` that prevented `{work_dir}` from being
    changed when `{toxinidir}` was changed by `--root`.

    `tox-monorepo` should no longer be needed

* docs: Update CONTRIBUTING.md to use tox 4 commands

    * References to tox-monorepo were removed
    * Replaced discussion of `tox -l` with tox4's `tox list`
    * Updated examples to use `--root`

* docs: Make `azure-media-{videoanalyzer,analytics}-edge`'s DevTips.md point to CONTRIBUTING.md for tox

* docs: Remove remaining references to tox-monorepo

* doc: Use `--root` throughout documentation

* engsys: Make tox_harness set `{toxinidir}` when invoking tox

* engsys: Set required tox version in config

* docs: Use the new url for tox docs

* docs: Add a callout that TOX_* environment variables control defaults

    * TOX_CONFIG_DIR can be used to permanently set --conf
    * TOX_ROOT_DIR can be used to permanently set --root

* update packaging requirement everywhere it is used.

* fix cspell

* docs: Use `tox run` syntax throughout documentation

* engsys: Use `tox run` syntax in tox_harness.py

* docs: Replace – (U+2013 : EN DASH) with - (ASCII code 45)

* update pytest requirements + coverage.

* update virtualenv

* more conflicts resolved

* bringing in urllib3 restriction, aligning ci_tools.txt with test_tools.txt

* check_call requires a list of type string. if we append ['blah', 'blah'] we are actually inserting another array. just use regular array concatenation

* engsys: Tox uses `run` for serial execution and `run-parallel` for parallel`

* azure-core: Use `@pytest_asyncio.fixture` to mark an asyncio fixture

    See https://pytest-asyncio.readthedocs.io/en/latest/concepts.html#strict-mode

* pin coverage to newer version with no conflicts

* identify issue with missing code coverage being caused by wrongly named namespace (#30344)

* remove fix of dotfile!

* apply black formatting to resolve failing analyze step

* tox installing tox. probably not a good thing :)

* engsys: Remove `tox` from `azure-media-analytics-edge` dev_requirements

* align regression version of ci/test_tools.txt

* new coverage format requires that the package sources be present when combining .coverage files. amend our tox tree cleanup to exclude the whl directory when running coverage.

* ensure that missing hidden folder can't break cleanup operation

* ensure coverage isn't generated on whl_no_aio

* ensure that coverage is generated without wonky package paths

---------

Co-authored-by: scbedd <45376673+scbedd@users.noreply.github.com>
2023-05-23 10:11:23 -07:00
Scott Beddall d549cfaffe
identify issue with missing code coverage being caused by wrongly named namespace (#30344) 2023-05-10 13:57:01 -07:00
Scott Beddall 8d921366bd
Local `tox` checks do not skip (#28612)
* update to only apply the is_check_enabled when we are in CI, all tox environments will run regardless if target package is configured to skip them in CI or not.
* now skipping an entire analyze entire step if possible
* now marking skipped package / environment combinations
2023-02-10 16:10:47 -08:00
Krista Pratico 8a48c7e3fc
fix local tox for pyright/verifytypes to match ci run (#28641)
* don't install azure-core via editable install from dev reqs for verifytypes

* make same change for pyright so we aren't mixing whl/sdist install with editable install when running locally

* create whls locally

* create whls for deps for pyright/verifytypes

* move shared code to ci_tools.functions and share between tox harness and script

* cspell
2023-02-10 14:31:04 -08:00
Scott Beddall d0f6d33c7e
Enable Pyproject Inclusion (#28345)
* inactive packages are still assembled, but will not be automatically tested unless included using ENABLE_PACKAGE_NAME=true
* checks can now be individually disabled through the pyproject.toml
* added package classifiers to ParsedSetup properties
* add new function is_check_enabled which combines environment_exclusions, pyproject.toml, and environment overrides into one slick package
* all run_check scripts now honor is_check_enabled to enable/disable atomically
* update eng_sys_checks for new functionality
* add pyproject.toml for all core/ packages
* enable black on only track 2 core packages
* remove package build exclusion list in favor of honoring classifier
* update a couple packages with Inactive classifier so they are no longer built. azure-mgmt-scheduler, azure-mgmt-documentdb, azure-mgmt-regionmove

Co-authored-by: McCoy Patiño <39780829+mccoyp@users.noreply.github.com>
2023-01-19 16:41:18 -08:00
Scott Beddall 3b1c811785
Common-sense `tox` environment skipping (#27487)
* move exclusion list to a file within sdk-tools that we can import from random places in the CI. clean up tox_harness as the serial invocation is unused, untested, and worthless.
* type and doccomment all touched functions
* replacing in_ci in favor of ci_tools common version that also honors github actions
* enable filtering based on the opt out lists from the unified exclusion set
* rename tox environment from lint -> pylint. update single reference to said environment. update documentation to reflect new location of exclusion list
* re-add azure-ai-textanalytics and azure-ai-metricsadvisor to opt_out lists
* adding further cspell exclusions
2022-11-15 13:22:36 -08:00
Scott Beddall 7bdc9029d6
[Asset-Sync] extensions to the test framework to allow external assets (#26078)
* add updated logic to resolve assets.json and pass along to record|playback/start

* ensure that parallel tox environments don't accidentally stomp on each other by updating where the local proxy assets are stored during CI runs

* add assets cleanup to ensure we don't overfill the CI agents disks

Co-authored-by: McCoy Patiño <39780829+mccoyp@users.noreply.github.com>
2022-10-14 20:23:18 +00:00
Scott Beddall 93056eb1b3
Update identity build machine for msal 3.7 from ubunto 18.04 to 20.04 (#25807)
* update identity build machine for msal 3.7 from ubunto 18.04 to 20.04
* updating parse_requirements in inject_custom_reqs
2022-08-22 16:05:06 -07:00
Scott Beddall ecfe90f0da
Refactor Build, Versioning into `azure-sdk-tools` (#25454)
* SDK-Tools refactor
* Refactors scripts present under eng/versioning to namespace ci_tools.versioning within the azure-sdk-tools package. All Integration points in CI are flipped over to consume entrypoints defined in the setup.py.
* Refactors build_packages.py and build_package.py into single module ci_tools.build. This function create_package within this module is used wherever packages are built.
* Moves anything related to setup.py parsing into ci_tools.parsing. More specifically, allows users access to ParsedSetup which has a classmethod from_path that can be aimed at any setup.py or package root.
  * Instead of a crazy tuple that we can get lost in the sauce in, it's just strongly typed members of a class now.
* Moves anything related to processing of requirements into ci_tools.functions.
* Type and doc comment all the moved common functionality
2022-08-16 12:25:02 -07:00
praveenkuttappan 90b76d0e98
Generate and publish API stub file for Python (#21505)
* Generate and publish API stub file
2021-12-01 11:12:01 -05:00
Scott Beddall 29f4d2c3d4
Refactor Artifacts at rest for safe/easy deployment (#16187)
* update build_packages to output to a deeper subfolder

* extend find_whl and find_sdst in common_tasks.py/tox_helper_tasks.py to search recursive in preparation for updated artifacts

* remove 'artifacts' artifact. update 'packages' artifact so that package artifacts are stored within folders aligning with each ci.yml artifact

* update archetype-sdk-release to leverage new artifact storage. no more staging.

* update test_regression.py to install package we need to test AFTER we install the dependent package. this ensures that `alpha` versions are always present
2021-02-22 18:11:51 -08:00
Sean Kane a00a4f4b25
adding an if statement for _coverage dir (#16729) 2021-02-12 21:33:13 +00:00
Sean Kane a849586b7c
adding step to upload tox logs on a failure (#16549)
Fixes #9168
2021-02-12 18:57:21 +00:00
Sean Kane 5d2e40eded
append code coverage over each other (#16202) 2021-02-03 19:45:41 +00:00
Scott Beddall 7400360c91
Move mindependency and latestdependency common dependencies to a file (#16365)
* move mindependency and latestdependency common pieces to eng/dependency_tools.txt
2021-01-26 17:09:52 -08:00
praveenkuttappan 10cfa90900
Fix CI issue when installing azure-devtools in parallel (#11223)
* Fix CI issue when installing azure-devtools in parallel
2020-05-04 15:29:20 -07:00
praveenkuttappan 7ccb9a9494
Fix coverage warning issue when no coverage is available (#10760)
* Fix coverage file missing warning
2020-04-09 10:59:00 -07:00
praveenkuttappan 2d0d475899
Skip build and egg info folders from pytest collection lookup (#10048)
* Skip build and egg info folders from pytest collection lookup
* add ignore arg to sdist
2020-02-27 18:38:42 -08:00
praveenkuttappan 78fb4830b6
Fix random failures on CI due to wheel and sdist build for dev required packages (#9942) 2020-02-20 19:46:26 -08:00
Scott Beddall 28043254a2
Allow Custom Pre-Installs During a Manual Build (#9533)
* adjustments to allow an argument w/ additional packages in it
* adding a wrapper ci.yml that can be invoked against the entire repo
* passing around a BuildDocs param. this means that the test-all can pass 'no docs' but the default will still generate them
* deleting the nightly build ymls. with some clever parametering we don't need them anymore!
2020-01-25 00:47:40 -08:00
Scott Beddall eef7caaee4
Run all tests regardless of exit result (#9515)
* all tox instantiations will complete prior to returning the worst return code encountered during the test run.
2020-01-22 12:17:54 -08:00
Scott Beddall d8a9ffdf63
remove parallel spinner for tox logs. allow eventhub to run in serial (#9428) 2020-01-13 12:33:53 -08:00
Scott Beddall ffb81edb37
Run Tox Test Environments in Parallel (#9034)
* take advantage of improvements to tox-monorepo, plumb through tox environments in parallel
* update tox.ini to only use `envtmpdir` instead of `distdir` for temp work.
* disabling coverage in sdist environment
* cogservices textanalytics uses core
* changing the whl to use envtmpdir
* replacing dev_requirements during CI build. this should  mitigate CI failures due to parallelization of install during tox runs
* ignoring the .tox directory to stop pytest discovery errors during collection
2020-01-07 14:24:28 -08:00
Scott Beddall 58f395913c
azure-devtools should never install the upstream pypi version. removing implicit dependency to ensure that (#9065)
adding sdk tools and dev tools as default
2019-12-10 13:26:48 -08:00
praveenkuttappan 67b20092cb Nightly build test is not ignoring error code 5 for azure-keyvault (#8389)
* coverage arg is inserted to master list during each iteration
* pytest should ignore error code 5 for azure-keyvault
2019-11-05 11:57:38 -08:00
Scott Beddall 2d28175a70
Enable azure-keyvault metapackage during build (#8353)
* enable azure-keyvault metapackage. ignore pylint errors. mypy has not opted in. Allow pytest code 5 for azure-keyvault
2019-11-01 16:23:58 -07:00
praveenkuttappan 9cd06b820b
Python 3.8 testing (#8082) 2019-10-23 18:31:33 -07:00
praveenkuttappan a8c9185604
No-cov is added in tox in addition to parameters to tox (#7856)
Code coverage test to exclude test and examples
2019-10-14 16:35:19 -07:00
Scott Beddall 21e442f601
Tox Workflow (#6624)
* Swapping CI to Leverage Tox Workflow
2019-08-27 13:39:32 -07:00