Endpoint._make_request namespace detection guard misses text/xml responses
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 50/100
Direzione di ricerca
Start in tableauserverclient/server/endpoint/endpoint.py at Endpoint._make_request and compare its Content-Type guard with TSC’s XML_CONTENT_TYPE constant. Review #1046 and PR #1863 to determine whether namespace detection remains needed; done means the chosen path is covered for the relevant XML response type or the obsolete subsystem is removed consistently.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Endpoint._make_request (in tableauserverclient/server/endpoint/endpoint.py) parses the response Content-Type and calls the namespace-detection helper only when it matches:
if content_type == "application/xml":
self.parent_srv._namespace.detect(server_response.content)
Tableau Server emits text/xml (which is what TSC's own XML_CONTENT_TYPE constant is set to), so _namespace.detect() never fires from this path. The pre-existing sign-in path called _namespace.detect() explicitly, so the pre-8.3 namespace fallback still worked there; PR #1848 routes signin through _make_request, which now exposes the bug for signin traffic too.
Two things worth thinking about together:
- The immediate fix: widen the guard to accept both
application/xmlandtext/xml, or (cheaper) just check"xml" in content_typesince detection is idempotent and cheap. - Is the code even reachable? The namespace fallback exists to accept pre-Tableau-8.3 servers that used
http://tableausoftware.com/apiinstead ofhttp://tableau.com/api. TSC'sminimum_supported_server_versionis 2.3, which corresponds to Tableau Server 10.0 (2016). Any server old enough to emit the pre-8.3 namespace is far below the minimum. See #1046 and PR #1863 for a proposed removal of the whole detection subsystem.
If PR #1863 lands, this issue is moot (the whole _namespace.detect call and the Namespace class go away). If it doesn't, we need to fix the guard.
Filed after a fresh-eyes review flagged the guard on PR #1848.
- Lingua principale
- Python
- Stelle
- 716
- Fork
- 446
- Merge medio
- 8g 8h
- PR unite (30g)
- 2
Guida per i contributori
Apri la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di tableau/server-client-python
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
tableau/server-client-python#1865 ·
-
in-progress
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
tableau/server-client-python#1829 · 1 commento ·
-
enhancement gap needs investigation
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
tableau/server-client-python#1322 · 1 commento ·
-
[Type2] Allow Incremental Refresh type schedules to be added via `server.schedules.add_to_schedule` Apertahelp wanted Server-Side Enhancement ui-exists
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
tableau/server-client-python#1101 · 3 commenti ·
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
tableau/server-client-python#783 · 5 commenti ·
Tutte le issue di tableau/server-client-python
Issue simili
-
link-check link-check:sphinx-theme
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
qgis/QGIS-Documentation#11275 ·
-
bug priority:normal ready-for-dev
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
OpenHands/extensions#626 · 1 commento ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
CSCfi/sd-search-api#39 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100