From aaff3fbfbe04245808b1c94222cb6dce3c983444 Mon Sep 17 00:00:00 2001 From: Tyler Burton Date: Fri, 19 Jul 2024 12:24:09 -0500 Subject: [PATCH 1/5] adds metrics workflow --- .github/workflows/build-metrics-report.yml | 20 +- .gitignore | 4 + metrics/.env | 1 + metrics/.vscode/launch.json | 22 + metrics/Makefile | 12 + metrics/README.md | 11 + metrics/datagov_metrics/__init__.py | 0 metrics/datagov_metrics/__main__.py | 4 + metrics/datagov_metrics/ckan.py | 45 ++ metrics/datagov_metrics/ga.py | 228 ++++++++ metrics/datagov_metrics/s3_util.py | 26 + metrics/poetry.lock | 602 +++++++++++++++++++++ metrics/pyproject.toml | 35 ++ 13 files changed, 1005 insertions(+), 5 deletions(-) create mode 100644 metrics/.env create mode 100644 metrics/.vscode/launch.json create mode 100644 metrics/Makefile create mode 100644 metrics/README.md create mode 100644 metrics/datagov_metrics/__init__.py create mode 100644 metrics/datagov_metrics/__main__.py create mode 100644 metrics/datagov_metrics/ckan.py create mode 100644 metrics/datagov_metrics/ga.py create mode 100644 metrics/datagov_metrics/s3_util.py create mode 100644 metrics/poetry.lock create mode 100644 metrics/pyproject.toml diff --git a/.github/workflows/build-metrics-report.yml b/.github/workflows/build-metrics-report.yml index 847ddcb75..6822f3670 100644 --- a/.github/workflows/build-metrics-report.yml +++ b/.github/workflows/build-metrics-report.yml @@ -13,10 +13,7 @@ jobs: fetch-report: defaults: run: - working-directory: metrics - env: - AWS_ACCESS_KEY_ID: ${{secrets.AWS_ACCESS_KEY_ID_METRICS}} - AWS_SECRET_ACCESS_KEY: ${{secrets.AWS_SECRET_ACCESS_KEY_METRICS}} + working-directory: metrics runs-on: ubuntu-latest name: Fetch Reports steps: @@ -34,6 +31,16 @@ jobs: with: poetry-version: ${{ env.POETRY_VERSION }} + - name: Setup a local virtual environment (if no poetry.toml file) + run: | + poetry config virtualenvs.create true --local + poetry config virtualenvs.in-project true --local + - uses: actions/cache@v3 + name: Define a cache for the virtual environment based on the dependencies lock file + with: + path: ./.venv + key: venv-${{ hashFiles('poetry.lock') }} + - name: Install Dependencies run: | poetry env use ${{ env.PY_VERSION }} @@ -43,7 +50,10 @@ jobs: env: GA_CREDENTIALS_JSON: ${{ secrets.GA_CREDENTIALS_JSON }} run: | - echo $GA_CREDENTIALS_JSON | base64 --decode > datagov_metrics/credentials.json + echo $GA_CREDENTIALS_JSON | base64 --decode > datagov_metrics/credentials.json - name: Run Python script + env: + AWS_ACCESS_KEY_ID_METRICS: ${{ secrets.AWS_ACCESS_KEY_ID_METRICS }} + AWS_SECRET_ACCESS_KEY_METRICS: ${{ secrets.AWS_SECRET_ACCESS_KEY_METRICS }} run: | poetry run python datagov_metrics \ No newline at end of file diff --git a/.gitignore b/.gitignore index 399346ca9..9d8e2cf9d 100644 --- a/.gitignore +++ b/.gitignore @@ -62,3 +62,7 @@ ansible/roles/vendor .vscode/settings.json output + +## dont ignore +# metrics +!metrics/.env \ No newline at end of file diff --git a/metrics/.env b/metrics/.env new file mode 100644 index 000000000..32ab322eb --- /dev/null +++ b/metrics/.env @@ -0,0 +1 @@ +AWS_S3_BUCKET_METRICS=cg-baa85e06-1bdd-4672-9e3a-36333c05c6ce \ No newline at end of file diff --git a/metrics/.vscode/launch.json b/metrics/.vscode/launch.json new file mode 100644 index 000000000..22af61e4f --- /dev/null +++ b/metrics/.vscode/launch.json @@ -0,0 +1,22 @@ +{ + "version": "0.2.0", + "configurations": [ + { + "name": "Poetry debug", + "type": "debugpy", + "request": "launch", + "pythonPath": "${workspaceFolder}/.venv/bin/python", + "cwd": "${workspaceFolder}", + "module": "datagov_metrics.ga", + "justMyCode": false, + "args": [ + "src.main:app", + "--host", + "0.0.0.0", + "--port", + "8000", + "--reload" + ] + } + ] +} \ No newline at end of file diff --git a/metrics/Makefile b/metrics/Makefile new file mode 100644 index 000000000..5322f91f5 --- /dev/null +++ b/metrics/Makefile @@ -0,0 +1,12 @@ +.DEFAULT_GOAL := help +SHELL := /bin/bash + +.PHONY: py-lint +py-lint: ## Run python linting scanners and black + poetry run ruff check . --fix + +# Output documentation for top-level targets +# Thanks to https://marmelab.com/blog/2016/02/29/auto-documented-makefile.html +.PHONY: help +help: + @awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf "\033[36m%-10s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST) diff --git a/metrics/README.md b/metrics/README.md new file mode 100644 index 000000000..10e5dae7a --- /dev/null +++ b/metrics/README.md @@ -0,0 +1,11 @@ +# datagov-metrics + +A python module to fetch metrics from various sources (GA & CKAN) and push them to S3 + +Reports are then available at the path: + +https://s3-us-gov-west-1.amazonaws.com/cg-baa85e06-1bdd-4672-9e3a-36333c05c6ce/{file_name} + +Ex. +https://s3-us-gov-west-1.amazonaws.com/cg-baa85e06-1bdd-4672-9e3a-36333c05c6ce/global__datasets_per_org.csv + diff --git a/metrics/datagov_metrics/__init__.py b/metrics/datagov_metrics/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/metrics/datagov_metrics/__main__.py b/metrics/datagov_metrics/__main__.py new file mode 100644 index 000000000..d3a217e7c --- /dev/null +++ b/metrics/datagov_metrics/__main__.py @@ -0,0 +1,4 @@ +from datagov_metrics import ckan, ga + +ga.main() +ckan.main() diff --git a/metrics/datagov_metrics/ckan.py b/metrics/datagov_metrics/ckan.py new file mode 100644 index 000000000..10e894f64 --- /dev/null +++ b/metrics/datagov_metrics/ckan.py @@ -0,0 +1,45 @@ +import requests +import csv +import io +from datagov_metrics.s3_util import put_data_to_s3 + +CKAN_BASE_URL = "https://catalog.data.gov/api/action/package_search" +ORG_LIST_API_ROUTE = "/api/action/organization_list" +PACKAGE_SEARCH_API_ROUTE = "/api/action/package_search" +QUERIES = { + "harvest_sources": '?fq=dataset_type:harvest&facet.field=["organization"]&facet.limit=200&rows=0', + "datasets_per_org": '?q=*:*&facet.field=["organization"]&facet.limit=200&rows=0', +} + + +def get_data(): + query_dict = {} + for k, v in QUERIES.items(): + url = f"{CKAN_BASE_URL}{v}" + repo = requests.get(url) + data = repo.json() + + raw_data = data["result"]["facets"]["organization"] + + query_dict[k] = [[k, v] for (k, v) in raw_data.items()] + return query_dict + + +def write_data_to_csv(response): + """Reshape the response CSV.""" + with io.StringIO() as csv_buffer: + writer = csv.writer(csv_buffer, delimiter=",") + writer.writerow(["organization", "count"]) # write header + writer.writerows(response) + return csv_buffer.getvalue() + + +def main(): + data = get_data() + for k, v in data.items(): + csv_data = write_data_to_csv(v) + put_data_to_s3(f"global__{k}.csv", csv_data) + + +if __name__ == "__main__": + main() diff --git a/metrics/datagov_metrics/ga.py b/metrics/datagov_metrics/ga.py new file mode 100644 index 000000000..49bdc26af --- /dev/null +++ b/metrics/datagov_metrics/ga.py @@ -0,0 +1,228 @@ +import datetime +import io +import csv + +from datagov_metrics.s3_util import put_data_to_s3 +import requests +from google.oauth2 import service_account +from googleapiclient.discovery import build + +KEY_FILE_LOCATION = "datagov_metrics/credentials.json" +GA4_PROPERTY_ID = "properties/381392243" + +credentials = service_account.Credentials.from_service_account_file( + KEY_FILE_LOCATION, scopes=["https://www.googleapis.com/auth/analytics.readonly"] +) +analytics = build("analyticsdata", "v1beta", credentials=credentials) +properties = analytics.properties() + + +def date_range(days_ago: int): + today = datetime.date.today().strftime("%Y-%m-%d") + days_ago_strfmt = ( + datetime.date.today() - datetime.timedelta(days=days_ago) + ).strftime("%Y-%m-%d") + return [{"startDate": days_ago_strfmt, "endDate": today}] + + +def get_org_list(): + url = "https://catalog.data.gov/api/action/organization_list" + repo = requests.get(url) + data = repo.json() + + return data["result"] + + +def setup_organization_reports(): + orgs = get_org_list() + org_reports = {} + + for org in orgs: + org_dimension_filter = { + "filter": { + "fieldName": "customEvent:DATAGOV_dataset_organization", + "stringFilter": {"matchType": "CONTAINS", "value": org}, + } + } + + # report most viewd dataset pages per organization + org_reports[f"{org}__page_requests__last30"] = { + "dateRanges": date_range(30), + "dimensions": [ + {"name": "pagePath"}, + {"name": "customEvent:DATAGOV_dataset_organization"}, + {"name": "customEvent:DATAGOV_dataset_publisher"}, + ], + "dimensionFilter": org_dimension_filter, + "metrics": [{"name": "screenPageViews"}], + "orderBys": [{"metric": {"metricName": "screenPageViews"}, "desc": True}], + } + + # report most downloaded files per organization + org_reports[f"{org}__download_requests__last30"] = { + "dateRanges": date_range(30), + "dimensions": [ + {"name": "linkUrl"}, + {"name": "customEvent:DATAGOV_dataset_organization"}, + {"name": "customEvent:DATAGOV_dataset_publisher"}, + {"name": "fileExtension"}, + {"name": "fileName"}, + ], + "dimensionFilter": { + "andGroup": { + "expressions": [ + { + "filter": { + "fieldName": "eventName", + "stringFilter": { + "matchType": "EXACT", + "value": "file_download", + }, + } + }, + org_dimension_filter, + ], + }, + }, + "metrics": [{"name": "eventCount"}], + "orderBys": [{"metric": {"metricName": "eventCount"}, "desc": True}], + } + + # report most clicked outboud links per organization + org_reports[f"{org}__link_requests__last30"] = { + "dateRanges": date_range(30), + "dimensions": [ + {"name": "linkUrl"}, + {"name": "customEvent:DATAGOV_dataset_organization"}, + {"name": "customEvent:DATAGOV_dataset_publisher"}, + {"name": "outbound"}, + ], + "dimensionFilter": { + "andGroup": { + "expressions": [ + { + "filter": { + "fieldName": "outbound", + "stringFilter": {"matchType": "EXACT", "value": "true"}, + } + }, + org_dimension_filter, + ], + }, + }, + "metrics": [{"name": "eventCount"}], + "orderBys": [{"metric": {"metricName": "eventCount"}, "desc": True}], + } + + return org_reports + + +def setup_global_reports(): + global_reports = {} + + global_reports["global__page_requests__last30"] = { + "dateRanges": date_range(30), + "dimensions": [{"name": "pagePath"}], + # TODO add filter to clean up pages? + # "dimensionFilter": {}, + "metrics": [{"name": "screenPageViews"}], + "orderBys": [{"metric": {"metricName": "screenPageViews"}, "desc": True}], + } + + global_reports["global__total_pageviews__last30"] = { + "dateRanges": date_range(30), + "metrics": [{"name": "screenPageViews"}], + } + + global_reports["global__top_search_terms__last30"] = { + "dateRanges": date_range(30), + "dimensions": [{"name": "searchTerm"}], + "dimensionFilter": { + "andGroup": { + "expressions": [ + { + "notExpression": { + "filter": { + "fieldName": "searchTerm", + "stringFilter": {"matchType": "EXACT", "value": ""}, + } + } + }, + { + "notExpression": { + "filter": { + "fieldName": "searchTerm", + "stringFilter": { + "matchType": "EXACT", + "value": "Search datasets...", + }, + } + } + }, + ] + } + }, + "metrics": [{"name": "eventCount"}], + "orderBys": [{"metric": {"metricName": "eventCount"}, "desc": True}], + } + + global_reports["global__device_category__last30"] = { + "dateRanges": date_range(30), + "dimensions": [{"name": "deviceCategory"}], + "metrics": [{"name": "activeUsers"}], + "orderBys": [{"metric": {"metricName": "activeUsers"}, "desc": True}], + } + + return global_reports + + +def setup_reports(): + reports = {} + reports.update(setup_global_reports()) + reports.update(setup_organization_reports()) + + return reports + + +def fetch_report(request): + response = properties.runReport(property=GA4_PROPERTY_ID, body=request).execute() + return response + + +def write_data_to_csv(response): + """Reshape the response CSV.""" + with io.StringIO() as csv_buffer: + writer = csv.writer(csv_buffer, delimiter=",") + writer.writerow( + [ + *[val["name"] for val in response.get("dimensionHeaders") or []], + *[val["name"] for val in response["metricHeaders"]], + ] + ) # write header + if response.get("rows"): + writer.writerows( + [ + *[ + [val["value"] for val in row.get("dimensionValues") or []] + for row in response["rows"] + ], + *[ + [val["value"] for val in row["metricValues"]] + for row in response["rows"] + ], + ] + ) + return csv_buffer.getvalue() + + +def main(): + reports = setup_reports() + for report in reports: + print(f"Fetching report: {report}") + fetched_report = fetch_report(reports[report]) + csv_data = write_data_to_csv(fetched_report) + put_data_to_s3(f"{report}.csv", csv_data) + + +if __name__ == "__main__": + main() diff --git a/metrics/datagov_metrics/s3_util.py b/metrics/datagov_metrics/s3_util.py new file mode 100644 index 000000000..c75ad4680 --- /dev/null +++ b/metrics/datagov_metrics/s3_util.py @@ -0,0 +1,26 @@ +import os +import boto3 +from dotenv import load_dotenv + +load_dotenv() + +AWS_S3_BUCKET = os.getenv("AWS_S3_BUCKET_METRICS") +AWS_ACCESS_KEY_ID = os.getenv("AWS_ACCESS_KEY_ID_METRICS") +AWS_SECRET_ACCESS_KEY = os.getenv("AWS_SECRET_ACCESS_KEY_METRICS") + +s3_client = boto3.client( + "s3", + aws_access_key_id=AWS_ACCESS_KEY_ID, + aws_secret_access_key=AWS_SECRET_ACCESS_KEY, +) + + +def put_data_to_s3(file_name, csv_data): + response = s3_client.put_object(Bucket=AWS_S3_BUCKET, Key=file_name, Body=csv_data) + + status = response.get("ResponseMetadata", {}).get("HTTPStatusCode") + + if status == 200: + print(f"Successful S3 put_object {file_name} response. Status - {status}") + else: + print(f"Unsuccessful S3 put_object {file_name} response. Status - {status}") diff --git a/metrics/poetry.lock b/metrics/poetry.lock new file mode 100644 index 000000000..b1f48dbc9 --- /dev/null +++ b/metrics/poetry.lock @@ -0,0 +1,602 @@ +# This file is automatically @generated by Poetry 1.8.3 and should not be changed by hand. + +[[package]] +name = "apiclient" +version = "1.0.4" +description = "Framework for making good API client libraries using urllib3." +optional = false +python-versions = "*" +files = [ + {file = "apiclient-1.0.4.tar.gz", hash = "sha256:2569c998191cd1a042beffa3cf7c1119277237b4ba1fa021d20c81fa98fa95e9"}, +] + +[package.dependencies] +certifi = "*" +urllib3 = "*" + +[[package]] +name = "boto3" +version = "1.34.144" +description = "The AWS SDK for Python" +optional = false +python-versions = ">=3.8" +files = [ + {file = "boto3-1.34.144-py3-none-any.whl", hash = "sha256:b8433d481d50b68a0162c0379c0dd4aabfc3d1ad901800beb5b87815997511c1"}, + {file = "boto3-1.34.144.tar.gz", hash = "sha256:2f3e88b10b8fcc5f6100a9d74cd28230edc9d4fa226d99dd40a3ab38ac213673"}, +] + +[package.dependencies] +botocore = ">=1.34.144,<1.35.0" +jmespath = ">=0.7.1,<2.0.0" +s3transfer = ">=0.10.0,<0.11.0" + +[package.extras] +crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] + +[[package]] +name = "botocore" +version = "1.34.144" +description = "Low-level, data-driven core of boto 3." +optional = false +python-versions = ">=3.8" +files = [ + {file = "botocore-1.34.144-py3-none-any.whl", hash = "sha256:a2cf26e1bf10d5917a2285e50257bc44e94a1d16574f282f3274f7a5d8d1f08b"}, + {file = "botocore-1.34.144.tar.gz", hash = "sha256:4215db28d25309d59c99507f1f77df9089e5bebbad35f6e19c7c44ec5383a3e8"}, +] + +[package.dependencies] +jmespath = ">=0.7.1,<2.0.0" +python-dateutil = ">=2.1,<3.0.0" +urllib3 = {version = ">=1.25.4,<2.2.0 || >2.2.0,<3", markers = "python_version >= \"3.10\""} + +[package.extras] +crt = ["awscrt (==0.20.11)"] + +[[package]] +name = "cachetools" +version = "5.4.0" +description = "Extensible memoizing collections and decorators" +optional = false +python-versions = ">=3.7" +files = [ + {file = "cachetools-5.4.0-py3-none-any.whl", hash = "sha256:3ae3b49a3d5e28a77a0be2b37dbcb89005058959cb2323858c2657c4a8cab474"}, + {file = "cachetools-5.4.0.tar.gz", hash = "sha256:b8adc2e7c07f105ced7bc56dbb6dfbe7c4a00acce20e2227b3f355be89bc6827"}, +] + +[[package]] +name = "certifi" +version = "2024.7.4" +description = "Python package for providing Mozilla's CA Bundle." +optional = false +python-versions = ">=3.6" +files = [ + {file = "certifi-2024.7.4-py3-none-any.whl", hash = "sha256:c198e21b1289c2ab85ee4e67bb4b4ef3ead0892059901a8d5b622f24a1101e90"}, + {file = "certifi-2024.7.4.tar.gz", hash = "sha256:5a1e7645bc0ec61a09e26c36f6106dd4cf40c6db3a1fb6352b0244e7fb057c7b"}, +] + +[[package]] +name = "charset-normalizer" +version = "3.3.2" +description = "The Real First Universal Charset Detector. Open, modern and actively maintained alternative to Chardet." +optional = false +python-versions = ">=3.7.0" +files = [ + {file = "charset-normalizer-3.3.2.tar.gz", hash = "sha256:f30c3cb33b24454a82faecaf01b19c18562b1e89558fb6c56de4d9118a032fd5"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:25baf083bf6f6b341f4121c2f3c548875ee6f5339300e08be3f2b2ba1721cdd3"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:06435b539f889b1f6f4ac1758871aae42dc3a8c0e24ac9e60c2384973ad73027"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:9063e24fdb1e498ab71cb7419e24622516c4a04476b17a2dab57e8baa30d6e03"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:6897af51655e3691ff853668779c7bad41579facacf5fd7253b0133308cf000d"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1d3193f4a680c64b4b6a9115943538edb896edc190f0b222e73761716519268e"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:cd70574b12bb8a4d2aaa0094515df2463cb429d8536cfb6c7ce983246983e5a6"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:8465322196c8b4d7ab6d1e049e4c5cb460d0394da4a27d23cc242fbf0034b6b5"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:a9a8e9031d613fd2009c182b69c7b2c1ef8239a0efb1df3f7c8da66d5dd3d537"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:beb58fe5cdb101e3a055192ac291b7a21e3b7ef4f67fa1d74e331a7f2124341c"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-musllinux_1_1_i686.whl", hash = "sha256:e06ed3eb3218bc64786f7db41917d4e686cc4856944f53d5bdf83a6884432e12"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-musllinux_1_1_ppc64le.whl", hash = "sha256:2e81c7b9c8979ce92ed306c249d46894776a909505d8f5a4ba55b14206e3222f"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-musllinux_1_1_s390x.whl", hash = "sha256:572c3763a264ba47b3cf708a44ce965d98555f618ca42c926a9c1616d8f34269"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:fd1abc0d89e30cc4e02e4064dc67fcc51bd941eb395c502aac3ec19fab46b519"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-win32.whl", hash = "sha256:3d47fa203a7bd9c5b6cee4736ee84ca03b8ef23193c0d1ca99b5089f72645c73"}, + {file = "charset_normalizer-3.3.2-cp310-cp310-win_amd64.whl", hash = "sha256:10955842570876604d404661fbccbc9c7e684caf432c09c715ec38fbae45ae09"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-macosx_10_9_universal2.whl", hash = "sha256:802fe99cca7457642125a8a88a084cef28ff0cf9407060f7b93dca5aa25480db"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:573f6eac48f4769d667c4442081b1794f52919e7edada77495aaed9236d13a96"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:549a3a73da901d5bc3ce8d24e0600d1fa85524c10287f6004fbab87672bf3e1e"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:f27273b60488abe721a075bcca6d7f3964f9f6f067c8c4c605743023d7d3944f"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:1ceae2f17a9c33cb48e3263960dc5fc8005351ee19db217e9b1bb15d28c02574"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:65f6f63034100ead094b8744b3b97965785388f308a64cf8d7c34f2f2e5be0c4"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:753f10e867343b4511128c6ed8c82f7bec3bd026875576dfd88483c5c73b2fd8"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:4a78b2b446bd7c934f5dcedc588903fb2f5eec172f3d29e52a9096a43722adfc"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:e537484df0d8f426ce2afb2d0f8e1c3d0b114b83f8850e5f2fbea0e797bd82ae"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-musllinux_1_1_i686.whl", hash = "sha256:eb6904c354526e758fda7167b33005998fb68c46fbc10e013ca97f21ca5c8887"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-musllinux_1_1_ppc64le.whl", hash = "sha256:deb6be0ac38ece9ba87dea880e438f25ca3eddfac8b002a2ec3d9183a454e8ae"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-musllinux_1_1_s390x.whl", hash = "sha256:4ab2fe47fae9e0f9dee8c04187ce5d09f48eabe611be8259444906793ab7cbce"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:80402cd6ee291dcb72644d6eac93785fe2c8b9cb30893c1af5b8fdd753b9d40f"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-win32.whl", hash = "sha256:7cd13a2e3ddeed6913a65e66e94b51d80a041145a026c27e6bb76c31a853c6ab"}, + {file = "charset_normalizer-3.3.2-cp311-cp311-win_amd64.whl", hash = "sha256:663946639d296df6a2bb2aa51b60a2454ca1cb29835324c640dafb5ff2131a77"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-macosx_10_9_universal2.whl", hash = "sha256:0b2b64d2bb6d3fb9112bafa732def486049e63de9618b5843bcdd081d8144cd8"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:ddbb2551d7e0102e7252db79ba445cdab71b26640817ab1e3e3648dad515003b"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:55086ee1064215781fff39a1af09518bc9255b50d6333f2e4c74ca09fac6a8f6"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:8f4a014bc36d3c57402e2977dada34f9c12300af536839dc38c0beab8878f38a"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a10af20b82360ab00827f916a6058451b723b4e65030c5a18577c8b2de5b3389"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:8d756e44e94489e49571086ef83b2bb8ce311e730092d2c34ca8f7d925cb20aa"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:90d558489962fd4918143277a773316e56c72da56ec7aa3dc3dbbe20fdfed15b"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:6ac7ffc7ad6d040517be39eb591cac5ff87416c2537df6ba3cba3bae290c0fed"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:7ed9e526742851e8d5cc9e6cf41427dfc6068d4f5a3bb03659444b4cabf6bc26"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_i686.whl", hash = "sha256:8bdb58ff7ba23002a4c5808d608e4e6c687175724f54a5dade5fa8c67b604e4d"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_ppc64le.whl", hash = "sha256:6b3251890fff30ee142c44144871185dbe13b11bab478a88887a639655be1068"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_s390x.whl", hash = "sha256:b4a23f61ce87adf89be746c8a8974fe1c823c891d8f86eb218bb957c924bb143"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:efcb3f6676480691518c177e3b465bcddf57cea040302f9f4e6e191af91174d4"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-win32.whl", hash = "sha256:d965bba47ddeec8cd560687584e88cf699fd28f192ceb452d1d7ee807c5597b7"}, + {file = "charset_normalizer-3.3.2-cp312-cp312-win_amd64.whl", hash = "sha256:96b02a3dc4381e5494fad39be677abcb5e6634bf7b4fa83a6dd3112607547001"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-macosx_10_9_x86_64.whl", hash = "sha256:95f2a5796329323b8f0512e09dbb7a1860c46a39da62ecb2324f116fa8fdc85c"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:c002b4ffc0be611f0d9da932eb0f704fe2602a9a949d1f738e4c34c75b0863d5"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a981a536974bbc7a512cf44ed14938cf01030a99e9b3a06dd59578882f06f985"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:3287761bc4ee9e33561a7e058c72ac0938c4f57fe49a09eae428fd88aafe7bb6"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:42cb296636fcc8b0644486d15c12376cb9fa75443e00fb25de0b8602e64c1714"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:0a55554a2fa0d408816b3b5cedf0045f4b8e1a6065aec45849de2d6f3f8e9786"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-musllinux_1_1_aarch64.whl", hash = "sha256:c083af607d2515612056a31f0a8d9e0fcb5876b7bfc0abad3ecd275bc4ebc2d5"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-musllinux_1_1_i686.whl", hash = "sha256:87d1351268731db79e0f8e745d92493ee2841c974128ef629dc518b937d9194c"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-musllinux_1_1_ppc64le.whl", hash = "sha256:bd8f7df7d12c2db9fab40bdd87a7c09b1530128315d047a086fa3ae3435cb3a8"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-musllinux_1_1_s390x.whl", hash = "sha256:c180f51afb394e165eafe4ac2936a14bee3eb10debc9d9e4db8958fe36afe711"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-musllinux_1_1_x86_64.whl", hash = "sha256:8c622a5fe39a48f78944a87d4fb8a53ee07344641b0562c540d840748571b811"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-win32.whl", hash = "sha256:db364eca23f876da6f9e16c9da0df51aa4f104a972735574842618b8c6d999d4"}, + {file = "charset_normalizer-3.3.2-cp37-cp37m-win_amd64.whl", hash = "sha256:86216b5cee4b06df986d214f664305142d9c76df9b6512be2738aa72a2048f99"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-macosx_10_9_universal2.whl", hash = "sha256:6463effa3186ea09411d50efc7d85360b38d5f09b870c48e4600f63af490e56a"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-macosx_10_9_x86_64.whl", hash = "sha256:6c4caeef8fa63d06bd437cd4bdcf3ffefe6738fb1b25951440d80dc7df8c03ac"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-macosx_11_0_arm64.whl", hash = "sha256:37e55c8e51c236f95b033f6fb391d7d7970ba5fe7ff453dad675e88cf303377a"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:fb69256e180cb6c8a894fee62b3afebae785babc1ee98b81cdf68bbca1987f33"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:ae5f4161f18c61806f411a13b0310bea87f987c7d2ecdbdaad0e94eb2e404238"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:b2b0a0c0517616b6869869f8c581d4eb2dd83a4d79e0ebcb7d373ef9956aeb0a"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:45485e01ff4d3630ec0d9617310448a8702f70e9c01906b0d0118bdf9d124cf2"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:eb00ed941194665c332bf8e078baf037d6c35d7c4f3102ea2d4f16ca94a26dc8"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-musllinux_1_1_aarch64.whl", hash = "sha256:2127566c664442652f024c837091890cb1942c30937add288223dc895793f898"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-musllinux_1_1_i686.whl", hash = "sha256:a50aebfa173e157099939b17f18600f72f84eed3049e743b68ad15bd69b6bf99"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-musllinux_1_1_ppc64le.whl", hash = "sha256:4d0d1650369165a14e14e1e47b372cfcb31d6ab44e6e33cb2d4e57265290044d"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-musllinux_1_1_s390x.whl", hash = "sha256:923c0c831b7cfcb071580d3f46c4baf50f174be571576556269530f4bbd79d04"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-musllinux_1_1_x86_64.whl", hash = "sha256:06a81e93cd441c56a9b65d8e1d043daeb97a3d0856d177d5c90ba85acb3db087"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-win32.whl", hash = "sha256:6ef1d82a3af9d3eecdba2321dc1b3c238245d890843e040e41e470ffa64c3e25"}, + {file = "charset_normalizer-3.3.2-cp38-cp38-win_amd64.whl", hash = "sha256:eb8821e09e916165e160797a6c17edda0679379a4be5c716c260e836e122f54b"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-macosx_10_9_universal2.whl", hash = "sha256:c235ebd9baae02f1b77bcea61bce332cb4331dc3617d254df3323aa01ab47bd4"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:5b4c145409bef602a690e7cfad0a15a55c13320ff7a3ad7ca59c13bb8ba4d45d"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:68d1f8a9e9e37c1223b656399be5d6b448dea850bed7d0f87a8311f1ff3dabb0"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:22afcb9f253dac0696b5a4be4a1c0f8762f8239e21b99680099abd9b2b1b2269"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:e27ad930a842b4c5eb8ac0016b0a54f5aebbe679340c26101df33424142c143c"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:1f79682fbe303db92bc2b1136016a38a42e835d932bab5b3b1bfcfbf0640e519"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:b261ccdec7821281dade748d088bb6e9b69e6d15b30652b74cbbac25e280b796"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-manylinux_2_5_i686.manylinux1_i686.manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:122c7fa62b130ed55f8f285bfd56d5f4b4a5b503609d181f9ad85e55c89f4185"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:d0eccceffcb53201b5bfebb52600a5fb483a20b61da9dbc885f8b103cbe7598c"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-musllinux_1_1_i686.whl", hash = "sha256:9f96df6923e21816da7e0ad3fd47dd8f94b2a5ce594e00677c0013018b813458"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-musllinux_1_1_ppc64le.whl", hash = "sha256:7f04c839ed0b6b98b1a7501a002144b76c18fb1c1850c8b98d458ac269e26ed2"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-musllinux_1_1_s390x.whl", hash = "sha256:34d1c8da1e78d2e001f363791c98a272bb734000fcef47a491c1e3b0505657a8"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:ff8fa367d09b717b2a17a052544193ad76cd49979c805768879cb63d9ca50561"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-win32.whl", hash = "sha256:aed38f6e4fb3f5d6bf81bfa990a07806be9d83cf7bacef998ab1a9bd660a581f"}, + {file = "charset_normalizer-3.3.2-cp39-cp39-win_amd64.whl", hash = "sha256:b01b88d45a6fcb69667cd6d2f7a9aeb4bf53760d7fc536bf679ec94fe9f3ff3d"}, + {file = "charset_normalizer-3.3.2-py3-none-any.whl", hash = "sha256:3e4d1f6587322d2788836a99c69062fbb091331ec940e02d12d179c1d53e25fc"}, +] + +[[package]] +name = "google-api-core" +version = "2.19.1" +description = "Google API client core library" +optional = false +python-versions = ">=3.7" +files = [ + {file = "google-api-core-2.19.1.tar.gz", hash = "sha256:f4695f1e3650b316a795108a76a1c416e6afb036199d1c1f1f110916df479ffd"}, + {file = "google_api_core-2.19.1-py3-none-any.whl", hash = "sha256:f12a9b8309b5e21d92483bbd47ce2c445861ec7d269ef6784ecc0ea8c1fa6125"}, +] + +[package.dependencies] +google-auth = ">=2.14.1,<3.0.dev0" +googleapis-common-protos = ">=1.56.2,<2.0.dev0" +proto-plus = ">=1.22.3,<2.0.0dev" +protobuf = ">=3.19.5,<3.20.0 || >3.20.0,<3.20.1 || >3.20.1,<4.21.0 || >4.21.0,<4.21.1 || >4.21.1,<4.21.2 || >4.21.2,<4.21.3 || >4.21.3,<4.21.4 || >4.21.4,<4.21.5 || >4.21.5,<6.0.0.dev0" +requests = ">=2.18.0,<3.0.0.dev0" + +[package.extras] +grpc = ["grpcio (>=1.33.2,<2.0dev)", "grpcio (>=1.49.1,<2.0dev)", "grpcio-status (>=1.33.2,<2.0.dev0)", "grpcio-status (>=1.49.1,<2.0.dev0)"] +grpcgcp = ["grpcio-gcp (>=0.2.2,<1.0.dev0)"] +grpcio-gcp = ["grpcio-gcp (>=0.2.2,<1.0.dev0)"] + +[[package]] +name = "google-api-python-client" +version = "2.137.0" +description = "Google API Client Library for Python" +optional = false +python-versions = ">=3.7" +files = [ + {file = "google_api_python_client-2.137.0-py2.py3-none-any.whl", hash = "sha256:a8b5c5724885e5be9f5368739aa0ccf416627da4ebd914b410a090c18f84d692"}, + {file = "google_api_python_client-2.137.0.tar.gz", hash = "sha256:e739cb74aac8258b1886cb853b0722d47c81fe07ad649d7f2206f06530513c04"}, +] + +[package.dependencies] +google-api-core = ">=1.31.5,<2.0.dev0 || >2.3.0,<3.0.0.dev0" +google-auth = ">=1.32.0,<2.24.0 || >2.24.0,<2.25.0 || >2.25.0,<3.0.0.dev0" +google-auth-httplib2 = ">=0.2.0,<1.0.0" +httplib2 = ">=0.19.0,<1.dev0" +uritemplate = ">=3.0.1,<5" + +[[package]] +name = "google-auth" +version = "2.32.0" +description = "Google Authentication Library" +optional = false +python-versions = ">=3.7" +files = [ + {file = "google_auth-2.32.0-py2.py3-none-any.whl", hash = "sha256:53326ea2ebec768070a94bee4e1b9194c9646ea0c2bd72422785bd0f9abfad7b"}, + {file = "google_auth-2.32.0.tar.gz", hash = "sha256:49315be72c55a6a37d62819e3573f6b416aca00721f7e3e31a008d928bf64022"}, +] + +[package.dependencies] +cachetools = ">=2.0.0,<6.0" +pyasn1-modules = ">=0.2.1" +rsa = ">=3.1.4,<5" + +[package.extras] +aiohttp = ["aiohttp (>=3.6.2,<4.0.0.dev0)", "requests (>=2.20.0,<3.0.0.dev0)"] +enterprise-cert = ["cryptography (==36.0.2)", "pyopenssl (==22.0.0)"] +pyopenssl = ["cryptography (>=38.0.3)", "pyopenssl (>=20.0.0)"] +reauth = ["pyu2f (>=0.1.5)"] +requests = ["requests (>=2.20.0,<3.0.0.dev0)"] + +[[package]] +name = "google-auth-httplib2" +version = "0.2.0" +description = "Google Authentication Library: httplib2 transport" +optional = false +python-versions = "*" +files = [ + {file = "google-auth-httplib2-0.2.0.tar.gz", hash = "sha256:38aa7badf48f974f1eb9861794e9c0cb2a0511a4ec0679b1f886d108f5640e05"}, + {file = "google_auth_httplib2-0.2.0-py2.py3-none-any.whl", hash = "sha256:b65a0a2123300dd71281a7bf6e64d65a0759287df52729bdd1ae2e47dc311a3d"}, +] + +[package.dependencies] +google-auth = "*" +httplib2 = ">=0.19.0" + +[[package]] +name = "google-auth-oauthlib" +version = "1.2.1" +description = "Google Authentication Library" +optional = false +python-versions = ">=3.6" +files = [ + {file = "google_auth_oauthlib-1.2.1-py2.py3-none-any.whl", hash = "sha256:2d58a27262d55aa1b87678c3ba7142a080098cbc2024f903c62355deb235d91f"}, + {file = "google_auth_oauthlib-1.2.1.tar.gz", hash = "sha256:afd0cad092a2eaa53cd8e8298557d6de1034c6cb4a740500b5357b648af97263"}, +] + +[package.dependencies] +google-auth = ">=2.15.0" +requests-oauthlib = ">=0.7.0" + +[package.extras] +tool = ["click (>=6.0.0)"] + +[[package]] +name = "googleapis-common-protos" +version = "1.63.2" +description = "Common protobufs used in Google APIs" +optional = false +python-versions = ">=3.7" +files = [ + {file = "googleapis-common-protos-1.63.2.tar.gz", hash = "sha256:27c5abdffc4911f28101e635de1533fb4cfd2c37fbaa9174587c799fac90aa87"}, + {file = "googleapis_common_protos-1.63.2-py2.py3-none-any.whl", hash = "sha256:27a2499c7e8aff199665b22741997e485eccc8645aa9176c7c988e6fae507945"}, +] + +[package.dependencies] +protobuf = ">=3.20.2,<4.21.1 || >4.21.1,<4.21.2 || >4.21.2,<4.21.3 || >4.21.3,<4.21.4 || >4.21.4,<4.21.5 || >4.21.5,<6.0.0.dev0" + +[package.extras] +grpc = ["grpcio (>=1.44.0,<2.0.0.dev0)"] + +[[package]] +name = "httplib2" +version = "0.22.0" +description = "A comprehensive HTTP client library." +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" +files = [ + {file = "httplib2-0.22.0-py3-none-any.whl", hash = "sha256:14ae0a53c1ba8f3d37e9e27cf37eabb0fb9980f435ba405d546948b009dd64dc"}, + {file = "httplib2-0.22.0.tar.gz", hash = "sha256:d7a10bc5ef5ab08322488bde8c726eeee5c8618723fdb399597ec58f3d82df81"}, +] + +[package.dependencies] +pyparsing = {version = ">=2.4.2,<3.0.0 || >3.0.0,<3.0.1 || >3.0.1,<3.0.2 || >3.0.2,<3.0.3 || >3.0.3,<4", markers = "python_version > \"3.0\""} + +[[package]] +name = "idna" +version = "3.7" +description = "Internationalized Domain Names in Applications (IDNA)" +optional = false +python-versions = ">=3.5" +files = [ + {file = "idna-3.7-py3-none-any.whl", hash = "sha256:82fee1fc78add43492d3a1898bfa6d8a904cc97d8427f683ed8e798d07761aa0"}, + {file = "idna-3.7.tar.gz", hash = "sha256:028ff3aadf0609c1fd278d8ea3089299412a7a8b9bd005dd08b9f8285bcb5cfc"}, +] + +[[package]] +name = "jmespath" +version = "1.0.1" +description = "JSON Matching Expressions" +optional = false +python-versions = ">=3.7" +files = [ + {file = "jmespath-1.0.1-py3-none-any.whl", hash = "sha256:02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980"}, + {file = "jmespath-1.0.1.tar.gz", hash = "sha256:90261b206d6defd58fdd5e85f478bf633a2901798906be2ad389150c5c60edbe"}, +] + +[[package]] +name = "oauth2client" +version = "4.1.3" +description = "OAuth 2.0 client library" +optional = false +python-versions = "*" +files = [ + {file = "oauth2client-4.1.3-py2.py3-none-any.whl", hash = "sha256:b8a81cc5d60e2d364f0b1b98f958dbd472887acaf1a5b05e21c28c31a2d6d3ac"}, + {file = "oauth2client-4.1.3.tar.gz", hash = "sha256:d486741e451287f69568a4d26d70d9acd73a2bbfa275746c535b4209891cccc6"}, +] + +[package.dependencies] +httplib2 = ">=0.9.1" +pyasn1 = ">=0.1.7" +pyasn1-modules = ">=0.0.5" +rsa = ">=3.1.4" +six = ">=1.6.1" + +[[package]] +name = "oauthlib" +version = "3.2.2" +description = "A generic, spec-compliant, thorough implementation of the OAuth request-signing logic" +optional = false +python-versions = ">=3.6" +files = [ + {file = "oauthlib-3.2.2-py3-none-any.whl", hash = "sha256:8139f29aac13e25d502680e9e19963e83f16838d48a0d71c287fe40e7067fbca"}, + {file = "oauthlib-3.2.2.tar.gz", hash = "sha256:9859c40929662bec5d64f34d01c99e093149682a3f38915dc0655d5a633dd918"}, +] + +[package.extras] +rsa = ["cryptography (>=3.0.0)"] +signals = ["blinker (>=1.4.0)"] +signedtoken = ["cryptography (>=3.0.0)", "pyjwt (>=2.0.0,<3)"] + +[[package]] +name = "proto-plus" +version = "1.24.0" +description = "Beautiful, Pythonic protocol buffers." +optional = false +python-versions = ">=3.7" +files = [ + {file = "proto-plus-1.24.0.tar.gz", hash = "sha256:30b72a5ecafe4406b0d339db35b56c4059064e69227b8c3bda7462397f966445"}, + {file = "proto_plus-1.24.0-py3-none-any.whl", hash = "sha256:402576830425e5f6ce4c2a6702400ac79897dab0b4343821aa5188b0fab81a12"}, +] + +[package.dependencies] +protobuf = ">=3.19.0,<6.0.0dev" + +[package.extras] +testing = ["google-api-core (>=1.31.5)"] + +[[package]] +name = "protobuf" +version = "5.27.2" +description = "" +optional = false +python-versions = ">=3.8" +files = [ + {file = "protobuf-5.27.2-cp310-abi3-win32.whl", hash = "sha256:354d84fac2b0d76062e9b3221f4abbbacdfd2a4d8af36bab0474f3a0bb30ab38"}, + {file = "protobuf-5.27.2-cp310-abi3-win_amd64.whl", hash = "sha256:0e341109c609749d501986b835f667c6e1e24531096cff9d34ae411595e26505"}, + {file = "protobuf-5.27.2-cp38-abi3-macosx_10_9_universal2.whl", hash = "sha256:a109916aaac42bff84702fb5187f3edadbc7c97fc2c99c5ff81dd15dcce0d1e5"}, + {file = "protobuf-5.27.2-cp38-abi3-manylinux2014_aarch64.whl", hash = "sha256:176c12b1f1c880bf7a76d9f7c75822b6a2bc3db2d28baa4d300e8ce4cde7409b"}, + {file = "protobuf-5.27.2-cp38-abi3-manylinux2014_x86_64.whl", hash = "sha256:b848dbe1d57ed7c191dfc4ea64b8b004a3f9ece4bf4d0d80a367b76df20bf36e"}, + {file = "protobuf-5.27.2-cp38-cp38-win32.whl", hash = "sha256:4fadd8d83e1992eed0248bc50a4a6361dc31bcccc84388c54c86e530b7f58863"}, + {file = "protobuf-5.27.2-cp38-cp38-win_amd64.whl", hash = "sha256:610e700f02469c4a997e58e328cac6f305f649826853813177e6290416e846c6"}, + {file = "protobuf-5.27.2-cp39-cp39-win32.whl", hash = "sha256:9e8f199bf7f97bd7ecebffcae45ebf9527603549b2b562df0fbc6d4d688f14ca"}, + {file = "protobuf-5.27.2-cp39-cp39-win_amd64.whl", hash = "sha256:7fc3add9e6003e026da5fc9e59b131b8f22b428b991ccd53e2af8071687b4fce"}, + {file = "protobuf-5.27.2-py3-none-any.whl", hash = "sha256:54330f07e4949d09614707c48b06d1a22f8ffb5763c159efd5c0928326a91470"}, + {file = "protobuf-5.27.2.tar.gz", hash = "sha256:f3ecdef226b9af856075f28227ff2c90ce3a594d092c39bee5513573f25e2714"}, +] + +[[package]] +name = "pyasn1" +version = "0.6.0" +description = "Pure-Python implementation of ASN.1 types and DER/BER/CER codecs (X.208)" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pyasn1-0.6.0-py2.py3-none-any.whl", hash = "sha256:cca4bb0f2df5504f02f6f8a775b6e416ff9b0b3b16f7ee80b5a3153d9b804473"}, + {file = "pyasn1-0.6.0.tar.gz", hash = "sha256:3a35ab2c4b5ef98e17dfdec8ab074046fbda76e281c5a706ccd82328cfc8f64c"}, +] + +[[package]] +name = "pyasn1-modules" +version = "0.4.0" +description = "A collection of ASN.1-based protocols modules" +optional = false +python-versions = ">=3.8" +files = [ + {file = "pyasn1_modules-0.4.0-py3-none-any.whl", hash = "sha256:be04f15b66c206eed667e0bb5ab27e2b1855ea54a842e5037738099e8ca4ae0b"}, + {file = "pyasn1_modules-0.4.0.tar.gz", hash = "sha256:831dbcea1b177b28c9baddf4c6d1013c24c3accd14a1873fffaa6a2e905f17b6"}, +] + +[package.dependencies] +pyasn1 = ">=0.4.6,<0.7.0" + +[[package]] +name = "pyparsing" +version = "3.1.2" +description = "pyparsing module - Classes and methods to define and execute parsing grammars" +optional = false +python-versions = ">=3.6.8" +files = [ + {file = "pyparsing-3.1.2-py3-none-any.whl", hash = "sha256:f9db75911801ed778fe61bb643079ff86601aca99fcae6345aa67292038fb742"}, + {file = "pyparsing-3.1.2.tar.gz", hash = "sha256:a1bac0ce561155ecc3ed78ca94d3c9378656ad4c94c1270de543f621420f94ad"}, +] + +[package.extras] +diagrams = ["jinja2", "railroad-diagrams"] + +[[package]] +name = "python-dateutil" +version = "2.9.0.post0" +description = "Extensions to the standard Python datetime module" +optional = false +python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" +files = [ + {file = "python-dateutil-2.9.0.post0.tar.gz", hash = "sha256:37dd54208da7e1cd875388217d5e00ebd4179249f90fb72437e91a35459a0ad3"}, + {file = "python_dateutil-2.9.0.post0-py2.py3-none-any.whl", hash = "sha256:a8b2bc7bffae282281c8140a97d3aa9c14da0b136dfe83f850eea9a5f7470427"}, +] + +[package.dependencies] +six = ">=1.5" + +[[package]] +name = "python-dotenv" +version = "1.0.1" +description = "Read key-value pairs from a .env file and set them as environment variables" +optional = false +python-versions = ">=3.8" +files = [ + {file = "python-dotenv-1.0.1.tar.gz", hash = "sha256:e324ee90a023d808f1959c46bcbc04446a10ced277783dc6ee09987c37ec10ca"}, + {file = "python_dotenv-1.0.1-py3-none-any.whl", hash = "sha256:f7b63ef50f1b690dddf550d03497b66d609393b40b564ed0d674909a68ebf16a"}, +] + +[package.extras] +cli = ["click (>=5.0)"] + +[[package]] +name = "requests" +version = "2.32.3" +description = "Python HTTP for Humans." +optional = false +python-versions = ">=3.8" +files = [ + {file = "requests-2.32.3-py3-none-any.whl", hash = "sha256:70761cfe03c773ceb22aa2f671b4757976145175cdfca038c02654d061d6dcc6"}, + {file = "requests-2.32.3.tar.gz", hash = "sha256:55365417734eb18255590a9ff9eb97e9e1da868d4ccd6402399eaf68af20a760"}, +] + +[package.dependencies] +certifi = ">=2017.4.17" +charset-normalizer = ">=2,<4" +idna = ">=2.5,<4" +urllib3 = ">=1.21.1,<3" + +[package.extras] +socks = ["PySocks (>=1.5.6,!=1.5.7)"] +use-chardet-on-py3 = ["chardet (>=3.0.2,<6)"] + +[[package]] +name = "requests-oauthlib" +version = "2.0.0" +description = "OAuthlib authentication support for Requests." +optional = false +python-versions = ">=3.4" +files = [ + {file = "requests-oauthlib-2.0.0.tar.gz", hash = "sha256:b3dffaebd884d8cd778494369603a9e7b58d29111bf6b41bdc2dcd87203af4e9"}, + {file = "requests_oauthlib-2.0.0-py2.py3-none-any.whl", hash = "sha256:7dd8a5c40426b779b0868c404bdef9768deccf22749cde15852df527e6269b36"}, +] + +[package.dependencies] +oauthlib = ">=3.0.0" +requests = ">=2.0.0" + +[package.extras] +rsa = ["oauthlib[signedtoken] (>=3.0.0)"] + +[[package]] +name = "rsa" +version = "4.2" +description = "Pure-Python RSA implementation" +optional = false +python-versions = "*" +files = [ + {file = "rsa-4.2.tar.gz", hash = "sha256:aaefa4b84752e3e99bd8333a2e1e3e7a7da64614042bd66f775573424370108a"}, +] + +[package.dependencies] +pyasn1 = ">=0.1.3" + +[[package]] +name = "ruff" +version = "0.5.3" +description = "An extremely fast Python linter and code formatter, written in Rust." +optional = false +python-versions = ">=3.7" +files = [ + {file = "ruff-0.5.3-py3-none-linux_armv6l.whl", hash = "sha256:b12424d9db7347fa63c5ed9af010003338c63c629fb9c9c6adb2aa4f5699729b"}, + {file = "ruff-0.5.3-py3-none-macosx_10_12_x86_64.whl", hash = "sha256:b8d72c5684bbd4ed304a9a955ee2e67f57b35f6193222ade910cca8a805490e3"}, + {file = "ruff-0.5.3-py3-none-macosx_11_0_arm64.whl", hash = "sha256:d2fc2cdb85ccac1e816cc9d5d8cedefd93661bd957756d902543af32a6b04a71"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:cf4bc751240b2fab5d19254571bcacb315c7b0b00bf3c912d52226a82bbec073"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl", hash = "sha256:bc697ec874fdd7c7ba0a85ec76ab38f8595224868d67f097c5ffc21136e72fcd"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl", hash = "sha256:e791d34d3557a3819b3704bc1f087293c821083fa206812842fa363f6018a192"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl", hash = "sha256:76bb5a87fd397520b91a83eae8a2f7985236d42dd9459f09eef58e7f5c1d8316"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl", hash = "sha256:a8cfc7a26422c78e94f1ec78ec02501bbad2df5834907e75afe474cc6b83a8c1"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl", hash = "sha256:96066c4328a49fce2dd40e80f7117987369feec30ab771516cf95f1cc2db923c"}, + {file = "ruff-0.5.3-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:03bfe9ab5bdc0b08470c3b261643ad54ea86edc32b64d1e080892d7953add3ad"}, + {file = "ruff-0.5.3-py3-none-musllinux_1_2_aarch64.whl", hash = "sha256:7704582a026fa02cca83efd76671a98ee6eb412c4230209efe5e2a006c06db62"}, + {file = "ruff-0.5.3-py3-none-musllinux_1_2_armv7l.whl", hash = "sha256:08058d077e21b856d32ebf483443390e29dc44d927608dc8f092ff6776519da9"}, + {file = "ruff-0.5.3-py3-none-musllinux_1_2_i686.whl", hash = "sha256:77d49484429ed7c7e6e2e75a753f153b7b58f875bdb4158ad85af166a1ec1822"}, + {file = "ruff-0.5.3-py3-none-musllinux_1_2_x86_64.whl", hash = "sha256:642cbff6cbfa38d2566d8db086508d6f472edb136cbfcc4ea65997745368c29e"}, + {file = "ruff-0.5.3-py3-none-win32.whl", hash = "sha256:eafc45dd8bdc37a00b28e68cc038daf3ca8c233d73fea276dcd09defb1352841"}, + {file = "ruff-0.5.3-py3-none-win_amd64.whl", hash = "sha256:cbaec2ddf4f78e5e9ecf5456ea0f496991358a1d883862ed0b9e947e2b6aea93"}, + {file = "ruff-0.5.3-py3-none-win_arm64.whl", hash = "sha256:05fbd2cb404775d6cd7f2ff49504e2d20e13ef95fa203bd1ab22413af70d420b"}, + {file = "ruff-0.5.3.tar.gz", hash = "sha256:2a3eb4f1841771fa5b67a56be9c2d16fd3cc88e378bd86aaeaec2f7e6bcdd0a2"}, +] + +[[package]] +name = "s3transfer" +version = "0.10.2" +description = "An Amazon S3 Transfer Manager" +optional = false +python-versions = ">=3.8" +files = [ + {file = "s3transfer-0.10.2-py3-none-any.whl", hash = "sha256:eca1c20de70a39daee580aef4986996620f365c4e0fda6a86100231d62f1bf69"}, + {file = "s3transfer-0.10.2.tar.gz", hash = "sha256:0711534e9356d3cc692fdde846b4a1e4b0cb6519971860796e6bc4c7aea00ef6"}, +] + +[package.dependencies] +botocore = ">=1.33.2,<2.0a.0" + +[package.extras] +crt = ["botocore[crt] (>=1.33.2,<2.0a.0)"] + +[[package]] +name = "six" +version = "1.16.0" +description = "Python 2 and 3 compatibility utilities" +optional = false +python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" +files = [ + {file = "six-1.16.0-py2.py3-none-any.whl", hash = "sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254"}, + {file = "six-1.16.0.tar.gz", hash = "sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926"}, +] + +[[package]] +name = "uritemplate" +version = "4.1.1" +description = "Implementation of RFC 6570 URI Templates" +optional = false +python-versions = ">=3.6" +files = [ + {file = "uritemplate-4.1.1-py2.py3-none-any.whl", hash = "sha256:830c08b8d99bdd312ea4ead05994a38e8936266f84b9a7878232db50b044e02e"}, + {file = "uritemplate-4.1.1.tar.gz", hash = "sha256:4346edfc5c3b79f694bccd6d6099a322bbeb628dbf2cd86eea55a456ce5124f0"}, +] + +[[package]] +name = "urllib3" +version = "2.2.2" +description = "HTTP library with thread-safe connection pooling, file post, and more." +optional = false +python-versions = ">=3.8" +files = [ + {file = "urllib3-2.2.2-py3-none-any.whl", hash = "sha256:a448b2f64d686155468037e1ace9f2d2199776e17f0a46610480d311f73e3472"}, + {file = "urllib3-2.2.2.tar.gz", hash = "sha256:dd505485549a7a552833da5e6063639d0d177c04f23bc3864e41e5dc5f612168"}, +] + +[package.extras] +brotli = ["brotli (>=1.0.9)", "brotlicffi (>=0.8.0)"] +h2 = ["h2 (>=4,<5)"] +socks = ["pysocks (>=1.5.6,!=1.5.7,<2.0)"] +zstd = ["zstandard (>=0.18.0)"] + +[metadata] +lock-version = "2.0" +python-versions = ">=3.10" +content-hash = "cd89bc8eb533d8c7bc74d4058c32d84d88d2c9c95b46b684ce3e9ed446dfc46f" diff --git a/metrics/pyproject.toml b/metrics/pyproject.toml new file mode 100644 index 000000000..3f086d48c --- /dev/null +++ b/metrics/pyproject.toml @@ -0,0 +1,35 @@ +[tool.poetry] +name = "datagov-metrics" +version = "0.1.0" +description = "" +authors = [ + "Datagov Team ", +] +maintainers = [ + "Datagov Team ", +] +readme = "README.md" +packages = [{include = "datagov_metrics"}] + +[tool.poetry.dependencies] +python = ">=3.10" +google-api-python-client = "^2.129.0" +google-auth = "^2.29.0" +google-auth-oauthlib = "^1.2.0" +google-auth-httplib2 = "^0.2.0" +apiclient = "^1.0.4" +oauth2client = "^4.1.3" +requests = "^2.32.3" +python-dotenv = "^1.0.1" +boto3 = "^1.34.144" + + +[tool.poetry.group.dev.dependencies] +ruff = "^0.5.3" + +[tool.ruff] +line-length = 88 + +[build-system] +requires = ["poetry-core"] +build-backend = "poetry.core.masonry.api" \ No newline at end of file From 33a70a1668e82ad8de22b49bd6183e90d9a29486 Mon Sep 17 00:00:00 2001 From: Tyler Burton Date: Mon, 22 Jul 2024 12:28:17 -0500 Subject: [PATCH 2/5] fix list comprehension in ga metrics and add default region --- .github/workflows/build-metrics-report.yml | 3 ++- metrics/datagov_metrics/ga.py | 11 +++-------- 2 files changed, 5 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build-metrics-report.yml b/.github/workflows/build-metrics-report.yml index 6822f3670..8393fcf80 100644 --- a/.github/workflows/build-metrics-report.yml +++ b/.github/workflows/build-metrics-report.yml @@ -35,7 +35,7 @@ jobs: run: | poetry config virtualenvs.create true --local poetry config virtualenvs.in-project true --local - - uses: actions/cache@v3 + - uses: actions/cache@v4 name: Define a cache for the virtual environment based on the dependencies lock file with: path: ./.venv @@ -55,5 +55,6 @@ jobs: env: AWS_ACCESS_KEY_ID_METRICS: ${{ secrets.AWS_ACCESS_KEY_ID_METRICS }} AWS_SECRET_ACCESS_KEY_METRICS: ${{ secrets.AWS_SECRET_ACCESS_KEY_METRICS }} + AWS_DEFAULT_REGION: us-gov-west-1 run: | poetry run python datagov_metrics \ No newline at end of file diff --git a/metrics/datagov_metrics/ga.py b/metrics/datagov_metrics/ga.py index 49bdc26af..c06002228 100644 --- a/metrics/datagov_metrics/ga.py +++ b/metrics/datagov_metrics/ga.py @@ -202,15 +202,10 @@ def write_data_to_csv(response): if response.get("rows"): writer.writerows( [ - *[ - [val["value"] for val in row.get("dimensionValues") or []] - for row in response["rows"] - ], - *[ - [val["value"] for val in row["metricValues"]] - for row in response["rows"] - ], + *[val["value"] for val in row.get("dimensionValues") or []], + *[val["value"] for val in row["metricValues"]], ] + for row in response["rows"] ) return csv_buffer.getvalue() From 4486c071af8bd8676db9149b4a4ddfef3fac8718 Mon Sep 17 00:00:00 2001 From: Tyler Burton Date: Mon, 22 Jul 2024 17:26:17 -0500 Subject: [PATCH 3/5] add metrics build badge to README --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index a24d6ad70..10b12ccc9 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ | egress actions | [![disable egress proxy](https://github.com/GSA/data.gov/actions/workflows/disable-egress.yml/badge.svg)](https://github.com/GSA/data.gov/actions/workflows/disable-egress.yml) [![enable egress proxy](https://github.com/GSA/data.gov/actions/workflows/enable-egress.yml/badge.svg)](https://github.com/GSA/data.gov/actions/workflows/enable-egress.yml) [![restart egress proxy](https://github.com/GSA/data.gov/actions/workflows/restart-egress.yml/badge.svg)](https://github.com/GSA/data.gov/actions/workflows/restart-egress.yml) | | [ssb egress actions](https://github.com/GSA/datagov-ssb) | [![disable egress proxy](https://github.com/GSA/datagov-ssb/actions/workflows/disable-egress.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/disable-egress.yml) [![enable egress proxy](https://github.com/GSA/datagov-ssb/actions/workflows/enable-egress.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/enable-egress.yml) [![restart egress proxy](https://github.com/GSA/datagov-ssb/actions/workflows/restart-egress.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/restart-egress.yml) | | | | -| [data.gov](https://github.com/GSA/datagov-11ty) | [![Build & Test](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml/badge.svg)](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml) | +| [data.gov](https://github.com/GSA/datagov-11ty) | [![Build & Test](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml/badge.svg)](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml)[![Catalog Metrics](https://github.com/GSA/data.gov/actions/workflows/build-metrics-report.yml/badge.svg)](https://github.com/GSA/data.gov/actions/workflows/build-metrics-report.yml) | | [www-redirects](https://github.com/GSA/datagov-website) | [![deploy](https://github.com/GSA/datagov-website/actions/workflows/deploy.yml/badge.svg)](https://github.com/GSA/datagov-website/actions/workflows/deploy.yml) | | [datagov-ssb](https://github.com/GSA/datagov-ssb) | [![commit](https://github.com/GSA/datagov-ssb/actions/workflows/commit.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/commit.yml) [![plan](https://github.com/GSA/datagov-ssb/actions/workflows/plan.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/plan.yml) [![apply](https://github.com/GSA/datagov-ssb/actions/workflows/apply.yml/badge.svg)](https://github.com/GSA/datagov-ssb/actions/workflows/apply.yml) | | [resources.data.gov](https://github.com/GSA/resources.data.gov/) | [![Build & Test](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml/badge.svg)](https://github.com/GSA/datagov-11ty/actions/workflows/build.yml) [![QA](https://github.com/GSA/resources.data.gov/actions/workflows/qa.yml/badge.svg)](https://github.com/GSA/resources.data.gov/actions/workflows/qa.yml) | From d76c2c62d92cb4794a248b4b21ea6f0f3059d63f Mon Sep 17 00:00:00 2001 From: Tyler Burton Date: Mon, 22 Jul 2024 17:31:52 -0500 Subject: [PATCH 4/5] test improve cache command --- .github/workflows/build-metrics-report.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/build-metrics-report.yml b/.github/workflows/build-metrics-report.yml index 8393fcf80..f20bb4b00 100644 --- a/.github/workflows/build-metrics-report.yml +++ b/.github/workflows/build-metrics-report.yml @@ -39,7 +39,7 @@ jobs: name: Define a cache for the virtual environment based on the dependencies lock file with: path: ./.venv - key: venv-${{ hashFiles('poetry.lock') }} + key: venv-${{ runner.os }}-${{ hashFiles('**/poetry.lock') }} - name: Install Dependencies run: | From 5c2a68594695b6b209b038220bee0fc0c90f61ef Mon Sep 17 00:00:00 2001 From: Tyler Burton Date: Tue, 23 Jul 2024 12:03:31 -0500 Subject: [PATCH 5/5] remove unnecessary routes --- metrics/datagov_metrics/ckan.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/metrics/datagov_metrics/ckan.py b/metrics/datagov_metrics/ckan.py index 10e894f64..6ddf82b2c 100644 --- a/metrics/datagov_metrics/ckan.py +++ b/metrics/datagov_metrics/ckan.py @@ -4,8 +4,6 @@ from datagov_metrics.s3_util import put_data_to_s3 CKAN_BASE_URL = "https://catalog.data.gov/api/action/package_search" -ORG_LIST_API_ROUTE = "/api/action/organization_list" -PACKAGE_SEARCH_API_ROUTE = "/api/action/package_search" QUERIES = { "harvest_sources": '?fq=dataset_type:harvest&facet.field=["organization"]&facet.limit=200&rows=0', "datasets_per_org": '?q=*:*&facet.field=["organization"]&facet.limit=200&rows=0',