Cannot get field attributes

Aperta
#247 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
38/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
python
Ambito
database

Direzione di ricerca

Reproduce the problem with the shown Datasource.from_file('myDS.tdsx') example and inspect how the datasource's fields are returned. Confirm the expected behavior by checking whether each field should expose attributes such as name rather than only an id string; done means the example can access field attributes without AttributeError.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

I have a tdsx of a published datasource (which is live to a virtual connection (which is extracts only) to AWS Athena).

I am attempting to use Datasource.Fields attributes but can't because instead of a full Field object I only get a string which is the id.

This will print the id:
ds = Datasource.from_file('myDS.tdsx') for f in newDS.fields: print(f)

This throws an error:
ds = Datasource.from_file('myDS.tdsx') for f in newDS.fields: print(f.name)
AttributeError: 'str' object has no attribute 'name'
The same error occurs with all attributes (but of course the attribute changes to whatever I specify)

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

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di tableau/document-api-python

Tutte le issue di tableau/document-api-python

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.