Skip to content

comment trim on long output not working #1387

@thobianchi

Description

@thobianchi

What happened?

On a very long output we get this error:

09-08T11:07:31.1759722Z �[0m�[38;5;1m                                    }�[0m�[38;5;1m
2025-09-08T11:07:31.1759874Z �[0m�[38;5;1m                                    version   : �[0m�[38;5;1m3�[0m�[38;5;1m
2025-09-08T11:07:31.1760041Z �[0m�[38;5;1m                                    widgetType: �[0m�[38;5;1m"area"�[0m�[38;5;1m
2025-09-08T11:07:31.1760175Z �[0m�[38;5;1m                                }�[0m�[38;5;1m
2025-09-08T11:07:31.1760301Z �[0m�[38;5;1m                            }�[0m�[38;5;1m
2025-09-08T11:07:31.1760427Z �[0m�[38;5;1m                        }�[0m�[38;5;1m
2025-09-08T11:07:31.1760547Z �[0m�[38;5;1m                    ]�[0m�[38;5;1m
2025-09-08T11:07:31.1760715Z �[0m�[38;5;1m                    name       : �[0m�[38;5;1m"XXX"�[0m�[38;5;1m
2025-09-08T11:07:31.1760832Z �[0m�[38;5;1m                }�[0m�[38;5;1m
2025-09-08T11:07:31.1761032Z �[0m�[38;5;1m            ]�[0m�[38;5;1m
2025-09-08T11:07:31.1761137Z �[0m�[38;5;1m        }�[0m�[38;5;1m
2025-09-08T11:07:31.1761227Z �[0m�[38;5;1m
2025-09-08T11:07:31.1761418Z �[0m�[38;5;1m        XXX        : �[0m�[38;5;1m"3e42df7d399c512f"�[0m�[38;5;1m
2025-09-08T11:07:31.1761526Z �[0m�[0m�[38;5;13m�[1mResources:�[0m
2025-09-08T11:07:31.1761637Z     �[38;5;3m~ 6 to update�[0m
2025-09-08T11:07:31.1761745Z     �[38;5;1m- 2 to delete�[0m
2025-09-08T11:07:31.1761851Z     �[1m8 changes�[0m. 3 unchanged
2025-09-08T11:07:31.1762221Z 
2025-09-08T11:07:31.1762737Z HttpError: Validation Failed: {"resource":"IssueComment","code":"unprocessable","field":"data","message":"Body is too long (maximum is 65536 characters)"}
2025-09-08T11:07:31.1763039Z     at /__w/_actions/pulumi/actions/v6.0.0/webpack:/pulumi-github-action/node_modules/@octokit/request/dist-node/index.js:86:1
2025-09-08T11:07:31.1763211Z     at processTicksAndRejections (node:internal/process/task_queues:95:5)
2025-09-08T11:07:31.1763566Z ##[endgroup]
2025-09-08T11:07:31.1778883Z ##[warning]Not able to edit comment, defaulting to creating a new comment.

that's strange because we have other occasions where the trimming is happening, but in this particular case where we have a SUPER long line in the stack ( 777943 chars ) we get the error

Example

import pulumi_databricks as databricks

    databricks.Dashboard(
        dashboard.name,
        display_name=f"[{prefix}] {dashboard.name}",
        warehouse_id=id,
        serialized_dashboard=json.dumps(file_really_long),
        embed_credentials=False,
    )

If you put a very long json in the serialized_dashboard parameter on a single line

Output of pulumi about

CLI          
Version      3.193.0
Go Version   go1.25.1
Go Compiler  gc

Plugins
KIND      NAME            VERSION
resource  archive         0.3.4
resource  auth0           3.23.1
resource  aws             6.83.0
resource  cloudamqp       3.23.0
resource  cloudflare      5.49.1
resource  command         1.1.0
resource  confluentcloud  2.33.0
resource  databricks      1.73.0
resource  datadog         4.52.0
resource  kubernetes      4.23.0
resource  mysql           0.0.11
resource  postgresql      3.15.2
language  python          3.193.0
resource  rabbitmq        3.3.11
resource  random          4.18.3
resource  time            0.1.1
resource  vault           7.1.0

Host     
OS       darwin
Version  15.6.1
Arch     arm64
Dependencies:
NAME                   VERSION
black                  24.10.0
flake8                 7.3.0
isort                  5.13.2
Jinja2                 3.1.6
mypy                   1.17.0
prima-pulumi           1.18.5
pulumi_databricks      1.73.0
setuptools             80.9.0
types-boto3-s3control  1.39.2
wheel                  0.45.1

Additional context

No response

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugSome behavior is incorrect or out of specresolution/fixedThis issue was fixed

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions