Remove Composite Structure Family#1093
Merged
danielballan merged 18 commits intobluesky:mainfrom Aug 26, 2025
Merged
Conversation
ddec522 to
4afe580
Compare
This was referenced Aug 19, 2025
genematx
commented
Aug 19, 2025
| @property | ||
| def parts(self): | ||
| return CompositeParts(self) | ||
| def base(self): |
Contributor
Author
There was a problem hiding this comment.
We can call something else, of course. base is just shortest relevant name I could think of. In future, we can also put it in the base class itself and make it a general accessor to the relevant Tiled client without specs -- it shouldn't break the current implementation.
ZohebShaikh
pushed a commit
that referenced
this pull request
Feb 21, 2026
* REV: remove references to composite * MNT: cleanup commented code * TST: move tests for composite * add normalize_spec util * TST: fix tests for Composite client * TST: fix tests on Windows and with py3.9 * ENH: server-side validation of the composite spec * MNT: bring back codecov * ENH: add the forward alembic migration script * ENH: add downgrade alembic path for migration * ENH: upgrade/downgrade data_sources table * MNT: changelog * DOC: update docs * DOC: update docs * ENH: remove composite parts * FIX: f-string --------- Co-authored-by: Dan Allan <dallan@bnl.gov>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request demotes Composite containers from
structure_familytospecto simplify the set of supported structures in Tiled. The validation is performed both, client-side (when adding data to an existing container withcompositespec) and server-side (when creating a new container or adding thecompositespec to an existing one).Main Changes
create_container(..., specs=["composite"])instead of the deprecatedcreate_composite, aligning with the new API and improving clarity.tiled/_tests/test_writing.pytotiled/_tests/test_composite.py, expanding coverage with new tests for edge cases such as key collisions and validator logic.Specmodel and updating argument order for custom validators.keyproperty to catalog adapters and cleaned up thelookup_adapterlogic to remove unnecessary resolution for composite nodes.composite.parts, to access the underlying container structure including the constituent tables, usecomposite.base, which returns an instance of the usualContainerclient.Usage Example
Demo Example
Testing Alembic Migration
The alembic migration scripts up/down-grade have been tested with PostgreSQL and SQLite catalogs.
Testing Script and Results
Script to generate the testing data
PostgreSQL database before
PostgreSQL database after
Issue: #1081
Related:
Checklist