refactor(conan): Use single cache namespace (#31033)

This commit is contained in:
Sergei Zharinov 2024-08-27 00:31:46 -03:00 committed by GitHub
parent 9dbe905e6d
commit 51ca6957e2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 3 additions and 4 deletions

View file

@ -74,10 +74,10 @@ export class ConanDatasource extends Datasource {
}
@cache({
namespace: `datasource-${datasource}-revisions`,
namespace: `datasource-${datasource}`,
key: ({ registryUrl, packageName }: DigestConfig, newValue?: string) =>
// TODO: types (#22198)
`${registryUrl!}:${packageName}:${newValue!}`,
`getDigest:${registryUrl!}:${packageName}:${newValue!}`,
})
override async getDigest(
{ registryUrl, packageName }: DigestConfig,
@ -106,7 +106,7 @@ export class ConanDatasource extends Datasource {
namespace: `datasource-${datasource}`,
key: ({ registryUrl, packageName }: GetReleasesConfig) =>
// TODO: types (#22198)
`${registryUrl}:${packageName}`,
`getReleases:${registryUrl}:${packageName}`,
})
async getReleases({
registryUrl,

View file

@ -36,7 +36,6 @@ export type PackageCacheNamespace =
| 'datasource-bitrise'
| 'datasource-cdnjs-digest'
| 'datasource-cdnjs'
| 'datasource-conan-revisions'
| 'datasource-conan'
| 'datasource-conda'
| 'datasource-cpan'