Skip to content

Version later than 3.5.15 breaking my pipeline #301

@gesnaud

Description

@gesnaud

Hello there,

I have a pipeline to generate XLS and XML files from ARI.

I've based the pipeline on version 3.5.15 and tried the latest (3.6.17) and pretty all other versions between latest and 3.5.15.
The version are took from here: https://www.powershellgallery.com/packages/AzureResourceInventory/3.6.4

for example:

3.5.17:

Invoke-ARI: /home/vsts/work/_temp/5b2d8ebc-89c6-48d0-9a05-6e5a29f1b5e5.ps1:4
Line |
   4 |  Invoke-ARI -ReportDir "./" -ReportName Bleucloudlab -TenantID xxxxx …
     |  ~~~~~~~~~~
     | The term 'Invoke-ARI' is not recognized as a name of a cmdlet, function,
     | script file, or executable program. Check the spelling of the name, or
     | if a path was included, verify that the path is correct and try again.

3.5.17 bis:

Import-Module: /home/vsts/work/_temp/5dd19c77-ece6-43c8-9eb0-4f5dc1aa673f.ps1:4
Line |
   4 |  Import-Module AzureResourceInventory
     |  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | The specified module 'AzureResourceInventory' was not loaded because no
     | valid module file was found in any module directory.

3.6.4:

WARNING: Failed adding PivotTable 'P0': Cannot index into a null array.
WARNING: Failed adding chart for pivotable 'P0': Cannot bind argument to parameter 'PivotTable' because it is null.
Write-Error: /home/vsts/.local/share/powershell/Modules/AzureResourceInventory/3.6.4/modules/Private/3.ReportingFunctions/StyleFunctions/Start-ARIExcelCustomization.ps1:92
Line |
  92 |              Build-ARIExcelComObject -File $File
     |              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | A parameter cannot be found that matches parameter name 'ComObject'.

3.6.0:

There will be breaking changes from 12.1.0 to 13.4.0. Open https://go.microsoft.com/fwlink/?linkid=2241373 and check the details.
Invoke-ARI: /home/vsts/work/_temp/c5e2537a-755b-49a6-be2f-0ed57c247018.ps1:4
Line |
   4 |  Invoke-ARI -ReportDir "./" -ReportName Bleucloudlab -TenantID xxxxx …
     |  ~~~~~~~~~~
     | The term 'Invoke-ARI' is not recognized as a name of a cmdlet, function,
     | script file, or executable program. Check the spelling of the name, or
     | if a path was included, verify that the path is correct and try again.

The pipeline code innvoking ARI is the following:

 - task: AzurePowerShell@5
    displayName: 'Running ARI'
    inputs:
      azurePowerShellVersion: latestVersion
      azureSubscription: my_sc
      ScriptType: 'InlineScript'
      pwsh: true
      Inline: |
         Import-Module AzureResourceInventory # <===== This one is sometimes commented depending version used, like 3.5.17 (even if the doc mention to use it 🙃!)
         Invoke-ARI -ReportDir "./" -ReportName $(organizationName) -TenantID ${{ variables.tenantid }} -SubscriptionID ${{ variables.subscriptionid }} -DiagramFullEnvironment -SecurityCenter

Anything I can do or must stick on 3.5.15?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions