gitlytics 0.1.7__tar.gz → 0.2.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. {gitlytics-0.1.7 → gitlytics-0.2.0}/PKG-INFO +2 -2
  2. {gitlytics-0.1.7 → gitlytics-0.2.0}/README.md +1 -1
  3. {gitlytics-0.1.7 → gitlytics-0.2.0}/pyproject.toml +1 -1
  4. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/__init__.py +1 -1
  5. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/api.py +12 -3
  6. gitlytics-0.2.0/src/gitlytics/static/assets/html2canvas-pro.esm-9xys3ejh.js +6 -0
  7. gitlytics-0.2.0/src/gitlytics/static/assets/html2canvas.esm-DXEQVQnt.js +5 -0
  8. gitlytics-0.2.0/src/gitlytics/static/assets/index-Cx6oOScf.js +87 -0
  9. gitlytics-0.2.0/src/gitlytics/static/assets/index-DxtMptVs.css +1 -0
  10. gitlytics-0.1.7/src/gitlytics/static/assets/index.es-DPqfsOIl.js → gitlytics-0.2.0/src/gitlytics/static/assets/index.es-DZq7ceO3.js +2 -15
  11. gitlytics-0.2.0/src/gitlytics/static/assets/jspdf.es.min-CaU6ZJCD.js +79 -0
  12. gitlytics-0.1.7/src/gitlytics/static/assets/purify.es-Csrj9YNg.js → gitlytics-0.2.0/src/gitlytics/static/assets/purify.es-CC4Brkr_.js +1 -1
  13. gitlytics-0.2.0/src/gitlytics/static/google-search-icon-48x48.png +0 -0
  14. gitlytics-0.2.0/src/gitlytics/static/google-search-icon.png +0 -0
  15. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/index.html +6 -6
  16. gitlytics-0.2.0/src/gitlytics/static/robots.txt +5 -0
  17. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/sitemap.xml +5 -0
  18. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/PKG-INFO +2 -2
  19. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/SOURCES.txt +9 -8
  20. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_api.py +15 -0
  21. gitlytics-0.1.7/src/gitlytics/static/assets/html2canvas-pro.esm-C9_j7xg5.js +0 -10
  22. gitlytics-0.1.7/src/gitlytics/static/assets/html2canvas.esm-QH1iLAAe.js +0 -22
  23. gitlytics-0.1.7/src/gitlytics/static/assets/index-Aazi2GN9.css +0 -1
  24. gitlytics-0.1.7/src/gitlytics/static/assets/index-DC2yfovd.js +0 -504
  25. gitlytics-0.1.7/src/gitlytics/static/assets/jspdf.es.min-Ck4Jy8d6.js +0 -170
  26. gitlytics-0.1.7/src/gitlytics/static/octocat.png +0 -0
  27. gitlytics-0.1.7/src/gitlytics/static/robots.txt +0 -5
  28. {gitlytics-0.1.7 → gitlytics-0.2.0}/LICENSE +0 -0
  29. {gitlytics-0.1.7 → gitlytics-0.2.0}/setup.cfg +0 -0
  30. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/__main__.py +0 -0
  31. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/automation.py +0 -0
  32. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/cli.py +0 -0
  33. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/core.py +0 -0
  34. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/process.py +0 -0
  35. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/android-chrome-192x192.png +0 -0
  36. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/android-chrome-512x512.png +0 -0
  37. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/apple-touch-icon.png +0 -0
  38. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/favicon-16x16.png +0 -0
  39. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/favicon-32x32.png +0 -0
  40. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/favicon-48x48.png +0 -0
  41. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/favicon.ico +0 -0
  42. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics/static/gitlytics-logo.png +0 -0
  43. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/dependency_links.txt +0 -0
  44. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/entry_points.txt +0 -0
  45. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/requires.txt +0 -0
  46. {gitlytics-0.1.7 → gitlytics-0.2.0}/src/gitlytics.egg-info/top_level.txt +0 -0
  47. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_automation.py +0 -0
  48. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_cli.py +0 -0
  49. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_core.py +0 -0
  50. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_process.py +0 -0
  51. {gitlytics-0.1.7 → gitlytics-0.2.0}/tests/test_username.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gitlytics
