René's URL Explorer Experiment


Title: fix(fork): preserve folder structure across a fork edge for files, tables, and knowledge bases by waleedlatif1 · Pull Request #6752 · simstudioai/sim · GitHub

Open Graph Title: fix(fork): preserve folder structure across a fork edge for files, tables, and knowledge bases by waleedlatif1 · Pull Request #6752 · simstudioai/sim

X Title: fix(fork): preserve folder structure across a fork edge for files, tables, and knowledge bases by waleedlatif1 · Pull Request #6752 · simstudioai/sim

Description: Summary Fork sync only mirrored workflow folders into the target. Copied files, tables, and knowledge bases were written with a hardcoded folderId: null, so every push/pull flattened them into the target root and lost the source's grouping. resolveForkFolderMapping already did the work (prune to folders holding copied content plus ancestors, reuse same-named target folders, remap parentId) but was pinned to resourceType: 'workflow' on both reads and the folder-ceiling check. Parameterized it by resource type and run it per family. The four folder-bearing families own disjoint trees and folder ids are globally unique, so the per-family maps merge cleanly for the sim:folder/ content rewrite — which previously resolved only for workflow folders. BlobCopyTask.targetFolderId is optional so file-copy jobs queued by an earlier deploy replay at the root exactly as before. Applies to fork create and to both sync directions — push and pull share the same code path. Scope: forward-only. Resources already flattened by earlier syncs stay where they are. An earlier revision of this PR included a sync-time re-home pass to heal them; it was removed after review — folder_id IS NULL cannot distinguish legacy flattening from a user's deliberate move to the root, so it would re-apply on every sync and fight that placement indefinitely. Doing it correctly needs a one-time marker per edge (a migration), which belongs in its own change. Type of Change Bug fix Testing 539 tests pass across 37 files in ee/workspace-forking; bun run type-check clean; all 27 check:audits pass Verified the new tests can fail: reverting the file folderId remap turns the file-placement test red Notes for review Folder creation now happens in three more collections, so assertFolderCollectionHasRoom can refuse a sync whose target is at the 10k-per-collection cap. It only fires when new folders are genuinely needed, the promote route already maps that error cleanly, and it matches existing workflow behavior. Checklist Code follows project style guidelines Self-reviewed my changes Tests added/updated and passing No new warnings introduced I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Open Graph Description: Summary Fork sync only mirrored workflow folders into the target. Copied files, tables, and knowledge bases were written with a hardcoded folderId: null, so every push/pull flattened them into the...

X Description: Summary Fork sync only mirrored workflow folders into the target. Copied files, tables, and knowledge bases were written with a hardcoded folderId: null, so every push/pull flattened them into the...

