Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Unable to publish a workbook successfully

Đang mở
#1,635 4 bình luận 0 reaction 0 người được giao Xem trên GitHub

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
45/100
Loại issue
Lỗi
Độ rõ ràng
Cần làm rõ
Mức độ hoạt động
Ít trao đổi
Công nghệ
python
Lĩnh vực
api, backend

Hướng nghiên cứu

Start at server.workbooks.publish and compare the two provided calls, especially skip_connection_check, as_job, and hidden_views. Reproduce the hang with the on-prem live datasource and cloud environment, then use the reported 403132 result and non-returning call to define and verify the corrected behavior.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

help wanted

Describe the bug
I have some code that I have been using for quite some time to publish workbook and also data sources to our on -prem environment. We just migrated to the cloud. While I had to change how we authenticate to the cloud the code to publish a dashboard is not completing.
This is a workbook that is connecting live to a database that is on-prem. That is why I was using the skip_connection_check=True. Which seems to hang for me.

Versions
I'm using version 0.36 right now.

To Reproduce
Here is a snippet of the code I was using originally.

    if row['AssetType'] == 'Workbook':
        try:
            ################  PUBLISH WORKBOOK ################
            displayviews = gethiddensheets(server, asset.id, dload_path, RunProcessPath)
            print('    Publishing Workbook!')
            show_tabs = True
            if row['ShowTabs'].upper() == 'FALSE':
                show_tabs = False
            wb_item = TSC.WorkbookItem(name=row['AssetName'], project_id=row['DestinationProjectLUID'], show_tabs=show_tabs)
            if displayviews is None:
                publishedasset = server.workbooks.publish(wb_item, dload_path, 'Overwrite',
                                                      as_job=False, skip_connection_check='True', show_tabs=row['ShowTabs'])
            elif displayviews == -1:
                print('ERROR: Grabbing Hidden Sheets!')
                result = '1|ERROR: Grabbing Hidden Sheets!|'
            else:
                publishedasset = server.workbooks.publish(wb_item, dload_path, 'Overwrite',
                                                      as_job=False, skip_connection_check='True',
                                                      hidden_views=displayviews)
        except Exception as e:
            print('ERROR: Publishing Workbook!')
            print("error in level argument", e.args[0])
            result = '1|ERROR: Publishing Workbook!|'
            return result

New code to adjust for the hidden views in the wb_item:

    if row['AssetType'] == 'Workbook':
        try:
            ################  PUBLISH WORKBOOK ################
            #workbook = server.workbooks.get_by_id(asset.id)
            #all_connections = server.workbooks.populate_connections(workbook)
            displayviews = gethiddensheets(server, asset.id, dload_path, RunProcessPath)
            print('    Publishing Workbook!')
            show_tabs = True
            if row['ShowTabs'].upper() == 'FALSE':
                show_tabs = False
            wb_item = TSC.WorkbookItem(name=row['AssetName'], project_id=row['DestinationProjectLUID'], show_tabs=show_tabs)
            if displayviews is None:
                publishedasset = server.workbooks.publish(wb_item, dload_path, 'Overwrite')
            elif displayviews == -1:
                print('ERROR: Grabbing Hidden Sheets!')
                result = '1|ERROR: Grabbing Hidden Sheets!| '
            else:
                try:
                    print('Hidden Views')
                    wb_item.hidden_views = displayviews

                   publishedasset = server.workbooks.publish(wb_item, dload_path, mode='Overwrite',
                                                              skip_connection_check=True,
                                                              as_job=False)

Results
server.workbooks.publish never returns.
If I remove or change skip_connection_check to false it does complete with the following error.

403132: Forbidden
		AssetPromotionRequest failed to establish a connection to your datasource.
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

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. 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.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của tableau/server-client-python

Tất cả issue của tableau/server-client-python

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.