Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

flatten a "list" does not work for time.struct_time #17

Open
e7dal opened this issue Sep 4, 2018 · 0 comments
Open

flatten a "list" does not work for time.struct_time #17

e7dal opened this issue Sep 4, 2018 · 0 comments

Comments

@e7dal
Copy link
Owner

e7dal commented Sep 4, 2018

in this example from: https://github.com/e7dal/bubble3_clients/tree/master/knmi_warnings

published_parsed should become
published_parsed.1
published_parsed.2
published_parsed.3
etc

introspection of pulled data looks like this:
In [10]: d['published_parsed']
Out[10]: time.struct_time(tm_year=2018, tm_mon=9, tm_mday=4, tm_hour=7, tm_min=6, tm_sec=0, tm_wday=1, tm_yday=247, tm_isdst=0)

jq . remember/pulled_DEV.jsonl
{
"title": "Code geel: Vanmiddag in het midden en zuiden van het land onweersbuien",
"title_detail.type": "text/plain",
"title_detail.language": null,
"title_detail.base": "http://projects.knmi.nl/RSSread/rss_KNMIwaarschuwingen.php",
"title_detail.value": "Code geel: Vanmiddag in het midden en zuiden van het land onweersbuien",
"summary": "

Vanaf halverwege de middag is er in het midden en zuiden van het land kans op onweersbuien met daarbij lokaal veel neerslag in korte tijd.


Uitgifte: 04/09/2018 09:06 uur LT\n

<img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_0_new.gif\" width=300> <img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_1_new.gif\" width=300> <img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_2_new.gif\" width=300>

",
"summary_detail.type": "text/html",
"summary_detail.language": null,
"summary_detail.base": "http://projects.knmi.nl/RSSread/rss_KNMIwaarschuwingen.php",
"summary_detail.value": "

Vanaf halverwege de middag is er in het midden en zuiden van het land kans op onweersbuien met daarbij lokaal veel neerslag in korte tijd.


Uitgifte: 04/09/2018 09:06 uur LT\n

<img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_0_new.gif\" width=300> <img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_1_new.gif\" width=300> <img src="https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_2_new.gif\" width=300>

",
"links.__bts_list": true,
"links.__bts_listlen": 2,
"links.1.type": "image/gif",
"links.1.length": "16907",
"links.1.href": "https://cdn.knmi.nl/knmi/map/current/weather/warning/waarschuwing_land_48_new.gif",
"links.1.rel": "enclosure",
"links.2.rel": "alternate",
"links.2.type": "text/html",
"links.2.href": "https://www.knmi.nl/waarschuwingen",
"link": "https://www.knmi.nl/waarschuwingen",
"id": "https://www.knmi.nl/waarschuwingen?Warnings_Tue%2004%20Sep%202018%2009:06:00%20+0200",
"guidislink": false,
"published": "Tue, 04 Sep 2018 09:06:00 +0200",
"published_parsed": [
2018,
9,
4,
7,
6,
0,
1,
247,
0
],
"tags.__bts_list": true,
"tags.__bts_listlen": 2,
"tags.1.term": "Weather",
"tags.1.scheme": "https://www.knmi.nl",
"tags.1.label": null,
"tags.2.term": "Weer",
"tags.2.scheme": "https://www.knmi.nl",
"tags.2.label": null,
"authors.__bts_list": true,
"authors.__bts_listlen": 1,
"authors.1.name": "Webmaster KNMI",
"authors.1.email": "webmaster@knmi.nl",
"author": "webmaster@knmi.nl (Webmaster KNMI)",
"author_detail.name": "Webmaster KNMI",
"author_detail.email": "webmaster@knmi.nl",
"__bts_flat": true,
"__bts_storetimestamp": "2018-09-04T07:14:47.325507+00:00",
"__bts_fulldata": true
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant