-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
It should be possible to fetch .conda metadata (.tar.bz2 can't be streamed) with JS only. This works on the browser:
import { RemoteZipPointer } from "@basisai/remote-zip";
(async () => {
const url = new URL("https://conda.anaconda.org/conda-forge/linux-64/des-fitvd-0.9.19-py39hf3d152e_2.conda");
const remoteZip = await new RemoteZipPointer({ url }).populate();
const fileListing = remoteZip.files(); // RemoteZipFile[]
console.log(fileListing);
})();Resulting in:
[
{
"filename": "metadata.json",
"size": 31,
"modified": "2024-02-06T18:29:10",
"attributes": 25165824
},
{
"filename": "pkg-des-fitvd-0.9.19-py39hf3d152e_2.tar.zst",
"size": 93411,
"modified": "1980-01-01T00:00:00",
"attributes": 25165824
},
{
"filename": "info-des-fitvd-0.9.19-py39hf3d152e_2.tar.zst",
"size": 8325,
"modified": "1980-01-01T00:00:00",
"attributes": 25165824
}
]Paired with a zst library, we should be able to fetch the info/ bits like conda-package-streaming does. This could be implemented in the conda-forge.org website and only point here for the .tar.bz2 bits (which are provided by the OCI backend).
Metadata
Metadata
Assignees
Labels
No labels