Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: ignored, decomposed parent #1053

Merged
merged 1 commit into from
Jul 24, 2023
Merged

Conversation

mshanemc
Copy link
Contributor

@mshanemc mshanemc commented Jul 24, 2023

What does this PR do?

top-level Decomposed types could be retrieved with *

What issues does this PR fix or reference?

@W-13813099@

repro w/ Dreamhouse

put Broker__c in your forceignore like **/objects/Broker__c
delete objects/Broker__c folder from local project
sf project retrieve start --metadata CustomObject (this will cause * for CustomObject)

you see broker retrieved without this PR.

@mshanemc mshanemc requested a review from a team as a code owner July 24, 2023 19:24
@mshanemc mshanemc changed the title test: ut for forceignore of decomposed parent fix: ignored, decomposed parent Jul 24, 2023
@WillieRuemmele
Copy link
Member

QA Results


✅ : following instructions

 ➜  vim .forceignore                  // add Broker__c
➜  dreamhouse-lwc git:(main) ✗  hub:(DevHub) scratch:([email protected])
 ➜  rm -rf force-app/main/default/objects/Broker__c 
➜  dreamhouse-lwc git:(main) ✗  hub:(DevHub) scratch:([email protected])
 ➜  sf project retrieve start -m CustomObject                                                      
Retrieving v58.0 metadata from [email protected] using the v58.0 SOAP API
Preparing retrieve request... Succeeded

Retrieved Source
====================================================================================================================================================================
| State   Name                                Type          Path                                                                                                     
| ─────── ─────────────────────────────────── ───────────── ──────────────────────────────────────────────────────────────────────────────────────────────────────── 
| Changed Property__c.Property_Compact_Layout CompactLayout force-app/main/default/objects/Property__c/compactLayouts/Property_Compact_Layout.compactLayout-meta.xml 
| Changed Property__c.Address__c              CustomField   force-app/main/default/objects/Property__c/fields/Address__c.field-meta.xml                              
| Changed Property__c.Assessed_Value__c       CustomField   force-app/main/default/objects/Property__c/fields/Assessed_Value__c.field-meta.xml                       
| Changed Property__c.Baths__c                CustomField   force-app/main/default/objects/Property__c/fields/Baths__c.field-meta.xml                                
| Changed Property__c.Beds__c                 CustomField   force-app/main/default/objects/Property__c/fields/Beds__c.field-meta.xml                                 
| Changed Property__c.Broker__c               CustomField   force-app/main/default/objects/Property__c/fields/Broker__c.field-meta.xml                               
| Changed Property__c.City__c                 CustomField   force-app/main/default/objects/Property__c/fields/City__c.field-meta.xml                                 
| Changed Property__c.Date_Agreement__c       CustomField   force-app/main/default/objects/Property__c/fields/Date_Agreement__c.field-meta.xml                       
| Changed Property__c.Date_Closed__c          CustomField   force-app/main/default/objects/Property__c/fields/Date_Closed__c.field-meta.xml                          
| Changed Property__c.Date_Contracted__c      CustomField   force-app/main/default/objects/Property__c/fields/Date_Contracted__c.field-meta.xml                      
| Changed Property__c.Date_Listed__c          CustomField   force-app/main/default/objects/Property__c/fields/Date_Listed__c.field-meta.xml                          
| Changed Property__c.Date_Pre_Market__c      CustomField   force-app/main/default/objects/Property__c/fields/Date_Pre_Market__c.field-meta.xml                      
| Changed Property__c.Days_On_Market__c       CustomField   force-app/main/default/objects/Property__c/fields/Days_On_Market__c.field-meta.xml                       
| Changed Property__c.Description__c          CustomField   force-app/main/default/objects/Property__c/fields/Description__c.field-meta.xml                          
| Changed Property__c.Location__c             CustomField   force-app/main/default/objects/Property__c/fields/Location__c.field-meta.xml                             
| Changed Property__c.Picture_IMG__c          CustomField   force-app/main/default/objects/Property__c/fields/Picture_IMG__c.field-meta.xml                          
| Changed Property__c.Picture__c              CustomField   force-app/main/default/objects/Property__c/fields/Picture__c.field-meta.xml                              
| Changed Property__c.Price_Sold__c           CustomField   force-app/main/default/objects/Property__c/fields/Price_Sold__c.field-meta.xml                           
| Changed Property__c.Price__c                CustomField   force-app/main/default/objects/Property__c/fields/Price__c.field-meta.xml                                
| Changed Property__c.Record_Link__c          CustomField   force-app/main/default/objects/Property__c/fields/Record_Link__c.field-meta.xml                          
| Changed Property__c.State__c                CustomField   force-app/main/default/objects/Property__c/fields/State__c.field-meta.xml                                
| Changed Property__c.Status__c               CustomField   force-app/main/default/objects/Property__c/fields/Status__c.field-meta.xml                               
| Changed Property__c.Tags__c                 CustomField   force-app/main/default/objects/Property__c/fields/Tags__c.field-meta.xml                                 
| Changed Property__c.Thumbnail_IMG__c        CustomField   force-app/main/default/objects/Property__c/fields/Thumbnail_IMG__c.field-meta.xml                        
| Changed Property__c.Thumbnail__c            CustomField   force-app/main/default/objects/Property__c/fields/Thumbnail__c.field-meta.xml                            
| Changed Property__c.Zip__c                  CustomField   force-app/main/default/objects/Property__c/fields/Zip__c.field-meta.xml                                  
| Changed Property__c                         CustomObject  force-app/main/default/objects/Property__c/Property__c.object-meta.xml                                   
| Changed Property__c.All                     ListView      force-app/main/default/objects/Property__c/listViews/All.listView-meta.xml                               
➜  dreamhouse-lwc git:(main) ✗  hub:(DevHub) scratch:([email protected])
 ➜  vim .forceignore                              // delete broker__c entry    
