Hidden property doesn't work as expected.
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Anfängerfreundlichkeit
- 45/100
Rechercherichtung
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.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
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:

- Vorherrschende Sprache
- Python
- Sterne
- 363
- Forks
- 183
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beitragsleitfaden
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus tableau/document-api-python
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 20/100
tableau/document-api-python#270 ·
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 25/100
tableau/document-api-python#260 ·
-
docs
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 55/100
tableau/document-api-python#258 ·
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 30/100
tableau/document-api-python#251 · 2 Kommentare ·
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 20/100
tableau/document-api-python#250 · 2 Kommentare ·
Alle Issues in tableau/document-api-python
Ähnliche Issues
-
essnmx good first issue
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 95/100
-
[Feature] 奇物选择添加优先级 Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 65/100
syfoud/Simulated_Scepter#174 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
Giskard-AI/giskard-oss#2840 · 1 Kommentar ·
-
A claim comment carrying the issue number is silently declined while the workflow reports success Offenarea: repo bug perceived difficulty: 2
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 70/100
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
yeti-platform/yeti#1380 ·