CorterraSolutions / SolutionDependencyChecker

For a Dynamics CRM, 365, or Dataverse solution, check if the dependencies for the solution deployment all exist in the target environment
MIT License
4 stars 5 forks source link

Solution file size limit? #12

Closed lambeck closed 1 year ago

lambeck commented 1 year ago

I'm trying to check dependencies on a fairly large solution file (7305 KB). It's definitely a valid file, but I keep getting "File is invalid. Please check you loaded a valid solution file". Is there a size limit? Thanks!

bonomo1 commented 1 year ago

@lambeck There should not be any limitations on size. I am fairly certain we tested solutions double the size of that.

Can you provide some more details (questions below)

  1. Version of CRM, D365 CE, Dataverse the solution was built on?
  2. Version of CRM, D365, CE, Dataverse for the target environment?
  3. Types of components in the solution (entities, option sets, web resources etc.)
  4. Does the file end in .zip?
bonomo1 commented 1 year ago

Location in code where this message is raised. image

Tested this myself and I am getting the same error message with a new solution in v9.1 or above when containing components not available in version 8.2 and below. For instance, SVG icon.

We will have to fix.

bonomo1 commented 1 year ago

Doesn't appear to be SVG icon as that is component type 61 of Web Resource.

Will have to dig into this more. Could be the "formulas" folder. Screenshot of solution that is failing for me as well

image

lambeck commented 1 year ago

Thanks for getting back to me!

Version of CRM, D365 CE, Dataverse the solution was built on? Version of CRM, D365, CE, Dataverse for the target environment? Our app uses some elements of D365 Project Operations (version 4.57.0.176), but most of it is custom. Both the source and destination environments have the same version.

Types of components in the solution (entities, option sets, web resources etc.) The solution file includes:

Does the file end in .zip? Yes. I've tried both managed and unmanaged.

