mozetl package¶
Subpackages¶
- mozetl.addon_aggregates package
- mozetl.basic package
- mozetl.clientsdaily package
- mozetl.engagement package
- mozetl.experimentsdaily package
- mozetl.hardware_report package
- mozetl.landfill package
- mozetl.search package
- mozetl.shield package
- mozetl.sync package
- mozetl.taar package
- Submodules
- mozetl.taar.taar_amodump module
- mozetl.taar.taar_amowhitelist module
- mozetl.taar.taar_dynamo module
- mozetl.taar.taar_lite_guidguid module
- mozetl.taar.taar_lite_guidranking module
- mozetl.taar.taar_locale module
- mozetl.taar.taar_similarity module
- mozetl.taar.taar_utils module
- Module contents
- mozetl.testpilot package
- mozetl.topline package
Submodules¶
mozetl.cli module¶
mozetl.constants module¶
mozetl.main module¶
mozetl.schemas module¶
mozetl.utils module¶
-
mozetl.utils.
extract_submission_window_for_activity_day
(frame, date, lag_days)[source]¶ Extract rows with an activity_date of date minus lag_days and a submission_date between activity_date and date (inclusive).
:date ‘Y-m-d’ of the end of the target period :lag_days number of days after date in the target period :frame DataFrame homologous with main_summary
Note that the start_date will be lag-days days before date. In other words, if you pass in 2017-01-20 and set lag-days to 5, the aggregation will be processed for day 2017-01-15 (the resulting data will cover submission dates including the activity day itself plus 5 days of lag for a total of 6 days).
-
mozetl.utils.
send_ses
('me@example.com, 'greetings', "Hi!", 'you@example.com)[source]¶ -
Raises a RuntimeError if the message did not send correctly.
-
mozetl.utils.
stop_session_safely
(spark_session)[source]¶ Safely stops Spark session. This is no-op if running on Databricks - we shouldn’t stop session there since it’s managed by the platform, doing so fails the job.
-
mozetl.utils.
upload_file_to_s3
(client, filepath, bucket, key, ACL='bucket-owner-full-control')[source]¶