Skip to content
This repository has been archived by the owner on Feb 28, 2021. It is now read-only.

Get-LatestServicingStack -OperatingSystem Windows8 throws an error #58

Open
AndrewStrickland opened this issue Dec 17, 2019 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@AndrewStrickland
Copy link

Expected Behavior

Get-LatestServicingStack -OperatingSystem Windows8 Should return the latest Servicing Stack update

Current Behavior

Throws an error

Failure Information (for bugs)

Please help provide information about the failure if this is a bug by issuing the command using the -Verbose command.

Get-LatestServicingStack -OperatingSystem Windows8 -Verbose                                                 VERBOSE: Get-LatestServicingStackUpdate: get feed for Windows8.
VERBOSE: GET
https://support.microsoft.com/app/content/api/content/feeds/sap/en-us/b905caa1-d413-c90c-bed3-20aead901092/atom with
0-byte payload
VERBOSE: received -1-byte response of content type application/atom+xml; charset=utf-8
VERBOSE: Get-UpdateFeed: retrieved feed.
VERBOSE: Get-UpdateServicingStack: matched item [Servicing Stack Updates (SSU): Frequently Ask Questions]
VERBOSE: Get-UpdateServicingStack: matched item [Servicing stack update for Windows 8.1, RT 8.1, and Server 2012 R2:
November 12, 2019]
VERBOSE: Get-UpdateServicingStack: matched item [Servicing stack update for Windows 8.1, RT 8.1, and Server 2012 R2:
October 8, 2019]
VERBOSE: Get-UpdateServicingStack: matched item [Servicing stack update for Windows 8.1, RT 8.1, and Server 2012 R2:
September 10, 2019]
VERBOSE: Get-UpdateServicingStack: matched item [Servicing stack update for Windows Server 2012, Windows 8.1 and
Windows Server 2012 R2]
VERBOSE: Get-UpdateServicingStack: matched item [Servicing stack update for Windows 8.1 and Windows Server 2012 R2:
July 12, 2016]
VERBOSE: Get-UpdateServicingStack: selected item [Servicing Stack Updates (SSU): Frequently Ask Questions]
VERBOSE: Get-LatestServicingStackUpdate: update count is: .
VERBOSE: Get-LatestServicingStackUpdate: searching catalog for: [].
VERBOSE: Invoke-UpdateCatalogSearch: search Catalog for [KB4535697)]
VERBOSE: GET https://www.catalog.update.microsoft.com/Search.aspx?q=KB4535697 with 0-byte payload
VERBOSE: received 35833-byte response of content type text/html; charset=utf-8
VERBOSE: Get-UpdateCatalogDownloadInfo: returned 0 items from the catalog.
Add-Property : Cannot validate argument on parameter 'InputObject'. The argument is null or empty. Provide an argument
that is not null or empty, and then try the command again.
At C:\temp\LatestUpdate\Public\Get-LatestServicingStackUpdate.ps1:139 char:63
+ ...    $updateListWithVersion = Add-Property @updateListWithVersionParams
+                                              ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidData: (:) [Add-Property], ParameterBindingValidationException
    + FullyQualifiedErrorId : ParameterArgumentValidationError,Add-Property

Add-Property : Cannot validate argument on parameter 'InputObject'. The argument is null or empty. Provide an argument
that is not null or empty, and then try the command again.
At C:\temp\LatestUpdate\Public\Get-LatestServicingStackUpdate.ps1:146 char:60
+ ...          $updateListWithArch = Add-Property @updateListWithArchParams
+                                                 ~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidData: (:) [Add-Property], ParameterBindingValidationException
    + FullyQualifiedErrorId : ParameterArgumentValidationError,Add-Property

Steps to Reproduce

Please provide detailed steps for reproducing the issue.

  1. Import Module
  2. Run Get-LatestServicingStack -OperatingSystem Windows8

Context

Please provide any relevant information about your setup. This is important in case the issue is not reproducible except for under certain conditions.

  • LatestUpdate Version: Use Get-Module -ListAvailable LatestUpdate
Get-Module LatestUpdate                                                                                     
ModuleType Version    Name                                ExportedCommands
---------- -------    ----                                ----------------
Script     3.0.171    LatestUpdate                        {Get-LatestAdobeFlashUpdate, Get-LatestCumulativeUpdate, G...
  • PowerShell Version: Use Get-PSVersion
$PSVersionTable                                                                                             
Name                           Value
----                           -----
PSVersion                      5.1.18362.145
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.18362.145
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1
  • Operating System:
Get-WmiObject Win32_OperatingSystem | Select Version, Name                                                  
Version    Name
-------    ----
10.0.18363 Microsoft Windows 10 Enterprise

Proposed Fix

It seems it is because a KB was released with the title "Servicing Stack Updates (SSU): Frequently Ask Questions" which matches the search string. My issue was resolved by updating the resource string to be "ServicingStack" : "^Servicing stack update for.*",

Cheers

@aaronparker aaronparker self-assigned this Dec 19, 2019
@aaronparker aaronparker added the enhancement New feature or request label Dec 19, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants