[PR #109] [MERGED] Import unique objects in the same order as the array of import sources #461

Closed
opened 2025-12-29 15:32:16 +01:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/JohnEstropia/CoreStore/pull/109
Author: @andriichernenko
Created: 10/8/2016
Status: Merged
Merged: 10/10/2016
Merged by: @JohnEstropia

Base: swift3_developHead: import-unique-objects-order


📝 Commits (1)

  • 32a388e import unique objects in the same order as the array of import sources

📊 Changes

1 file changed (+32 additions, -35 deletions)

View changed files

📝 Sources/Importing/BaseDataTransaction+Importing.swift (+32 -35)

📄 Description

Currently according to the documentation import of unique objects occurs in arbitrary order.

This behavior is different from the import of non-unique objects which might be unexpected (who reads the method docs anyway?). Furthermore, maintaining the order might be useful in some cases.

This pull request modifies importUniqueObjects(...) method to ensure that the order of import sources, order of import method calls and the order of imported objects in the returned array are the same.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/JohnEstropia/CoreStore/pull/109 **Author:** [@andriichernenko](https://github.com/andriichernenko) **Created:** 10/8/2016 **Status:** ✅ Merged **Merged:** 10/10/2016 **Merged by:** [@JohnEstropia](https://github.com/JohnEstropia) **Base:** `swift3_develop` ← **Head:** `import-unique-objects-order` --- ### 📝 Commits (1) - [`32a388e`](https://github.com/JohnEstropia/CoreStore/commit/32a388e0ca3a79911d4d1581d23861e433d79848) import unique objects in the same order as the array of import sources ### 📊 Changes **1 file changed** (+32 additions, -35 deletions) <details> <summary>View changed files</summary> 📝 `Sources/Importing/BaseDataTransaction+Importing.swift` (+32 -35) </details> ### 📄 Description Currently according to the documentation import of unique objects occurs in arbitrary order. This behavior is different from the import of non-unique objects which might be unexpected (who reads the method docs anyway?). Furthermore, maintaining the order might be useful in some cases. This pull request modifies `importUniqueObjects(...)` method to ensure that the order of import sources, order of import method calls and the order of imported objects in the returned array are the same. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2025-12-29 15:32:16 +01:00
adam closed this issue 2025-12-29 15:32:16 +01:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/CoreStore#461