Remove deprecated DEX support and tests (endpoints return 404)#93
Merged
Conversation
DEX endpoints deprecated server-side (all /api/v1/dex/* return 404). Drop Dex client, its wiring in Datamaxi.__init__, and the six dex_* entries from _endpoints.py (GROUPS rebuilds, so dex group drops too).
Drop test_dex (test_call.py), the TestDex class (test_integration.py), and the dex marker from setup.cfg.
ENDPOINTS/GROUPS in datamaxi/_endpoints.py are not imported anywhere in the SDK, tests, or packaging — clients build requests directly. Drop the dead generated artifact rather than keep patching its dex entries.
af80bda to
08b4ea3
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Closes #89.
The DEX endpoints are deprecated server-side — every
/api/v1/dex/*call now returns404 Cannot GET, which was the main cause of the integration-test failures. This PR removes DEX support and its tests entirely.Removed:
datamaxi/datamaxi/dex.py(Dex client) and its import +self.dex = Dex(...)wiring indatamaxi/datamaxi/__init__.py.datamaxi/_endpoints.pydeleted in full.ENDPOINTS/GROUPSin that file are not imported anywhere in the SDK, tests, or packaging (clients build requests directly), so rather than hand-patch out the sixdex_*entries from a generated artifact, the dead file is dropped. Verified: no consumers,import datamaxiclean, 140 tests still collect.test_dex(tests/test_call.py), theTestDexclass (tests/test_integration.py), and thedexpytest marker (setup.cfg).docs/dex.md, the- DEX: dex.mdnav entry (mkdocs.yml), and theDEX Datasection + TOC entry + client-description mention (README.md).A repo-wide
grep -ri dexsweep is clean (onlyindex/set_indexsubstrings remain).datamaxi/_endpoints.pywas an auto-generated file ("DO NOT EDIT — regenerate with: make python", sourced fromopenapi.yaml). The codegen source lives in a separate upstream repo not present here. This PR deletes the artifact, but the upstream codegen still emits it — so:Action needed upstream: drop the
dextag fromopenapi.yamlAND stop emitting_endpoints.py(otherwise the nextmake pythonregenerates the file and reintroduces the dex entries). Note the file is currently unused, so a regen would not by itself resurrect theDexclient or the 404s — but it would undo this cleanup.Test plan
python -m pytest tests/ --collect-only→ 140 tests collected, no import/collection errors, nodexmarker warnings. ✅import datamaxi+Datamaxi('x')→ import clean, no.dexattribute. ✅python -m pytest tests/test_query_params.py tests/test_api.py→ 10 passed. ✅flake8on changed files → clean. ✅python -m pytest tests/test_call.py→ 11 skipped — require a liveDATAMAXI_API_KEY(not mocked); skipped offline. The formertest_dexis gone.Not run: the full
tests/test_integration.pysuite requires a live API key + network and was not executed in this environment. The DEX 404 failures it previously produced are removed by construction (theTestDexclass is deleted).Out of scope (per issue):
TestPremium::test_premium_token_includeis a separate non-DEX failure.