* Fix broken TLS interception because uid is now no longer a UUID
* Give enough context to work id for them to be unique within a `proxy.py` instance
* Use --port=0 by default within `proxy.TestCase`
* Attempt to fix weird buildx issue
* Add makefile targets within workflow
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Order?
* Write scm file for make
* Fetch depth
* Quote patch
* Try with sudo?
* https://github.com/docker/buildx/issues/850
* Remove sudo hack
* https://github.com/docker/buildx/issues/850\#issuecomment-973270625
* Add explicit deps
* Add `requirements-testing.txt` during linting phase
* Pin buildx to v0.7.1
* Pin buildx to v0.7.0
* Revert back unnecessary change to dockerignore
* Skip container within make workflow (because GHA lacks support for docker on macOS by default)
* Repurpose make into developer workflow
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Allow overriding work_klass via Proxy context manager kwargs
* Decouple acceptor and executor pools
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Add `--num_acceptors` flag and better load balancing
* Remove unused
* Lint errors
* Another arg not kwarg
* Move start work staticmethods within ExecutorPool
* mypy fixes
* Update README with `--num-acceptors` flag
* Rename `Proxy.pool` to `Proxy.acceptors`
* Add SetupShutdownContextManager abstraction
* Match --num-acceptors logic with PR description
* Rename executor utility methods and add docstring
* Remove work_klass from constructors and pass it via flags
* Update docstring for pools as they no longer accept a work_klass argument
* Turn work_klass into a flag. main() no longer accepts input_args (only kwargs opts). Similarly, Proxy doesnt accept any input_args now (only kwargs opts)
* Expose default work klass in README
* Expose `HttpProtocolHandler` and `HttpProtocolHandlerPlugin` within `proxy.http` module
* Start to fix tests
* Fix tests
* mypy and flake8
* Trailing comma
* Remove unused var
* Unused arg
* uff
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
* Expose within __all__
* Enable `--numprocesses=auto` for `pytest.ini`
* make lib-lint
* Also consider `--plugins` flag when bootstrapping plugins
* Add `from .dashboard import ProxyDashboard` in top-level `__init__.py` to make `ProxyDashboard` flags auto discoverable
* Move `--enable-dashboard` to top-level
* Move logging utility within `Logger` class
* Consider comma separated --plugin and --plugins during discover_plugins
* Refactor plugin related utilities in Plugins module
* mypy and lint
* Fix unused import
* Safe to use tempdir on Github actions to avoid race conditions???
* pki (generically disk based file) based tests are flaky on macOS under parallel execution
* Use suggested fix in #683 to remove pytest ignore
* Handle should not flush now which can block, instead let base tcp handler do its magic
* test speed up, doc string, logging enhancements
* Move macOS to the end of workflows
* Fix mypy warnings
* Remove autopep8, is redundant now after recent CI changes
* Add pyenv .python-version to .gitignore
* Update year
* Add lib-pytest target so that pytest can run in isolation
* Add git-push hook which will also run the lint.
By default now git-pre-commit hook will only run pytest.
* Update outdated sections of README
* Update requirement to match setup.cfg install_requires
* Deprecate proxy.start and TestCase.PROXY_PORT
Proxy port during test is now available as self.PROXY.pool.flags.port.
Also now TestCase utilize ephemeral port strategy instead of
calling get_available_port utility method.
* Rename to git-pre-push
* Ideally public repo dont require CODECOV_TOKEN but codecov integration is broken since introduction of codecov-action@v2 (instead of codecov binary invocation)
* Issue is possibly with codecov@v2 action, fallback to codecov. See https://github.com/abhinavsingh/proxy.py/runs/4110423084\?check_suite_focus\=true and https://github.com/codecov/uploader/issues/223
* Revert back to v2
* connection.recv now returns a memoryview
* Make connection.queue also memoryview compliant
* autopep8
* wrap in memoryview as necessary
* Add default timeout for socket_connection and test_embed urllib
* Fix tests
* Skip TestProxyPyEmbedded for now, verifying GitHub actions
* Add timeout for wait_for_server and skip only if GITHUB_ACTIONS env variable is set
* Verify if GitHub Action fails due to wait_for_server spinning forever
* Add test for wait_for_server timeout error exception
* GitHub action hangs irrespective of wait_for_server timeout, disable TestEmbed for GitHub actions
* Introduce proxy.Proxy context manager.
This is similar to already existing context manager `start` but
`proxy.Proxy` is a class with __enter__ and __exit__ methods. This
allows usage of `proxy.Proxy` both as context manager and for manually
setup and teardown of `proxy.py` during test setUpClass and
teardownClass methods.
* Gracefully shutdown threadless processes
* Update tests and add a VCR method. See #184
* Refactor routes
* Add Proxy to __all__
* Move TestCase under proxy.testing and test_embed.py under tests.embed module to avoid conflict with http module due to a http directory under proxy folder
* Add a base cache plugin class which can be customized for custom cache behaviors
* See #184. Add VCRPlugin which can be enabled within tests using a context manager, e.g. with self.vcr(): ...
* Make cache plugin pluggable + make cache storage pluggable
* Make dashboard npm module agnostic of top level directory
* Symlink dashboard public folder
* Dump devtools within dashboard public folder
* Remove unused 3rd party js