studylife-cli 1.9.72__tar.gz → 1.9.74__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.
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/PKG-INFO +5 -1
- studylife_cli-1.9.74/PRIVACY.md +35 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/README.md +4 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/_version.py +2 -2
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/cli.py +4 -4
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/client.py +1 -1
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/login.py +1 -1
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/models.py +1 -1
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/ISSUE_TEMPLATE/bug_report.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/ISSUE_TEMPLATE/config.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/ISSUE_TEMPLATE/feature_request.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/PULL_REQUEST_TEMPLATE.md +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/dependabot.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/lktec-bot.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/workflows/ci.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/workflows/dependabot-auto-merge.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/workflows/dependabot-lockfiles.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/workflows/dependency-review.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.github/workflows/scorecard.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/.gitignore +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/CHANGELOG.md +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/CODE_OF_CONDUCT.md +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/CONTRIBUTING.md +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/LICENSE +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/SECURITY.md +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/fuzz/fuzz_models_and_callback.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/pyproject.toml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/socket.yml +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/__init__.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/credentials.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/src/studylife_cli/tui.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/tests/test_cli.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/tests/test_client.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/tests/test_login.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/tests/test_tui.py +0 -0
- {studylife_cli-1.9.72 → studylife_cli-1.9.74}/uv.lock +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: studylife-cli
|
|
3
|
-
Version: 1.9.
|
|
3
|
+
Version: 1.9.74
|
|
4
4
|
Summary: Command-line client for StudyAtrium (self-hosted study organizer) - notes, sessions, course goals, and webhooks from your terminal.
|
|
5
5
|
License-File: LICENSE
|
|
6
6
|
Requires-Python: >=3.12
|
|
@@ -116,6 +116,10 @@ uv run ruff check .
|
|
|
116
116
|
uv run ruff format --check .
|
|
117
117
|
```
|
|
118
118
|
|
|
119
|
+
## Privacy
|
|
120
|
+
|
|
121
|
+
See [PRIVACY.md](PRIVACY.md) for what the CLI stores and where data goes.
|
|
122
|
+
|
|
119
123
|
## License
|
|
120
124
|
|
|
121
125
|
AGPL-3.0
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Privacy
|
|
2
|
+
|
|
3
|
+
StudyAtrium CLI is a command line tool and terminal UI that runs on your own computer. The
|
|
4
|
+
maintainers of this repository operate no server and receive no data from it. Statements
|
|
5
|
+
below are based on the code in `src/studylife_cli`.
|
|
6
|
+
|
|
7
|
+
## What is stored
|
|
8
|
+
|
|
9
|
+
- **Credentials** in `~/.config/studylife-cli/credentials.json` (or under `XDG_CONFIG_HOME`):
|
|
10
|
+
the instance URL, the client id and the API key StudyAtrium issued to the CLI when you ran
|
|
11
|
+
`studylife login`. The file is plain text, restricted to your user on POSIX systems (not on
|
|
12
|
+
Windows). The key is limited to the scopes you granted when registering the CLI.
|
|
13
|
+
- **Exports** you create with `studylife export` are written as JSON or Markdown files to the
|
|
14
|
+
directory you name. They contain your study data in clear text; protect or delete them
|
|
15
|
+
yourself.
|
|
16
|
+
|
|
17
|
+
The CLI keeps no other files: no cache, no history, no logs and no telemetry.
|
|
18
|
+
|
|
19
|
+
## Where data goes
|
|
20
|
+
|
|
21
|
+
Requests go only to the StudyAtrium instance you logged in to, over the URL you entered, with
|
|
22
|
+
your API key. The browser opens for the login approval on that same instance. Nothing is sent
|
|
23
|
+
to the maintainers or any third party.
|
|
24
|
+
|
|
25
|
+
## Retention and deletion
|
|
26
|
+
|
|
27
|
+
`studylife logout` deletes the local credentials file. It does not revoke the key on the
|
|
28
|
+
server: revoke it in StudyAtrium (account settings) to make a copied key unusable. Deleting
|
|
29
|
+
your StudyAtrium account revokes it too. The CLI stores nothing on any server, so there is no
|
|
30
|
+
purge endpoint. Export files stay until you delete them.
|
|
31
|
+
|
|
32
|
+
## Contact
|
|
33
|
+
|
|
34
|
+
Requests about your StudyAtrium data go to the operator of your StudyAtrium instance. Security
|
|
35
|
+
issues: see [SECURITY.md](SECURITY.md).
|
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '1.9.
|
|
22
|
-
__version_tuple__ = version_tuple = (1, 9,
|
|
21
|
+
__version__ = version = '1.9.74'
|
|
22
|
+
__version_tuple__ = version_tuple = (1, 9, 74)
|
|
23
23
|
|
|
24
24
|
__commit_id__ = commit_id = None
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"""`studylife` - command-line client for a self-hosted
|
|
1
|
+
"""`studylife` - command-line client for a self-hosted StudyAtrium instance."""
|
|
2
2
|
|
|
3
3
|
from __future__ import annotations
|
|
4
4
|
|
|
@@ -31,11 +31,11 @@ app.add_typer(courses_app, name="courses")
|
|
|
31
31
|
app.add_typer(programs_app, name="programs")
|
|
32
32
|
app.add_typer(webhooks_app, name="webhooks")
|
|
33
33
|
|
|
34
|
-
#
|
|
34
|
+
# StudyAtrium content (course icons, note text) is arbitrary Unicode, but Python's stdout/stderr
|
|
35
35
|
# on Windows default to the console's legacy OEM/ANSI codepage (e.g. cp1252) unless overridden -
|
|
36
36
|
# printing anything outside that codepage then crashes the whole command with a
|
|
37
37
|
# UnicodeEncodeError instead of just rendering oddly. errors="replace" trades a perfect glyph
|
|
38
|
-
# for "never crashes on real
|
|
38
|
+
# for "never crashes on real StudyAtrium content" on whatever terminal this happens to run in.
|
|
39
39
|
if sys.platform == "win32":
|
|
40
40
|
for _stream in (sys.stdout, sys.stderr):
|
|
41
41
|
if hasattr(_stream, "reconfigure"):
|
|
@@ -125,7 +125,7 @@ def _print(
|
|
|
125
125
|
than fit a terminal - e.g. a note's full content, or a session's course_color) - --json always
|
|
126
126
|
returns every field regardless, since a table's readability limit doesn't apply there."""
|
|
127
127
|
if as_json:
|
|
128
|
-
# ensure_ascii=False -
|
|
128
|
+
# ensure_ascii=False - StudyAtrium content (course/note text) is mostly German;
|
|
129
129
|
# json.dumps' own default escapes every non-ASCII character into a \uXXXX
|
|
130
130
|
# sequence, technically valid JSON but unreadable for a human piping this to
|
|
131
131
|
# a file or terminal.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"""Typed HTTP client for the
|
|
1
|
+
"""Typed HTTP client for the StudyAtrium REST API, scoped to what
|
|
2
2
|
ApiKeyScopes.PubliclyGrantable actually allows a third-party client to do.
|
|
3
3
|
|
|
4
4
|
No internal-CA-trust handling here (unlike studylife-mcp's client.py) - this talks to the
|
|
@@ -170,7 +170,7 @@ def run_login(
|
|
|
170
170
|
LoginError on any failure - callers decide how to present that (CLI prints and exits 1)."""
|
|
171
171
|
base_url = instance_url.rstrip("/")
|
|
172
172
|
state_token = secrets.token_urlsafe(32)
|
|
173
|
-
# PKCE (RFC 7636): the assertion comes back through a browser redirect, and
|
|
173
|
+
# PKCE (RFC 7636): the assertion comes back through a browser redirect, and StudyAtrium only
|
|
174
174
|
# redeems it together with the verifier matching this challenge - so a copy of the redirect
|
|
175
175
|
# URL alone (browser history, a proxy log) is worthless to anyone but this process.
|
|
176
176
|
code_verifier, code_challenge = _new_pkce_pair()
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"""Pydantic models mirroring
|
|
1
|
+
"""Pydantic models mirroring StudyAtrium's actual OpenAPI schemas (fetched live from
|
|
2
2
|
`/openapi/v1.json` and cross-checked against StudyLife.Shared/Dtos.cs - not reconstructed from
|
|
3
3
|
memory, which previously produced wrong field names for StudySessionDto/CourseGoalDto).
|
|
4
4
|
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|