mirror of
https://github.com/catdevnull/transicion-desordenada-diablo
synced 2024-11-26 11:26:18 +00:00
Compare commits
2 commits
6b75cea27a
...
c26cc2d263
Author | SHA1 | Date | |
---|---|---|---|
c26cc2d263 | |||
e1d208b63c |
4 changed files with 12 additions and 5 deletions
|
@ -1,5 +1,5 @@
|
||||||
import streamSaver from "streamsaver";
|
import streamSaver from "streamsaver";
|
||||||
import { zData, type Distribution, zError, zDumpMetadata } from "common/schema";
|
import { zData, type Distribution, zDumpError, zDumpMetadata } from "common/schema";
|
||||||
|
|
||||||
export async function downloadFile(
|
export async function downloadFile(
|
||||||
dataPath: string,
|
dataPath: string,
|
||||||
|
@ -73,6 +73,6 @@ export async function fetchErrors(url: string) {
|
||||||
.split("\n")
|
.split("\n")
|
||||||
.filter((line) => !!line)
|
.filter((line) => !!line)
|
||||||
.map((line) => JSON.parse(line))
|
.map((line) => JSON.parse(line))
|
||||||
.map((json) => zError.parse(json));
|
.map((json) => zDumpError.parse(json));
|
||||||
return lines;
|
return lines;
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
|
|
||||||
$: data = Promise.all([fetchData(url), fetchErrors(url)])
|
$: data = Promise.all([fetchData(url), fetchErrors(url)])
|
||||||
.then(([data, errors]) => ({ data, errors }))
|
.then(([data, errors]) => ({ data, errors }))
|
||||||
.catch(alert);
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<main class="mx-auto max-w-3xl">
|
<main class="mx-auto max-w-3xl">
|
||||||
|
@ -102,6 +101,8 @@
|
||||||
{/each}
|
{/each}
|
||||||
</ul>
|
</ul>
|
||||||
{/if}
|
{/if}
|
||||||
|
{:catch error}
|
||||||
|
Hubo un error intenando cargar este dataset archivado. <pre>{error}</pre>
|
||||||
{/await}
|
{/await}
|
||||||
</Container>
|
</Container>
|
||||||
</main>
|
</main>
|
||||||
|
|
|
@ -32,12 +32,19 @@
|
||||||
<!-- nPortales: find . -maxdepth 1 -mindepth 1 -type d | wc -l -->
|
<!-- nPortales: find . -maxdepth 1 -mindepth 1 -type d | wc -l -->
|
||||||
<!-- nDatasets: jq '.dataset | length' */data.json | awk '{s+=$1} END {print s}' -->
|
<!-- nDatasets: jq '.dataset | length' */data.json | awk '{s+=$1} END {print s}' -->
|
||||||
<!-- size: du -sh -->
|
<!-- size: du -sh -->
|
||||||
|
<Dump
|
||||||
|
dumpUrl="https://archivos.nulo.ar/portales-de-datos/dump-2023-12-09/"
|
||||||
|
nPortales={51}
|
||||||
|
nDatasets={4157}
|
||||||
|
size="155 GB"
|
||||||
|
glow>29 de diciembre de 2023</Dump
|
||||||
|
>
|
||||||
<Dump
|
<Dump
|
||||||
dumpUrl="https://archivos.nulo.ar/portales-de-datos/dump-2023-12-09/"
|
dumpUrl="https://archivos.nulo.ar/portales-de-datos/dump-2023-12-09/"
|
||||||
nPortales={50}
|
nPortales={50}
|
||||||
nDatasets={4098}
|
nDatasets={4098}
|
||||||
size="147 GB"
|
size="147 GB"
|
||||||
glow>9 de diciembre de 2023</Dump
|
>9 de diciembre de 2023</Dump
|
||||||
>
|
>
|
||||||
<Dump
|
<Dump
|
||||||
dumpUrl="https://archivos.nulo.ar/dump-2023-12-08/"
|
dumpUrl="https://archivos.nulo.ar/dump-2023-12-08/"
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
|
|
||||||
$: data = Promise.all([fetchData(url), fetchErrors(url)])
|
$: data = Promise.all([fetchData(url), fetchErrors(url)])
|
||||||
.then(([data, errors]) => ({ data, errors }))
|
.then(([data, errors]) => ({ data, errors }))
|
||||||
.catch(alert);
|
|
||||||
|
|
||||||
function arreglarHomepageUrl(url: string): string {
|
function arreglarHomepageUrl(url: string): string {
|
||||||
if (!url.startsWith("http://") && !url.startsWith("https://"))
|
if (!url.startsWith("http://") && !url.startsWith("https://"))
|
||||||
|
|
Loading…
Reference in a new issue