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

New-M365DSCDeltaReport: Error: Cannot bind argument to parameter 'DifferenceObject' because it is null #3478

Open
ChrisJay77 opened this issue Jul 17, 2023 · 6 comments · Fixed by #3526 or #3568
Labels
Bug Something isn't working Core Engine

Comments

@ChrisJay77
Copy link

ChrisJay77 commented Jul 17, 2023

Details of the scenario you tried and the problem that is occurring

when changing any config on the tenant, i export the config using:
Export-M365DSCConfiguration -ApplicationId 0791df04-ee1a-4931-9995-XXXXX -TenantId XXXX.onmicrosoft.com -CertificateThumbprint XXXXXXXXXXXXXXXXXXX -Workloads @("intune") -Path C:\t1\july2023
change the av and profile config values:
Export-M365DSCConfiguration -ApplicationId 0791df04-ee1a-4931-9995-XXXXX -TenantId XXXX.onmicrosoft.com -CertificateThumbprint XXXXXXXXXXXXXXXXXXX -Workloads @("intune") -Path C:\t1\july2023\changed
then run the following:
New-M365DSCDeltaReport -Source 'C:\T1\july2023\M365TenantConfig.ps1' -Destination 'C:\t1\july2023\changed\M365TenantConfig.ps1' -OutputPath 'C:\Reports\ComparsionReport.html' -DriftOnly $true -Verbose

Verbose logs showing the problem

VERBOSE: Obtaining Delta between the source and destination configurations
VERBOSE: Loading file 'C:\T1\july2023\M365TenantConfig.ps1'
VERBOSE: Loading file 'C:\t1\july2023\changed\M365TenantConfig.ps1'
Error: Cannot bind argument to parameter 'DifferenceObject' because it is null.
Error: Cannot bind argument to parameter 'DifferenceObject' because it is null.
Error: Cannot bind argument to parameter 'DifferenceObject' because it is null.

Suggested solution to the issue

t

The DSC configuration that is used to reproduce the issue (as detailed as possible)

# insert configuration here

The operating system the target node is running

Win10

Version of the DSC module that was used ('dev' if using current dev branch)

C:\Program Files\WindowsPowerShell\Modules\Microsoft365DSC\1.23.712.1

@andikrueger andikrueger added Bug Something isn't working Core Engine Pending Information and removed Bug Something isn't working labels Jul 17, 2023
@andikrueger
Copy link
Collaborator

Were you able to verify the content of both configurations? Any chance that one of the configuration does not have any content?

@ChrisJay77
Copy link
Author

M365TenantConfig_changed.zip
M365TenantConfig_first.zip
Please see both files, it's a test environment so no sensitive information is included. thanks

@ChrisJay77
Copy link
Author

Were you able to verify the content of both configurations? Any chance that one of the configuration does not have any content?

You can run the New-M365DSCReportFromConfiguration -Type 'HTML' -ConfigurationPath 'C:\T1\july2023\M365TenantConfig_first.ps1' -OutputPath 'C:\reports\M365Report_july2023_inital.html'' and can see the config not sure if it's limted to the New-M365DSCDeltaReport module?

@ChrisJay77
Copy link
Author

Were you able to verify the content of both configurations? Any chance that one of the configuration does not have any content?

Have you managed to compare the attached reports and replicate the same error? Thanks

@NikCharlebois
Copy link
Collaborator

Update: I am able to replicate in my environment. Will investigate further

@andikrueger andikrueger added Bug Something isn't working and removed Pending Information labels Jul 28, 2023
NikCharlebois added a commit to NikCharlebois/Microsoft365DSC that referenced this issue Jul 28, 2023
@ChrisJay77
Copy link
Author

Update: I am able to replicate in my environment. Will investigate further

Hi, same error in version 1.23.920.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Core Engine
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants