Skip to content

[bot] Merge master/63ae5592 into rel/dev - #1935

Merged
yenkins-admin merged 1 commit into
rel/devfrom
snapshot-master-63ae5592-to-rel/dev
Nov 10, 2026
Merged

yenkins-admin merged 1 commit into
rel/devfrom
snapshot-master-63ae5592-to-rel/dev

Conversation

@yenkins-admin

Copy link
Copy Markdown
Contributor

🚀 Automated PR to perform merge from master into rel/dev with changes up to 63ae559 (created by https://github.com/gooddata/gooddata-python-sdk/actions/runs/42825095795).

…1934)

* fix(gooddata-api-client): accept primitive-only oneOf union values

A declarative read failed with `ApiTypeError: Invalid type for variable
'gap'` once any Publisher document, document template or page template
in the workspace carried a style value such as `gap: 20` or
`padding: "{theme.spacing.padding.normal}"`. The write paths (from_dict,
load from disk, to_api, put) failed the same way.

The spec types these fields as a oneOf of two primitives. python-prior
v6.6.0 renders such a schema as an empty model class that accepts no
value, so all seven of them were broken: the publisher style gap,
padding and border radius, a visualization's auto-visibility, the
publisher date filter bounds, the dashboard tabular export date filter
bounds and the conditional-formatting literal.

The fix is in the custom templates, so it survives regeneration:

- an override of the normal-model partial marks a primitive-only oneOf
  model with its member types (a non-empty oneOf list is the only thing
  telling it apart from a genuinely empty object model);
- model_utils validates such a property against the member types, also
  admits an int on a union that contains float, and skips the
  int-to-float upconversion for these unions only, so 20 stays 20
  through a read, the constructor and the wire.

A wrong type, such as a dict, a list or a bool on a number union, is
still rejected. Empty object models and plain number properties behave
as before. The client is regenerated from the specs already in
schemas/, so the generated diff is the seven union models and
model_utils alone.

The override is a full copy of the upstream partial and must be
reconciled on a generator upgrade; a move to generator v7's python
generator, which emits real unions, would retire it.

jira: LX-3540
risk: low
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(gooddata-sdk): carry style values through document round trips

The document unit tests carried no style, so nothing in the SDK suite
exercised the number-or-string unions a real Publisher document uses.
Their literal now has a page `gap: 20`, a container padding theme
token, a `borderRadius: 4.5` and a visualization's
`display.dataLabels.visible: "auto"`, in the document as well as in the
document and page templates.

The round-trip assertions compare types as well as values, because
`==` treats 20 and 20.0 as equal and would not notice an int turned
into a float. A new test deserializes a layout body the way an API
response is deserialized and builds the SDK layer from it, which is
the path the reported read failure took.

The hand-built document in the period test now takes its content in
the form a read holds it, with the client's python names for the keys
the client models, as for any document's content in memory.

jira: LX-3540
risk: nonprod
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* test(gooddata-sdk): seed style values in the recorded document round trip

The recorded document store-load-put test seeded a document without any
style, so the real-backend round trip never carried the number-or-string
values a Publisher document has. The seed layout now has a page
`gap: 20`, a container padding theme token, a `borderRadius: 4.5` and a
visualization's `display.dataLabels.visible: "auto"`. The test asserts
that the read-back page keeps `gap` as the int 20 and the padding as the
token string.

The test fails on replay until its cassette is re-recorded against the
backend with the new seed.

jira: LX-3540
risk: nonprod
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* chore(gooddata-sdk): re-record the document round-trip cassette

The recorded document store-load-put test now seeds a page gap, a
container padding token, a border radius and a visualization data
label setting, so its cassette is recorded again on the SDK's staging
environment, as is and unedited. The read responses carry the page
`gap` as the JSON int 20 and the padding as the token string.

The recording was made with the metric and visualization permission
flags off, like the other document cassettes. No other cassette
changes.

jira: LX-3540
risk: nonprod
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
@yenkins-admin
yenkins-admin merged commit f478c77 into rel/dev Nov 10, 2026
1 check passed
@coderabbitai

coderabbitai Bot commented Nov 10, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: e3074a31-1686-4ddc-8d64-4a960bbe88ea

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

@yenkins-admin
yenkins-admin deleted the snapshot-master-63ae5592-to-rel/dev branch November 10, 2026 13:30
@codecov

codecov Bot commented Nov 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.18%. Comparing base (7c0e996) to head (63ae559).
⚠️ Report is 641 commits behind head on rel/dev.

Additional details and impacted files
@@           Coverage Diff            @@
##           rel/dev    #1935   +/-   ##
========================================
  Coverage    86.18%   86.18%           
========================================
  Files          345      345           
  Lines        25954    25954           
========================================
  Hits         22368    22368           
  Misses        3586     3586           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants