diff --git a/postgres/program_metadata.json b/postgres/program_metadata.json index ac7c31162..a1971f5d5 100644 --- a/postgres/program_metadata.json +++ b/postgres/program_metadata.json @@ -422,11 +422,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 1, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -447,6 +447,20 @@ "radio": false, "id": "cc4a2d02331449f4198431a47bb31c24150033a6f09d6d2a525ecc8c870654aa" }, + { + "channel_name": "m6", + "start": "13:15", + "end": "13:50", + "weekday": 1, + "program_name": "1245 le mag", + "program_type": "Information - Magazine", + "duration": 35, + "channel_title": "M6", + "public": false, + "infocontinue": false, + "radio": false, + "id": "ab6d5ba4be05d1934a02cce4b2da91af591d927321292941081a52a30ae453bd" + }, { "channel_name": "m6", "start": "19:40", @@ -1304,11 +1318,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 2, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -1329,6 +1343,20 @@ "radio": false, "id": "e991f66c4a3e36501af628429f2e6a510b7ffcfd60058c29d6b4491a3baf7a0c" }, + { + "channel_name": "m6", + "start": "13:15", + "end": "13:50", + "weekday": 2, + "program_name": "1245 le mag", + "program_type": "Information - Magazine", + "duration": 35, + "channel_title": "M6", + "public": false, + "infocontinue": false, + "radio": false, + "id": "37e9c64c2628239dc0aced57f03759cc3c1701a2b9daa02400d199ead8c040e9" + }, { "channel_name": "m6", "start": "19:40", @@ -2186,11 +2214,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 3, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -2211,6 +2239,20 @@ "radio": false, "id": "d5dac14c9c635a22457a33ebddb84ed3df3e81d563a247995b0165292c90501c" }, + { + "channel_name": "m6", + "start": "13:15", + "end": "13:50", + "weekday": 3, + "program_name": "1245 le mag", + "program_type": "Information - Magazine", + "duration": 35, + "channel_title": "M6", + "public": false, + "infocontinue": false, + "radio": false, + "id": "1f2a404b610f6aa9db59773c40884039e73ad3d354b29a72b8e6df2802909c80" + }, { "channel_name": "m6", "start": "19:40", @@ -3082,11 +3124,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 4, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -3107,6 +3149,20 @@ "radio": false, "id": "147698b5152e12caa81bf40b19d5fd6ce09e82b99d0ceffc095b926d87dfd3d8" }, + { + "channel_name": "m6", + "start": "13:15", + "end": "13:50", + "weekday": 4, + "program_name": "1245 le mag", + "program_type": "Information - Magazine", + "duration": 35, + "channel_title": "M6", + "public": false, + "infocontinue": false, + "radio": false, + "id": "3d1e086ec13ae9aa11e73ab4d8151061a8d3781053d172285a42aa222a0ade25" + }, { "channel_name": "m6", "start": "19:40", @@ -3950,11 +4006,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 5, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -3975,6 +4031,20 @@ "radio": false, "id": "a83c43bb126cf5d2a6e5c43fe84ccbd2484161715379d300e8dcf2b316151396" }, + { + "channel_name": "m6", + "start": "13:15", + "end": "13:50", + "weekday": 5, + "program_name": "1245 le mag", + "program_type": "Information - Magazine", + "duration": 35, + "channel_title": "M6", + "public": false, + "infocontinue": false, + "radio": false, + "id": "23ef719dfc4ff89aaec9ab73f948335e9ef90a9591e96408db6e5a52dbeb677a" + }, { "channel_name": "m6", "start": "19:40", @@ -4762,11 +4832,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 6, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, @@ -5490,11 +5560,11 @@ { "channel_name": "m6", "start": "12:45", - "end": "13:35", + "end": "13:15", "weekday": 7, "program_name": "JT 1245", "program_type": "Information - Journal", - "duration": 50, + "duration": 30, "channel_title": "M6", "public": false, "infocontinue": false, diff --git a/quotaclimat/data_processing/mediatree/channel_program.json b/quotaclimat/data_processing/mediatree/channel_program.json index 37dc8850f..62dcc2878 100644 --- a/quotaclimat/data_processing/mediatree/channel_program.json +++ b/quotaclimat/data_processing/mediatree/channel_program.json @@ -20,8 +20,9 @@ {"channel_name":"fr3-idf","start":"7:00","end":"9:00","weekday":"weekday","program_name":"Ici Matin","program_type":"Information - Journal"} {"channel_name":"fr3-idf","start":"12:00","end":"12:50","weekday":"*","program_name":"JT 12h","program_type":"Information - Journal"} {"channel_name":"fr3-idf","start":"19:00","end":"19:55","weekday":"*","program_name":"JT 19h + météo","program_type":"Information - Journal"} -{"channel_name":"m6","start":"12:45","end":"13:35","weekday":"*","program_name":"JT 1245","program_type":"Information - Journal"} +{"channel_name":"m6","start":"12:45","end":"13:15","weekday":"*","program_name":"JT 1245","program_type":"Information - Journal"} {"channel_name":"m6","start":"13:50","end":"17:20","weekday":"weekday","program_name":"1 jour un doc","program_type":"Information - Magazine"} +{"channel_name":"m6","start":"13:15","end":"13:50","weekday":"weekday","program_name":"1245 le mag","program_type":"Information - Magazine"} {"channel_name":"m6","start":"19:40","end":"20:10","weekday":"*","program_name":"JT 1945 + météo","program_type":"Information - Journal"} {"channel_name":"m6","start":"11:00","end":"12:30","weekday":5,"program_name":"66 minutes samedi","program_type":"Information - Magazine"} {"channel_name":"m6","start":"16:35","end":"19:30","weekday":6,"program_name":"66 minutes","program_type":"Information - Magazine"} diff --git a/test/sitemap/test_update_pg_keywords.py b/test/sitemap/test_update_pg_keywords.py index cea0e8bb1..b88eafc59 100644 --- a/test/sitemap/test_update_pg_keywords.py +++ b/test/sitemap/test_update_pg_keywords.py @@ -13,8 +13,8 @@ from test_utils import get_localhost, debug_df, compare_unordered_lists_of_dicts logging.getLogger().setLevel(logging.INFO) -original_timestamp = 1706444334 * 1000 # Sun Jan 28 2024 13:18:54 GMT+0100 -start = pd.to_datetime("2024-01-28 12:18:54", utc=True).tz_convert('Europe/Paris') +original_timestamp = 1706271523 * 1000 # Sun Jan 28 2024 13:18:54 GMT+0100 +start = pd.to_datetime("2024-01-26 12:18:54", utc=True).tz_convert('Europe/Paris') create_tables() def test_delete_keywords(): @@ -197,9 +197,9 @@ def test_first_update_keywords(): ,number_of_biodiversite_solutions_directes = get_themes_keywords_duration(plaintext, srt, start) expected_keywords_with_timestamp = [ - {'category': 'Ecosystème', 'keyword': 'conditions de vie sur terre', 'timestamp': 1706444349000, 'theme': 'changement_climatique_constat'}, - {'category': 'Ecosystème','keyword': 'habitabilité de la planète', 'timestamp': 1706444334006, 'theme': 'changement_climatique_constat'}, - {'category': 'General','keyword': 'digue', 'timestamp': 1706444366000, 'theme': 'adaptation_climatique_solutions'} + {'category': 'Ecosystème', 'keyword': 'conditions de vie sur terre', 'timestamp': original_timestamp + 15000, 'theme': 'changement_climatique_constat'}, + {'category': 'Ecosystème','keyword': 'habitabilité de la planète', 'timestamp': original_timestamp + 6, 'theme': 'changement_climatique_constat'}, + {'category': 'General','keyword': 'digue', 'timestamp': original_timestamp + 32000, 'theme': 'adaptation_climatique_solutions'} ] assert result_after_update.id == result_before_update.id @@ -239,6 +239,6 @@ def test_first_update_keywords(): assert number_of_biodiversite_solutions_directes == 0 # program - assert result_after_update.channel_program == "JT 1245" - assert result_after_update.channel_program_type == "Information - Journal" + assert result_after_update.channel_program == "1245 le mag" + assert result_after_update.channel_program_type == "Information - Magazine"