I have a feeling that the problem might have to do with the Custom Pages :( Please let me know if you need any other information!

bonomo1 commented 1 year ago

@lambeck Thank you for getting back to me. Will try my best to look into this as soon as I can and hope it's an easy fix. My fear is it will be a large overhaul based on changes in solutions that may take a couple of months to get prioritized on our end. I'll let you know one way or another soon.

bonomo1 commented 1 year ago

Some news...created a blank solution and it threw the same error. No components at all. Not sure if that is good (i.e. quick fix) or bad (complete re-write)

image

bonomo1 commented 1 year ago

Error on my end from the log file

. The import file is invalid. XSD validation failed with the following error: 'The element 'ImportExportXml' has invalid child element 'EntityDataProviders'.

Looks like its not handling virtual data sources in the solution file.

@lambeck

Can you check the log file for the plugin? If you don't know where that is, you can find it under Configuration > Settings > Paths > Open XrmToolBox storage folder

image

Then open the log file for the XRMSolutionDependencyChecker

image

Assuming you get same error I am above

bonomo1 commented 1 year ago

Temporary workaround.

Unzip solution. Open customizations.xml

Remove note for "EntityDataProviders"

image

Worked with a testing solution I had but so many components now your experience may differ. Solution was still importable on my end but use this workaround at your own risk until I can get an update out there

bonomo1 commented 1 year ago

I should just have to update the references (note to myself more than anything) to target the latest and test to ensure still has backwards compatibility.

  <package id="Microsoft.CrmSdk.CoreAssemblies" version="9.0.2.5" targetFramework="net462" />
  <package id="Microsoft.CrmSdk.Deployment" version="9.0.2.5" targetFramework="net462" />
  <package id="Microsoft.CrmSdk.Workflow" version="9.0.2.5" targetFramework="net462" />
lambeck commented 1 year ago

Here's what I'm seeing in XRMSolutionDependencyChecker.log. I don't see anything about EntityDataProviders, but I will try your suggestion and let you know.

Exception details: ErrorCode: 0x80040216 Message: System.FormatException: Input string was not in a correct format. at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +0x5c at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +0x20 at Microsoft.Crm.Tools.ImportExportPublish.ImportXml.RetrieveMissingComponents() +0x0 at Microsoft.Crm.WebServices.ImportXmlService.RetrieveMissingComponents(Byte[] customizationXml, ExecutionContext context) +0x25: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #975140B4 TimeStamp: 2023-01-26T16:24:58.1463179Z

). 2023-01-26 02:21:52.490 PM CNP FSM PROD Info System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]: An unexpected error occurred. (Fault Detail is equal to Exception details: ErrorCode: 0x80040216 Message: An unexpected error occurred. TimeStamp: 2023-01-26T19:21:53.0347412Z

Exception details: ErrorCode: 0x80040216 Message: System.FormatException: Input string was not in a correct format. at System.Number.StringToNumber(String str, NumberStyles options, NumberBuffer& number, NumberFormatInfo info, Boolean parseDecimal) +0x5c at System.Number.ParseInt32(String s, NumberStyles style, NumberFormatInfo info) +0x20 at Microsoft.Crm.Tools.ImportExportPublish.ImportXml.RetrieveMissingComponents() +0x0 at Microsoft.Crm.WebServices.ImportXmlService.RetrieveMissingComponents(Byte[] customizationXml, ExecutionContext context) +0x25: Microsoft Dynamics CRM has experienced an error. Reference number for administrators or support: #5356230F TimeStamp: 2023-01-26T19:21:53.0347412Z

lambeck commented 1 year ago

Sorry, no, same error :(

bonomo1 commented 1 year ago

Quick update. My plan is to look further into this and hopefully resolve this weekend.

bonomo1 commented 1 year ago

Apologies for the delay on this. Got busy with client work. Getting this into a team members queue to resolve soon hopefully

lambeck commented 1 year ago

No worries! Work is busy here too 🙂 Thanks for following up!


From: Joe Bonomo @.> Sent: Tuesday, March 28, 2023 9:42 PM To: CorterraSolutions/SolutionDependencyChecker @.> Cc: Lori Beck @.>; Mention @.> Subject: Re: [CorterraSolutions/SolutionDependencyChecker] Solution file size limit? (Issue #12)

Apologies for the delay on this. Got busy with client work. Getting this into a team members queue to resolve soon hopefully

— Reply to this email directly, view it on GitHubhttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2FCorterraSolutions%2FSolutionDependencyChecker%2Fissues%2F12%23issuecomment-1487828785&data=05%7C01%7C%7C0a83d8c4163340a75b7308db2ff6cc13%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638156509250132709%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=zMk4D2QpHiZ4dz10WKmZjAV%2BpT3cCWLXSRGvZtKgmyQ%3D&reserved=0, or unsubscribehttps://na01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAAYH35LITHLIFB75DOBCSULW6OHOVANCNFSM6AAAAAAUHVTRIU&data=05%7C01%7C%7C0a83d8c4163340a75b7308db2ff6cc13%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638156509250132709%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=dC9XQUDK%2FPC7p%2FhhDDuHDOh7qBuvmrSZQ8bNw5xOCnY%3D&reserved=0. You are receiving this because you were mentioned.Message ID: @.***>

bonomo1 commented 1 year ago

@lambeck

Finally got around to looking into this. I updated a few bugs that could be causing your issue and implemented a new check for the version of the solution to the target environment in the connection.

Just dropped the update in nuget if you want to check sometime later today or tomorrow if your issue is resolved. These updates solved the errors I was able to replicate, but that being said there could be other things going on without having your source file/target environment. Let me know how it goes :)

I should confirm, make sure using version 1.3.4. Had issue in 1.3.3 as I haven't developed the plugin for a while and missed a version update causing XRM Toolbox to constantly prompt to update

bonomo1 commented 1 year ago

Closing this issue for now