API - Filter by version - `$filter=NormalizedVersion gt '9'` does not return any newer major versions
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 35/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Estagnada
- Stack de tecnologia
- powershell
- Domínio
- api
Direção de pesquisa
Start by tracing how the PowerShell Gallery API applies filters and ordering to the Version and NormalizedVersion fields for package queries. Reproduce the supplied Az query and compare its results with the expected major-version behavior; done means the query returns the newest version at or above major version 9, including versions 10 and 11.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest version
- Search the existing issues.
Steps to reproduce
If you want to specify a minimum major version to return, you can do $filter=NormalizedVersion gt '9'.
If the module you're searching for has newer major versions than 9, say 10, the API won't return it.
Example request for Az, where I want the newest version returned, but at least major version 9:
More human friendly view:
# Filter on Version
[uri]::EscapeUriString(
'https://www.powershellgallery.com/api/v2/Packages()?' +
"`$filter=Id eq 'Az' and Version ge '9'&" +
'$orderby=Version desc&' +
'$top=1&' +
'$select=NormalizedVersion,Version'
).Replace("'",'%27') | Set-Clipboard
# Filter on NormalizedVersion
[uri]::EscapeUriString(
'https://www.powershellgallery.com/api/v2/Packages()?' +
"`$filter=Id eq 'Az' and NormalizedVersion ge '9'&" +
'$orderby=NormalizedVersion desc&' +
'$top=1&' +
'$select=NormalizedVersion,Version'
).Replace("'",'%27') | Set-Clipboard
Expected behavior
- Example returns newest version, but at least version 9.
- I expected (as of writing) v11.5.0.
Actual behavior
Example returns version v9.7.1; the newest v9 version before major jumped to v10 and beyond.
Error details
No response
Environment data
Not relevant, API
Version
Not relevant, API
Visuals
No response
- Linguagem predominante
- PowerShell
- Estrelas
- 289
- Forks
- 83
- Merge médio
- 1min
- PRs com merge (30d)
- 1
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de PowerShell/PowerShellGallery
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 38/100
PowerShell/PowerShellGallery#357 · 3 comentários · 4 reações ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 48/100
PowerShell/PowerShellGallery#355 ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 31/100
PowerShell/PowerShellGallery#354 · 1 comentário · 3 reações ·
-
Dificuldade 5/5 Mais de uma semana Facilidade para iniciantes 35/100
PowerShell/PowerShellGallery#353 · 5 reações ·
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
PowerShell/PowerShellGallery#350 · 7 comentários · 8 reações ·
Todas as issues de PowerShell/PowerShellGallery
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
Mantenedores costumam responder em até 1 dia
-
5.0.x backport enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 63/100
spring-cloud/spring-cloud-function#1507 ·
Mantenedores costumam responder em até 1 dia
-
cost:cheap practicality:seen-in-the-wild severity:medium
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
fairagro/m4.2_advanced_middleware_api#620 ·
Mantenedores costumam responder em até 1 dia
-
reproduced
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
anomalyco/opencode#61391 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
ai-driven-fuzzing bug claude Minor
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 77/100
linagora/open-bastion#422 ·
Mantenedores costumam responder em até 1 dia