Skip to content

Commit 58ebe67

Browse files
committed
black reformatting
1 parent 936e814 commit 58ebe67

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

.github/workflows/write-metrics-md.py

+15-5
Original file line numberDiff line numberDiff line change
@@ -16,11 +16,15 @@ def process_user_data(json_file, top_pages, this_year, map, md_file):
1616
f.write('\n\n')
1717

1818
# Intro description
19-
f.write('This metrics page provides an overview of user activity collected by Google Analytics across the three pillars of Project Pythia: our portal which includes information about the project as well as our resource gallery, our Foundations book, and our Cookbooks gallery. Information is either all-time (from a pre-project start date of March 2020) or year-to-date as indicated and is updated nightly to provide real-time and automated insights into our engagement, impact, and audience reach. If you would like to request a different metrics analysis, timeframe, or view, please [open a GitHub issue](https://github.com/ProjectPythia/projectpythia.github.io/issues/new/choose).\n\n')
19+
f.write(
20+
'This metrics page provides an overview of user activity collected by Google Analytics across the three pillars of Project Pythia: our portal which includes information about the project as well as our resource gallery, our Foundations book, and our Cookbooks gallery. Information is either all-time (from a pre-project start date of March 2020) or year-to-date as indicated and is updated nightly to provide real-time and automated insights into our engagement, impact, and audience reach. If you would like to request a different metrics analysis, timeframe, or view, please [open a GitHub issue](https://github.com/ProjectPythia/projectpythia.github.io/issues/new/choose).\n\n'
21+
)
2022

2123
# Markdown table
2224
f.write('## Table of Total Active Users by Project\n\n')
23-
f.write('This table displays the total active users of our 3 Pythia projects over the life of Project Pythia. Google analytics defines active users as the number of unique people who have visited the site and met certain [engagement requirements](https://support.google.com/analytics/answer/9234069?sjid=8697784525616937194-NC). You can read more from the [GA4 "Understand User Metrics" documentation](https://support.google.com/analytics/answer/12253918?hl=en).\n\n')
25+
f.write(
26+
'This table displays the total active users of our 3 Pythia projects over the life of Project Pythia. Google analytics defines active users as the number of unique people who have visited the site and met certain [engagement requirements](https://support.google.com/analytics/answer/9234069?sjid=8697784525616937194-NC). You can read more from the [GA4 "Understand User Metrics" documentation](https://support.google.com/analytics/answer/12253918?hl=en).\n\n'
27+
)
2428
headers = '| Project | All-Time Users |'
2529
separator = '| ' + ' | '.join(['-----'] * 2) + ' |'
2630
rows = []
@@ -32,15 +36,21 @@ def process_user_data(json_file, top_pages, this_year, map, md_file):
3236

3337
# Add plots
3438
f.write('## Chart of Active Users by Project Since Year Start\n\n')
35-
f.write('This table displays active users for our 3 Pythia projects (Portal in purple, Foundations in blue, and Cookbooks in salmon) since January 1st of the current year. Typically Foundations is our most visited project, but with all 3 displaying a cycle representative of the Monday-Friday work week.\n\n')
39+
f.write(
40+
'This table displays active users for our 3 Pythia projects (Portal in purple, Foundations in blue, and Cookbooks in salmon) since January 1st of the current year. Typically Foundations is our most visited project, but with all 3 displaying a cycle representative of the Monday-Friday work week.\n\n'
41+
)
3642
f.write(f'![Users this Year]({this_year})\n\n')
3743

3844
f.write('## Chart of Top 5 Pages by Project\n\n')
39-
f.write('This table displays the top 5 pages by project over the life of Project Pythia, as determined by screen page views. Screen page views refers to the number of times users viewed a page, including repeated visits. To learn more visit the [GA4 "API Dimensions & Metrics" page](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema).\n\n')
45+
f.write(
46+
'This table displays the top 5 pages by project over the life of Project Pythia, as determined by screen page views. Screen page views refers to the number of times users viewed a page, including repeated visits. To learn more visit the [GA4 "API Dimensions & Metrics" page](https://developers.google.com/analytics/devguides/reporting/data/v1/api-schema).\n\n'
47+
)
4048
f.write(f'![Top Pages]({top_pages})\n\n')
4149

4250
f.write('## Map of Total Foundation Active Users by Country\n\n')
43-
f.write('This map displays the number of active users per country for Pythia Foundations for the entire life of Project Pythia.\n\n')
51+
f.write(
52+
'This map displays the number of active users per country for Pythia Foundations for the entire life of Project Pythia.\n\n'
53+
)
4454
f.write(f'![Users by Country]({map})\n\n')
4555

4656
f.close()

0 commit comments

Comments
 (0)