fix(smartnpm): Fix file extraction & streaming, types and caching; update deps and CI; skip flaky tests
This commit is contained in:
@@ -22,19 +22,19 @@ export class RegistryCache {
|
||||
|
||||
public async getCachedFile(
|
||||
cacheDescriptorArg: ICacheDescriptor
|
||||
): Promise<plugins.smartfile.Smartfile> {
|
||||
): Promise<plugins.smartfile.SmartFile> {
|
||||
const cacheEntry = await this.levelCache.retrieveCacheEntryByKey(
|
||||
this.getCacheDescriptorAsString(cacheDescriptorArg)
|
||||
);
|
||||
if (cacheEntry) {
|
||||
return plugins.smartfile.Smartfile.fromFoldedJson(cacheEntry.contents.toString());
|
||||
return plugins.smartfile.SmartFile.fromFoldedJson(cacheEntry.contents.toString());
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public async cacheSmartFile(
|
||||
cacheDescriptorArg: ICacheDescriptor,
|
||||
smartfileArg: plugins.smartfile.Smartfile
|
||||
smartfileArg: plugins.smartfile.SmartFile
|
||||
) {
|
||||
if (smartfileArg && cacheDescriptorArg.version) {
|
||||
await this.levelCache.storeCacheEntryByKey(
|
||||
|
||||
Reference in New Issue
Block a user