Hidden property doesn't work as expected.
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Idoneità per principianti
- 45/100
Direzione di ricerca
Start with Workbook initialization and the field hidden method referenced in the issue, then run the provided reproduction against CheckBook_2021.2_sql.twb. Compare fields whose XML lacks the hidden attribute with the method's documented return values. Done means the behavior and docstring consistently communicate the intended True/False result, with coverage for fields without the attribute.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Hi. Release 0.10 brought ability to get status of field, either it hidden or not. But in fact Tableau workbook doesn't contain xml attribute for every field, only for hidden. So after initialisation Workbook object if you check fields you will see two values False or None.
But code and docstring inside hidden method tells that as a user I should expect only True False values. Am I right that it's a bug and None values have to be handled?
Code to reproduce:
import tableaudocumentapi
wb = tableaudocumentapi.Workbook('CheckBook_2021.2_sql.twb')
import pandas as pd
fs = []
for s in wb.datasources:
for k in s.fields:
try:
id = s.fields[k].id
except:
pass
try:
name = s.fields[k].name
except:
pass
try:
caption = s.fields[k].caption
except:
pass
try:
calculation = s.fields[k].calculation
except:
pass
try:
hidden = s.fields[k].hidden
except:
pass
fs.append({'ds': s.caption,
'id': id,
'name': name,
'caption': caption,
'calculation': calculation,
'hidden': hidden
})
df = pd.DataFrame.from_records(fs)
df
Result:

- Lingua principale
- Python
- Stelle
- 363
- Fork
- 183
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
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/document-api-python
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 20/100
tableau/document-api-python#270 ·
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
tableau/document-api-python#260 ·
-
docs
Difficoltà 2/5 1-3 ore Idoneità per principianti 55/100
tableau/document-api-python#258 ·
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 30/100
tableau/document-api-python#251 · 2 commenti ·
-
Alternative for Document Api Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 20/100
tableau/document-api-python#250 · 2 commenti ·
Tutte le issue di tableau/document-api-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