➜  dreamhouse-lwc git:(main) ✗  hub:(DevHub) scratch:([email protected])
 ➜  sf project retrieve start -m CustomObject  
Retrieving v58.0 metadata from [email protected] using the v58.0 SOAP API
Preparing retrieve request... Succeeded

Retrieved Source
====================================================================================================================================================================
| State   Name                                Type          Path                                                                                                     
| ─────── ─────────────────────────────────── ───────────── ──────────────────────────────────────────────────────────────────────────────────────────────────────── 
| Changed Broker__c.Broker_Compact            CompactLayout force-app/main/default/objects/Broker__c/compactLayouts/Broker_Compact.compactLayout-meta.xml            
| Changed Property__c.Property_Compact_Layout CompactLayout force-app/main/default/objects/Property__c/compactLayouts/Property_Compact_Layout.compactLayout-meta.xml 
| Changed Broker__c.Broker_Id__c              CustomField   force-app/main/default/objects/Broker__c/fields/Broker_Id__c.field-meta.xml                              
| Changed Broker__c.Email__c                  CustomField   force-app/main/default/objects/Broker__c/fields/Email__c.field-meta.xml                                  
| Changed Broker__c.Mobile_Phone__c           CustomField   force-app/main/default/objects/Broker__c/fields/Mobile_Phone__c.field-meta.xml                           
| Changed Broker__c.Phone__c                  CustomField   force-app/main/default/objects/Broker__c/fields/Phone__c.field-meta.xml                                  
| Changed Broker__c.Picture_IMG__c            CustomField   force-app/main/default/objects/Broker__c/fields/Picture_IMG__c.field-meta.xml                            
| Changed Broker__c.Picture__c                CustomField   force-app/main/default/objects/Broker__c/fields/Picture__c.field-meta.xml                                
| Changed Broker__c.Title__c                  CustomField   force-app/main/default/objects/Broker__c/fields/Title__c.field-meta.xml                                  
| Changed Property__c.Address__c              CustomField   force-app/main/default/objects/Property__c/fields/Address__c.field-meta.xml                              
| Changed Property__c.Assessed_Value__c       CustomField   force-app/main/default/objects/Property__c/fields/Assessed_Value__c.field-meta.xml                       
| Changed Property__c.Baths__c                CustomField   force-app/main/default/objects/Property__c/fields/Baths__c.field-meta.xml                                
| Changed Property__c.Beds__c                 CustomField   force-app/main/default/objects/Property__c/fields/Beds__c.field-meta.xml                                 
| Changed Property__c.Broker__c               CustomField   force-app/main/default/objects/Property__c/fields/Broker__c.field-meta.xml                               
| Changed Property__c.City__c                 CustomField   force-app/main/default/objects/Property__c/fields/City__c.field-meta.xml                                 
| Changed Property__c.Date_Agreement__c       CustomField   force-app/main/default/objects/Property__c/fields/Date_Agreement__c.field-meta.xml                       
| Changed Property__c.Date_Closed__c          CustomField   force-app/main/default/objects/Property__c/fields/Date_Closed__c.field-meta.xml                          
| Changed Property__c.Date_Contracted__c      CustomField   force-app/main/default/objects/Property__c/fields/Date_Contracted__c.field-meta.xml                      
| Changed Property__c.Date_Listed__c          CustomField   force-app/main/default/objects/Property__c/fields/Date_Listed__c.field-meta.xml                          
| Changed Property__c.Date_Pre_Market__c      CustomField   force-app/main/default/objects/Property__c/fields/Date_Pre_Market__c.field-meta.xml                      
| Changed Property__c.Days_On_Market__c       CustomField   force-app/main/default/objects/Property__c/fields/Days_On_Market__c.field-meta.xml                       
| Changed Property__c.Description__c          CustomField   force-app/main/default/objects/Property__c/fields/Description__c.field-meta.xml                          
| Changed Property__c.Location__c             CustomField   force-app/main/default/objects/Property__c/fields/Location__c.field-meta.xml                             
| Changed Property__c.Picture_IMG__c          CustomField   force-app/main/default/objects/Property__c/fields/Picture_IMG__c.field-meta.xml                          
| Changed Property__c.Picture__c              CustomField   force-app/main/default/objects/Property__c/fields/Picture__c.field-meta.xml                              
| Changed Property__c.Price_Sold__c           CustomField   force-app/main/default/objects/Property__c/fields/Price_Sold__c.field-meta.xml                           
| Changed Property__c.Price__c                CustomField   force-app/main/default/objects/Property__c/fields/Price__c.field-meta.xml                                
| Changed Property__c.Record_Link__c          CustomField   force-app/main/default/objects/Property__c/fields/Record_Link__c.field-meta.xml                          
| Changed Property__c.State__c                CustomField   force-app/main/default/objects/Property__c/fields/State__c.field-meta.xml                                
| Changed Property__c.Status__c               CustomField   force-app/main/default/objects/Property__c/fields/Status__c.field-meta.xml                               
| Changed Property__c.Tags__c                 CustomField   force-app/main/default/objects/Property__c/fields/Tags__c.field-meta.xml                                 
| Changed Property__c.Thumbnail_IMG__c        CustomField   force-app/main/default/objects/Property__c/fields/Thumbnail_IMG__c.field-meta.xml                        
| Changed Property__c.Thumbnail__c            CustomField   force-app/main/default/objects/Property__c/fields/Thumbnail__c.field-meta.xml                            
| Changed Property__c.Zip__c                  CustomField   force-app/main/default/objects/Property__c/fields/Zip__c.field-meta.xml                                  
| Changed Broker__c                           CustomObject  force-app/main/default/objects/Broker__c/Broker__c.object-meta.xml                                       
| Changed Property__c                         CustomObject  force-app/main/default/objects/Property__c/Property__c.object-meta.xml                                   
| Changed Broker__c.All                       ListView      force-app/main/default/objects/Broker__c/listViews/All.listView-meta.xml                                 
| Changed Property__c.All                     ListView      force-app/main/default/objects/Property__c/listViews/All.listView-meta.xml          

✅ : variations on forceignore
✅ : remote source tracking situations
✅ : **/objects/Broker__c/fields/** in .forceignore and -m CustomObject will retrieve Broker, except fields
✅ : entire objects dir

@WillieRuemmele WillieRuemmele merged commit 2f281d1 into main Jul 24, 2023
@WillieRuemmele WillieRuemmele deleted the sm/decomposed-ignored-parent branch July 24, 2023 20:59
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.

3 participants