Issue with Downloading Large Views from Tableau Server to CSV
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 42/100
Hướng nghiên cứu
Start with server.views.populate_csv and the subsequent view.csv handling shown in the report, then reproduce the behavior using a large Tableau view with Python 3.9 and TSC 0.30. Trace where the large response stops progressing or is retained, and compare it with the reported successful small-file path. Done means the large CSV is written successfully, or the limitation and required handling are clearly documented.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Describe the bug
I'm encountering an issue when trying to download a view that is around 200 MB in size. My script works perfectly for smaller files (5 MB or 10 MB), but it keeps running indefinitely and doesn't write data into the CSV file for the larger view.
The script successfully logs "CSV populated," indicating that server.views.populate_csv completes, but the file is not written for larger views.
Here's the code I'm using:
def download_file(client, server, content_url, output_file, region):
# NOTE: Monkey patched TSC.RequestOptions.Field class
# since the contentUrl filter parameter was not supported
setattr(TSC.RequestOptions.Field, 'ContentURL', 'contentUrl')
req_option = TSC.RequestOptions()
req_option.filter.add(TSC.Filter(TSC.RequestOptions.Field.ContentURL,
TSC.RequestOptions.Operator.Equals,
content_url))
logger.info('Fetching views...')
views, pagination_item = server.views.get(req_option)
logger.info(f'Views fetched: {len(views)}')
if len(views) == 1:
only_matched_index = 0
view = views[only_matched_index]
logger.info('Populating CSV...')
server.views.populate_csv(view, TSC.CSVRequestOptions(maxage = 5))
logger.info('CSV populated.')
with open(output_file, 'wb') as f:
f.write(b''.join(view.csv))
logger.info(f"CSV DATA WRITTEN TO the {output_file}")
OUTPUT:
INFO:main:Fetching views...
INFO:main:Views fetched: 1
INFO:main:Populating CSV...
INFO:main:CSV populated.
Could anyone suggest what might be going wrong with handling larger views? Are there any additional steps or considerations when dealing with larger files in Tableau Server that I might be missing?
Any insights or suggestions would be greatly appreciated!
Thank you!
Versions
Details of your environment, including:
- Python version:3.9
- TSC library version:0.30
- Ngôn ngữ chính
- Python
- Star
- 716
- Fork
- 446
- Merge trung bình
- 8 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 2
Hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của tableau/server-client-python
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
tableau/server-client-python#1865 ·
-
in-progress
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
tableau/server-client-python#1829 · 1 bình luận ·
-
enhancement gap needs investigation
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
tableau/server-client-python#1322 · 1 bình luận ·
-
[Type2] Allow Incremental Refresh type schedules to be added via `server.schedules.add_to_schedule` Đang mởhelp wanted Server-Side Enhancement ui-exists
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
tableau/server-client-python#1101 · 3 bình luận ·
-
enhancement good first issue
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
tableau/server-client-python#783 · 5 bình luận ·
Tất cả issue của tableau/server-client-python
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
anthropics/skills#1811 · 1 bình luận ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
speaches-ai/speaches#678 ·
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
datalayer/mcp-compose#42 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
conda-forge/spacy-feedstock#177 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
UKGovernmentBEIS/inspect_evals#2523 ·