3
- Version: 0.1.7
3
+ Version: 0.2.0
4
4
  Summary: Monitor and automate your GitHub repository traffic analytics.
5
5
  Author-email: Ameya Chopade <ameyaccod171@gmail.com>
6
6
  License: Apache-2.0
@@ -96,7 +96,7 @@ Dynamic: license-file
96
96
 
97
97
  The full Gitlytics ecosystem spans across a few repositories. If you are looking for the live web dashboard or the automation cron job, check out the links below:
98
98
 
99
- - **[Gitlytics Web Ecosystem](https://github.com/ameyac11/gitlytics-deployement)**: The production landing page, React Dashboard, and React Documentation site.
99
+ - 📊 **[Gitlytics Live Dashboard](https://dashboard.gitlytics.dev)**: The production web interface to visualize repository traffic analytics, trends, and historical charts.
100
100
  - ⚙️ **[Gitlytics Automation](https://github.com/ameyac11/gitlytics-github-traffic-automation)**: The GitHub Action companion tool that automates fetching and saving to defeat GitHub's 14-day traffic limit.
101
101
 
102
102
  ---
@@ -64,7 +64,7 @@
64
64
 
65
65
  The full Gitlytics ecosystem spans across a few repositories. If you are looking for the live web dashboard or the automation cron job, check out the links below:
66
66
 
67
- - **[Gitlytics Web Ecosystem](https://github.com/ameyac11/gitlytics-deployement)**: The production landing page, React Dashboard, and React Documentation site.
67
+ - 📊 **[Gitlytics Live Dashboard](https://dashboard.gitlytics.dev)**: The production web interface to visualize repository traffic analytics, trends, and historical charts.
68
68
  - ⚙️ **[Gitlytics Automation](https://github.com/ameyac11/gitlytics-github-traffic-automation)**: The GitHub Action companion tool that automates fetching and saving to defeat GitHub's 14-day traffic limit.
69
69
 
70
70
  ---
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "gitlytics"
7
- version = "0.1.7"
7
+ version = "0.2.0"
8
8
  description = "Monitor and automate your GitHub repository traffic analytics."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
@@ -8,7 +8,7 @@ import json
8
8
 
9
9
  # Single source of truth for the package version.
10
10
  # Mirrors the version in pyproject.toml — keep them in sync.
11
- __version__ = "0.1.7"
11
+ __version__ = "0.2.0"
12
12
 
13
13
  __all__ = ["fetch_traffic", "sync", "serve_dashboard", "__version__"]
14
14
 
@@ -187,8 +187,17 @@ def get_traffic(token: str = Body("", embed=True)):
187
187
 
188
188
  @app.post("/api/upload-csv")
189
189
  def upload_csv(file: UploadFile = File(...)):
190
- # Accept a user-uploaded CSV — deep stats not available in CSV mode
191
190
  try:
191
+ data_dir = os.environ.get("GITLYTICS_DATA_DIR")
192
+ if data_dir:
193
+ data_dir_path = Path(data_dir)
194
+ data_dir_path.mkdir(parents=True, exist_ok=True)
195
+ file.file.seek(0)
196
+ content = file.file.read()
197
+ file.file.seek(0)
198
+ dest = data_dir_path / f"traffic_uploaded_{int(_time.time())}.csv"
199
+ with open(dest, "wb") as f:
200
+ f.write(content)
192
201
  df = process_uploaded_csv(file.file)
193
202
  df = df.replace([float('inf'), float('-inf')], None).where(pd.notnull(df), None)
194
203
  payload = build_react_payload(df, deep_stats=None)
@@ -208,7 +217,7 @@ def serve_index():
208
217
  return FileResponse(index_file)
209
218
  return JSONResponse(
210
219
  status_code=503,
211
- content={"error": "Dashboard not found. Run 'npm run build' in the dashboard directory."}
220
+ content={"error": "Dashboard assets not found in the package installation."}
212
221
  )
213
222
 
214
223
 
@@ -225,7 +234,7 @@ def serve_spa_fallback(full_path: str):
225
234
 
226
235
  return JSONResponse(
227
236
  status_code=503,
228
- content={"error": "Dashboard not found. Run 'npm run build' in the dashboard directory."}
237
+ content={"error": "Dashboard assets not found in the package installation."}
229
238
  )
230
239
 
231
240