IRC logs for #farmOS, 2022-02-15 (GMT)

2022-02-14
2022-02-16
TimeNickMessage
[22:23:00]* jonasbits has quit (Ping timeout: 252 seconds)
[22:27:46]* jonasbits has joined #farmos
[00:22:38]* UgeshB[m] has joined #farmos
[00:23:45]<UgeshB[m]>@here i am not able get the files i uploaded through api as well as in UI i am getting the below error. someone please help me to resolve the issue ERROR: "Error generating image, missing source file."
[11:58:08]<symbioquine[m]>There were a few gotchas, but I figured out how to do KML Import with JupyterLite too: https://farmos.discourse.group/t/share-your-jupyterlite-examples/1134/7?...
[11:58:29]<symbioquine[m]>ACTION uploaded an image: (986KiB) < https://libera.ems.host/_matrix/media/r0/download/matrix.org/sYdsbsrgvWa... >
[11:58:39]<mstenta[m]>Whoa!
[12:12:03]<paul121[m]>> from pyodide.http import pyfetch
[12:12:03]<paul121[m]>this looks useful :-)
[12:12:26]<symbioquine[m]>Yeah
[12:12:45]<symbioquine[m]>https://pyodide.org/en/stable/usage/api/python-api.html#pyodide.http.pyf...
[12:14:42]<paul121[m]>so once concern I have with building importers here..... creating duplicate data by running the notebook twice
[12:15:19]<paul121[m]>each time I've tested these notebooks I feel like I click "run" multiple times, and in different places, before I end up seeing the result
[12:15:38]<paul121[m]>maybe I need to be more patient/get a better understanding for how this works..
[12:15:56]<paul121[m]>but I see this being an issue! any ideas on how to protect against that?
[12:17:23]<symbioquine[m]>paul121[m]: Create a "UUID mapping file" ahead of time, then write those IDs along with each entry...
[12:18:17]<symbioquine[m]>Such a file could be a JSON file with entries like `{"ALABAMA": "2f087aad-68e2-441b-8484-cb4ce5a3cd45"...}`
[12:18:29]<symbioquine[m]>For the states KML import example that is.
[12:19:27]<symbioquine[m]>Then the importer can catch the HTTP 409 conflict error and skip those.
[12:20:01]<symbioquine[m]>That's how I'd do it.
[12:20:15]<paul121[m]>Ah interesting, 409 error. Cool
[12:20:17]<symbioquine[m]>Obviously, these are just proofs of concept. Everybody's use-cases will differ.
[12:20:46]<symbioquine[m]>In some cases it might make sense to modify the source data to include those UUIDs or use some other value for deduplicating the data.
[12:23:14]<symbioquine[m]>ACTION uploaded an image: (36KiB) < https://libera.ems.host/_matrix/media/r0/download/matrix.org/MlMGSSNJcxf... >
[12:26:13]<symbioquine[m]>ACTION uploaded an image: (12KiB) < https://libera.ems.host/_matrix/media/r0/download/matrix.org/MFhqlbPTkxg... >
[12:27:04]<symbioquine[m]><paul121[m]> "each time I've tested these..." <- I wonder if perhaps the kernel wasn't fully initialized so it just queued up the cell executions?
[12:27:34]<symbioquine[m]>It takes a bit for it to download all the relevant packages and start up.
[12:30:26]<paul121[m]>Yeah that's possible. I think I noticed this more when trying some of the various jupyterlite "lab demo" notebooks - there are some examples each using different graphing/mapping libraries.. probably takes some time to load each of those
[12:42:40]<paul121[m]>hard to link to these in the live environment, but there is an example that pulls in geojson to a leaflet map.. then graphs data associated with each geojson feature.. https://github.com/jupyterlite/jupyterlite/blob/main/examples/pyolite/ip...
[12:43:14]<paul121[m]>seems like pulling in geojson from farmOS is some low-hanging fruit :-)
[12:46:27]<symbioquine[m]>Hmmm, I should test that again... I think I found it needed extensions that weren't included by default in JupyterLite
[12:48:56]<paul121[m]>ah hmm. yeah I'm not sure how they got it configured but it was this "demo" environment: https://jupyterlite.readthedocs.io/en/latest/_static/lab/index.html
[12:50:23]<symbioquine[m]>Cool
[14:36:05]<symbioquine[m]>I guess they're pulling in all this stuff: https://github.com/jupyterlite/jupyterlite/blob/ac6493e5dead6588ae7a16ec...
[15:16:53]<symbioquine[m]>I think the build is orchestrated in [dodo.py](https://github.com/jupyterlite/jupyterlite/blob/ac6493e5dead6588ae7a16ec...) - it might just be me, but I don't find that to be an intuitive workflow declaration pattern/format 😒
[18:04:24]* jonasbits has quit (Ping timeout: 252 seconds)
[18:25:47]* botlfarm[m] has joined #farmos