Skip to content
This repository has been archived by the owner on Nov 21, 2023. It is now read-only.

Deprecation notices #271

Merged
merged 5 commits into from
Nov 6, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 10 additions & 12 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,12 @@ test_settings: &test_settings
command: |
# python-snappy compression relies on C bindings to libsnappy-dev.
# pyspark needs to run Java, so we install openjdk.
apt-get update
apt-get install -y libsnappy-dev openjdk-8-jre-headless
echo "deb [check-valid-until=no] http://cdn-fastly.deb.debian.org/debian jessie main" > /etc/apt/sources.list.d/jessie.list
echo "deb [check-valid-until=no] http://archive.debian.org/debian jessie-backports main" > /etc/apt/sources.list.d/jessie-backports.list
sed -i '/deb http:\/\/deb.debian.org\/debian jessie-updates main/d' /etc/apt/sources.list
apt-get -o Acquire::Check-Valid-Until=false update
apt-get install -t jessie-backports -y libsnappy-dev openjdk-8-jre-headless
/usr/sbin/update-java-alternatives -s java-1.8.0-openjdk-amd64
- run: &run_tox_environment_matching_circleci_job_name
name: Run tox job
command: |
Expand All @@ -51,32 +55,27 @@ test_settings: &test_settings
version: 2
jobs:

py27:
<<: *test_settings
docker:
- image: python:2.7

py35:
<<: *test_settings
docker:
- image: python:3.5
- image: python:3.5-jessie

py36:
<<: *test_settings
docker:
- image: python:3.6
- image: python:3.6-jessie

# We don't actually add this job to the workflow yet due to issues with
# pyspark <= 2.3.1 running on Python 3.7; see:
# https://issues.apache.org/jira/browse/SPARK-24739
py37:
<<: *test_settings
docker:
- image: python:3.7
- image: python:3.7-jessie

docs: &docs_settings
docker:
- image: python:3.6
- image: python:3.6-jessie
steps:
- checkout
- run:
Expand Down Expand Up @@ -158,7 +157,6 @@ workflows:
version: 2
build:
jobs:
- py27
- py35
- py36
- docs
Expand Down
6 changes: 6 additions & 0 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,12 @@
python_moztelemetry
===================

.. warning::
This library will stop working *VERY SOON* (if it hasn't stopped
working already)

Please see `this post <https://mail.mozilla.org/pipermail/fx-data-dev/2019-November/000291.html>`_ to fx-data-dev for more information.

A simple library to fetch and analyze data collected by the Mozilla Telemetry service.
Objects collected by Telemetry are called ``pings``.
A ping has a number of properties (aka ``dimensions``) and a payload.
Expand Down
9 changes: 9 additions & 0 deletions moztelemetry/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
# flake8: noqa
from .spark import *
from .histogram import *


print(
"WARNING: python_moztelemetry will stop working *VERY SOON* "
"(if it hasn't stopped working already)\n"
"Please see this post to fx-data-dev for more "
"information: "
"https://mail.mozilla.org/pipermail/fx-data-dev/2019-November/000291.html"
)
2 changes: 1 addition & 1 deletion moztelemetry/standards.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def snap_to_beginning_of_week(day, weekday_start="Sunday"):
:param weekday_start: Either "Monday" or "Sunday", indicating the first day of the week.
:returns: A date representing the first day of the current week.
"""
delta_days = ((day.weekday() + 1) % 7) if weekday_start is "Sunday" else day.weekday()
delta_days = ((day.weekday() + 1) % 7) if weekday_start == "Sunday" else day.weekday()
return day - timedelta(days=delta_days)


Expand Down