Opengraph URL: https://github.com/simstudioai/sim/pull/6752

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf
route-pattern/:user_id/:repository/pull/:id/files(.:format)
route-controllerpull_requests
route-actionfiles
fetch-noncev2:48598c24-3965-4528-9eb6-57061314dc9e
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id8752:15DF38:7ED71F:ADAC40:6AFB4565
html-safe-noncef333fcb0ad701777a2b3d8c8d7b6c7209725f49ced60f9ff76e4ff94fb597830
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4NzUyOjE1REYzODo3RUQ3MUY6QURBQzQwOjZBRkI0NTY1IiwidmlzaXRvcl9pZCI6IjYxNzA4NTc3MTcxNDM0ODM4OSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac3c2e2b004d8d0b0a3320d0f77b4200c31f8829d0b929740d59069c3dc8bf1017
hovercard-subject-tagpull_request:4288221998
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///pull_requests/show/files
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/simstudioai/sim/pull/6752/files
twitter:imagehttps://avatars.githubusercontent.com/u/40672544?s=400&v=4
twitter:cardsummary_large_image
og:imagehttps://avatars.githubusercontent.com/u/40672544?s=400&v=4
og:image:altSummary Fork sync only mirrored workflow folders into the target. Copied files, tables, and knowledge bases were written with a hardcoded folderId: null, so every push/pull flattened them into the...
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
Noned849b928f455c800985398e7f1b659425adb312a5fa14fba5d9a14e62e9fe5dd
turbo-cache-controlno-preview
diff-viewunified
go-importgithub.com/simstudioai/sim git https://github.com/simstudioai/sim.git
octolytics-dimension-user_id199344406
octolytics-dimension-user_loginsimstudioai
octolytics-dimension-repository_id912559512
octolytics-dimension-repository_nwosimstudioai/sim
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id912559512
octolytics-dimension-repository_network_root_nwosimstudioai/sim
turbo-body-classeslogged-out env-production page-responsive full-width
disable-turbotrue
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
releasea6c2f87cbcb6414452377b4967858ed6a66f1109
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/simstudioai/sim/pull/6752/files#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsimstudioai%2Fsim%2Fpull%2F6752%2Ffiles
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fsimstudioai%2Fsim%2Fpull%2F6752%2Ffiles
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fpull_requests%2Fshow%2Ffiles&source=header-repo&source_repo=simstudioai%2Fsim
Reloadhttps://github.com/simstudioai/sim/pull/6752/files
Reloadhttps://github.com/simstudioai/sim/pull/6752/files
Reloadhttps://github.com/simstudioai/sim/pull/6752/files
simstudioaihttps://github.com/simstudioai
simhttps://github.com/simstudioai/sim
Codehttps://github.com/simstudioai/sim
Issues129 (129)https://github.com/simstudioai/sim/issues
Pull requests199 (199)https://github.com/simstudioai/sim/pulls
Actionshttps://github.com/simstudioai/sim/actions
Projectshttps://github.com/simstudioai/sim/projects
Security and qualityhttps://github.com/simstudioai/sim/security
Insightshttps://github.com/simstudioai/sim/pulse
Sign up for GitHub https://github.com/signup?return_to=%2Fsimstudioai%2Fsim%2Fissues%2Fnew%2Fchoose
terms of servicehttps://docs.github.com/terms
privacy statementhttps://docs.github.com/privacy
Sign inhttps://github.com/login?return_to=%2Fsimstudioai%2Fsim%2Fissues%2Fnew%2Fchoose
waleedlatif1https://github.com/waleedlatif1
staginghttps://github.com/simstudioai/sim/tree/staging
fix/fork-sync-folder-structurehttps://github.com/simstudioai/sim/tree/fix/fork-sync-folder-structure
Conversation 14 https://github.com/simstudioai/sim/pull/6752
Commits 3 https://github.com/simstudioai/sim/pull/6752/commits
Checks 31 https://github.com/simstudioai/sim/pull/6752/checks
Files changed https://github.com/simstudioai/sim/pull/6752/files
Please reload this pagehttps://github.com/simstudioai/sim/pull/6752/files
fix(fork): preserve folder structure across a fork edge for files, tables, and knowledge bases https://github.com/simstudioai/sim/pull/6752/files#top
Show all changes 3 commits https://github.com/simstudioai/sim/pull/6752/files
bacb1e3 fix(fork): carry folder structure across a fork edge for files, table… waleedlatif1 Aug 16, 2026 https://github.com/simstudioai/sim/pull/6752/commits/bacb1e3ee4cbae662e1e16a08b6bdf43e5c4f2d0
ffc3685 refactor(fork): page the re-home lookups and reuse the plan's identit… waleedlatif1 Aug 16, 2026 https://github.com/simstudioai/sim/pull/6752/commits/ffc36852b8b5423eeaf1533a542dc46457d26996
a07e14b fix(fork): drop the sync-time re-home pass, keep folder transit forwa… waleedlatif1 Aug 16, 2026 https://github.com/simstudioai/sim/pull/6752/commits/a07e14bf9af159e4fa741c40fd77d3b689ad6bed
Clear filters https://github.com/simstudioai/sim/pull/6752/files
Please reload this pagehttps://github.com/simstudioai/sim/pull/6752/files
Please reload this pagehttps://github.com/simstudioai/sim/pull/6752/files
copy-files.test.ts https://github.com/simstudioai/sim/pull/6752/files#diff-31d6b823ee537f678640acbf005d7c2e0cdbe039addabcf822609e39aff913a1
copy-files.ts https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
copy-resources.test.ts https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
copy-resources.ts https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
copy-workflows.ts https://github.com/simstudioai/sim/pull/6752/files#diff-cf848b79f30956f4fcfd02bf3cc4542a1c4786526d4c22368946d1a9badcc1b8
create-fork.test.ts https://github.com/simstudioai/sim/pull/6752/files#diff-296e1a98029b9a96a81aa7f980262a8491ff20cccc8f94b9820b968ed932b189
create-fork.ts https://github.com/simstudioai/sim/pull/6752/files#diff-202ab0340bdbd94663e1182c0295106afbcba13ffa9f7e481276fee250b041ee
copy-unmapped.test.ts https://github.com/simstudioai/sim/pull/6752/files#diff-5ae18348c8c4f6cb2565463ddf67cf5fd21af3d47d3cbaca6af63b843d5a839d
copy-unmapped.ts https://github.com/simstudioai/sim/pull/6752/files#diff-e951b4203d3de3538138946986d8c80a4e37cb88d7ad29596d7150459aa74cd3
promote.ts https://github.com/simstudioai/sim/pull/6752/files#diff-497982ff22d7de8c90edf0d78da858e9bf7b3197472fa36bf731e7642fec30a6
apps/sim/ee/workspace-forking/lib/copy/copy-files.test.tshttps://github.com/simstudioai/sim/pull/6752/files#diff-31d6b823ee537f678640acbf005d7c2e0cdbe039addabcf822609e39aff913a1
View file https://github.com/simstudioai/sim/blob/a07e14bf9af159e4fa741c40fd77d3b689ad6bed/apps/sim/ee/workspace-forking/lib/copy/copy-files.test.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/simstudioai/sim/pull/6752/{{ revealButtonHref }}
https://github.com/simstudioai/sim/pull/6752/files#diff-31d6b823ee537f678640acbf005d7c2e0cdbe039addabcf822609e39aff913a1
https://github.com/simstudioai/sim/pull/6752/files#diff-31d6b823ee537f678640acbf005d7c2e0cdbe039addabcf822609e39aff913a1
apps/sim/ee/workspace-forking/lib/copy/copy-files.tshttps://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
View file https://github.com/simstudioai/sim/blob/a07e14bf9af159e4fa741c40fd77d3b689ad6bed/apps/sim/ee/workspace-forking/lib/copy/copy-files.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/simstudioai/sim/pull/6752/{{ revealButtonHref }}
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
https://github.com/simstudioai/sim/pull/6752/files#diff-bf18028615819590a8db4f975a917d4a1885a8209f47999ae0d505fa24b3b772
apps/sim/ee/workspace-forking/lib/copy/copy-resources.test.tshttps://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
View file https://github.com/simstudioai/sim/blob/a07e14bf9af159e4fa741c40fd77d3b689ad6bed/apps/sim/ee/workspace-forking/lib/copy/copy-resources.test.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/simstudioai/sim/pull/6752/{{ revealButtonHref }}
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
https://github.com/simstudioai/sim/pull/6752/files#diff-963c6ff31e66e98956f6635d910841a48e456cf551f33319f6f1dfc6e9789287
apps/sim/ee/workspace-forking/lib/copy/copy-resources.tshttps://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
View file https://github.com/simstudioai/sim/blob/a07e14bf9af159e4fa741c40fd77d3b689ad6bed/apps/sim/ee/workspace-forking/lib/copy/copy-resources.ts
Open in desktop https://desktop.github.com
https://github.co/hiddenchars
https://github.com/simstudioai/sim/pull/6752/{{ revealButtonHref }}
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
https://github.com/simstudioai/sim/pull/6752/files#diff-8090f65dbd57000145cea8bb14673ad7008ab9c9bf550c267d736e4abf3c7ffb
Please reload this pagehttps://github.com/simstudioai/sim/pull/6752/files
Please reload this pagehttps://github.com/simstudioai/sim/pull/6752/files
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.