import type { LockfileObject } from '@pnpm/lockfile.types'; import type { DependenciesField, DepPath, ProjectId, SupportedArchitectures } from '@pnpm/types'; export interface FilterLockfileResult { lockfile: LockfileObject; selectedImporterIds: ProjectId[]; /** * Dep paths reached by a non-optional edge from an importer or from a * package that is itself part of the install. Their installability is * evaluated as non-optional — an incompatible one fails the install under * `engineStrict` instead of being skipped — even when the lockfile marks * the snapshot `optional: true` because the subtree happens to hang off an * optional dependency. Downstream consumers must classify by this set * rather than by `pkgSnapshot.optional` so every stage of a headless * install agrees with the resolver, which classifies by edge too. */ requiredDepPaths: Set; } export declare function filterLockfileByEngine(lockfile: LockfileObject, opts: FilterLockfileOptions): FilterLockfileResult; export interface FilterLockfileOptions { currentEngine: { nodeVersion?: string; pnpmVersion: string; }; engineStrict: boolean; include: { [dependenciesField in DependenciesField]: boolean; }; includeIncompatiblePackages?: boolean; failOnMissingDependencies: boolean; lockfileDir: string; skipped: Set; skipRuntimes?: boolean; supportedArchitectures?: SupportedArchitectures; } export declare function filterLockfileByImportersAndEngine(lockfile: LockfileObject, importerIds: ProjectId[], opts: FilterLockfileOptions): FilterLockfileResult;