Description
Currently, when using PSGalleryExplorer to retrieve metadata for a PowerShell module, the last updated field is based on information from the PowerShell Gallery. However, there may be cases where the module's repository has more up-to-date information on when it was last updated. This can lead to inconsistencies, where the module's last updated date in the gallery is not accurate.
As an example, consider the PSLeap module. The last updated field in the PowerShell Gallery metadata is January 28th, 2023. However, the module's repository shows that it hasn't been updated since June 8th, 2022. This is likely because the repository hasn't been updated, but the PowerShell Gallery metadata was updated for some other reason. This inconsistency can be confusing for users who are trying to determine the actual last updated date of the module.
$a.AdditionalMetadata
summary : A PowerShell smart filesystem bookmarking tool.
isLatestVersion : True
published : 6/8/2022 3:05:41 PM +01:00
lastUpdated : 1/28/2023 2:43:41 AM +00:00
SourceName : PSGallery
created : 6/8/2022 3:05:41 PM +01:00
description : A PowerShell smart filesystem bookmarking tool.
vs
$a.ProjectInfo
Name Value
---- -----
Updated 06/08/22 15:05:23
Created 06/08/22 05:49:21
Forks 0
Issues 0
Describe the solution you'd like
In the case of the PSLeap module, the last updated field should be based on the repository's information, rather than the PowerShell Gallery's information. This will ensure that the last updated field is accurate and consistent with the module's repository. If the repository doesn't have a last updated field, then the PowerShell Gallery's last updated field can be used as a fallback.
Describe any alternatives you've considered
One alternative solution would be to always prioritize the PowerShell Gallery's last updated field, regardless of whether the repository has more up-to-date information. However, this can lead to inconsistencies as mentioned before, and can be confusing for users who are trying to determine the actual last updated date of the module.
Additional context
This feature request is being made in response to inconsistencies observed between the last updated field in the PowerShell Gallery metadata and the repository information for the PSLeap module. Prioritizing the last updated field from the repository will help to ensure that the information in PSGalleryExplorer is accurate and consistent with the module's repository.