pythia-plsql 0.7.1__tar.gz → 0.9.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 (44) hide show
  1. {pythia_plsql-0.7.1/scripts/pythia_plsql.egg-info → pythia_plsql-0.9.0}/PKG-INFO +14 -10
  2. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/README.md +13 -9
  3. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/pyproject.toml +1 -1
  4. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia.py +559 -37
  5. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0/scripts/pythia_plsql.egg-info}/PKG-INFO +14 -10
  6. pythia_plsql-0.9.0/skills/pythia-apply/SKILL.md +149 -0
  7. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/tests/test_phase3.py +582 -3
  8. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/tests/test_phase5.py +23 -1
  9. pythia_plsql-0.7.1/skills/pythia-apply/SKILL.md +0 -147
  10. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/LICENSE +0 -0
  11. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/compile-errors.sql +0 -0
  12. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/dependencies.sql +0 -0
  13. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/impact.sql +0 -0
  14. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/invalid-objects.sql +0 -0
  15. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/name-occupants.sql +0 -0
  16. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/object-names.sql +0 -0
  17. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/object-source.sql +0 -0
  18. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/plscope-enabled.sql +0 -0
  19. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/plscope-statements.sql +0 -0
  20. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/plscope-usages.sql +0 -0
  21. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/session-privileges.sql +0 -0
  22. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/similar-candidates.sql +0 -0
  23. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/queries/source.sql +0 -0
  24. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia_plsql.egg-info/SOURCES.txt +0 -0
  25. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia_plsql.egg-info/dependency_links.txt +0 -0
  26. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia_plsql.egg-info/entry_points.txt +0 -0
  27. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia_plsql.egg-info/requires.txt +0 -0
  28. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/scripts/pythia_plsql.egg-info/top_level.txt +0 -0
  29. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/setup.cfg +0 -0
  30. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-conventions/SKILL.md +0 -0
  31. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-explore/SKILL.md +0 -0
  32. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-explore/reference/data-dictionary.md +0 -0
  33. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-impact/SKILL.md +0 -0
  34. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-review/SKILL.md +0 -0
  35. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-review/reference/antipatterns.md +0 -0
  36. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-setup/SKILL.md +0 -0
  37. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-skill-author/SKILL.md +0 -0
  38. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-spec/SKILL.md +0 -0
  39. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-write/SKILL.md +0 -0
  40. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/pythia-write/reference/patterns.md +0 -0
  41. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/skills/using-pythia/SKILL.md +0 -0
  42. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/tests/test_install.py +0 -0
  43. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/tests/test_phase1.py +0 -0
  44. {pythia_plsql-0.7.1 → pythia_plsql-0.9.0}/tests/test_phase2.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pythia-plsql
3
- Version: 0.7.1
3
+ Version: 0.9.0
4
4
  Summary: PL/SQL development for AI agents on Oracle Database - expert data-dictionary queries, impact analysis, and a snapshot-verified write path with honest rollback.
5
5
  License: MIT
6
6
  Project-URL: Homepage, https://github.com/thaildhe172591/pythia
@@ -81,7 +81,8 @@ is the missing input, and forbids it to guess past them:
81
81
 
82
82
  - **Before any write**: the full preview — diff, dependents, warnings — is
83
83
  relayed verbatim, and the agent waits for a real yes. A compliment is not a
84
- yes. Silence is not a yes.
84
+ yes. Silence is not a yes. And the wait is no longer a matter of obedience:
85
+ the write cannot complete until the developer mints the approval themselves.
85
86
  - **When the blast radius is large**: ten or more dependents, or anything
86
87
  cross-schema, goes to the developer *before code is written*, not after.
87
88
  - **When sources of truth disagree**: a standards document says one thing,
@@ -96,12 +97,15 @@ is the missing input, and forbids it to guess past them:
96
97
  ### 3 · Do — act inside a pipeline that cannot lie
97
98
 
98
99
  Only after Learn and Ask does anything touch the database, and then only
99
- through one door: **snapshot → impact → preview → token → apply → verify →
100
- report**. DDL self-commits in Oracle, so the snapshot is the only real undo —
101
- it runs first and no flag disables it. A content-bound token guarantees what
102
- lands is byte-for-byte what was approved. And the CLI enforces the gates
103
- itself: a headless agent cannot `--yes` its own writes or loosen policy —
104
- that takes a human at a real terminal.
100
+ through one door: **snapshot → impact → preview → token → approve → apply →
101
+ verify → report**. DDL self-commits in Oracle, so the snapshot is the only real
102
+ undo — it runs first and no flag disables it. A content-bound token guarantees
103
+ what lands is byte-for-byte what was previewed, and a **developer-minted grant**
104
+ guarantees a person approved it at all: `pythia approve` runs only at a human's
105
+ own console, and without its one-time grant `apply --confirm` refuses. The
106
+ agent's command line is unchanged; what changed is that it now stops until
107
+ someone acts. A headless agent cannot `--yes` its own writes, cannot approve
108
+ them, and cannot loosen policy — each of those takes a human at a real terminal.
105
109
 
106
110
  The same discipline holds when the *developer* does the work: `src` and
107
111
  `impact` silently snapshot what they read, so even a change made by hand in
@@ -162,7 +166,7 @@ and WSL are all CI-tested.
162
166
  | `args` signatures | `invalid` everything broken | `unistr` exact non-ASCII literals |
163
167
  | `ddl` via DBMS_METADATA | `plscope` exact identifier usages | `agent-user` least-privilege setup |
164
168
  | `cols` columns + types | `similar` programs named like this | `history` every captured version |
165
- | `grep` search all source | | |
169
+ | `grep` search all source | | `approve` the developer's one-time grant |
166
170
  | `sql` free query (SELECT/WITH only) | | |
167
171
 
168
172
  Every command takes `--json` (machine output), `--conn` (pick a connection), and
@@ -207,7 +211,7 @@ Per-group write policy, `.pythia/policy.json` (defaults shown):
207
211
  | Group | Default | Is rollback real? |
208
212
  |---|---|---|
209
213
  | `plsql_source` | `confirm` | **Yes — completely.** Source is recoverable from `ALL_SOURCE`. |
210
- | `data_dml` | `deny` | **No.** After commit only Flashback Query remains, within undo retention. |
214
+ | `data_dml` | `deny` | **No.** After commit only Flashback Query remains, within undo retention. Revalidation checks the row set *before* the write; it is not an undo. |
211
215
  | `structural` | `deny` | **Almost never.** `DROP COLUMN` is permanent; a dropped table may be in the Recycle Bin. |
212
216
  | `grants` | `deny` | Yes, but by hand. |
213
217
  | `session` | `allow` | Not needed. |
@@ -67,7 +67,8 @@ is the missing input, and forbids it to guess past them:
67
67
 
68
68
  - **Before any write**: the full preview — diff, dependents, warnings — is
69
69
  relayed verbatim, and the agent waits for a real yes. A compliment is not a
70
- yes. Silence is not a yes.
70
+ yes. Silence is not a yes. And the wait is no longer a matter of obedience:
71
+ the write cannot complete until the developer mints the approval themselves.
71
72
  - **When the blast radius is large**: ten or more dependents, or anything
72
73
  cross-schema, goes to the developer *before code is written*, not after.
73
74
  - **When sources of truth disagree**: a standards document says one thing,
@@ -82,12 +83,15 @@ is the missing input, and forbids it to guess past them:
82
83
  ### 3 · Do — act inside a pipeline that cannot lie
83
84
 
84
85
  Only after Learn and Ask does anything touch the database, and then only
85
- through one door: **snapshot → impact → preview → token → apply → verify →
86
- report**. DDL self-commits in Oracle, so the snapshot is the only real undo —
87
- it runs first and no flag disables it. A content-bound token guarantees what
88
- lands is byte-for-byte what was approved. And the CLI enforces the gates
89
- itself: a headless agent cannot `--yes` its own writes or loosen policy —
90
- that takes a human at a real terminal.
86
+ through one door: **snapshot → impact → preview → token → approve → apply →
87
+ verify → report**. DDL self-commits in Oracle, so the snapshot is the only real
88
+ undo — it runs first and no flag disables it. A content-bound token guarantees
89
+ what lands is byte-for-byte what was previewed, and a **developer-minted grant**
90
+ guarantees a person approved it at all: `pythia approve` runs only at a human's
91
+ own console, and without its one-time grant `apply --confirm` refuses. The
92
+ agent's command line is unchanged; what changed is that it now stops until
93
+ someone acts. A headless agent cannot `--yes` its own writes, cannot approve
94
+ them, and cannot loosen policy — each of those takes a human at a real terminal.
91
95
 
92
96
  The same discipline holds when the *developer* does the work: `src` and
93
97
  `impact` silently snapshot what they read, so even a change made by hand in
@@ -148,7 +152,7 @@ and WSL are all CI-tested.
148
152
  | `args` signatures | `invalid` everything broken | `unistr` exact non-ASCII literals |
149
153
  | `ddl` via DBMS_METADATA | `plscope` exact identifier usages | `agent-user` least-privilege setup |
150
154
  | `cols` columns + types | `similar` programs named like this | `history` every captured version |
151
- | `grep` search all source | | |
155
+ | `grep` search all source | | `approve` the developer's one-time grant |
152
156
  | `sql` free query (SELECT/WITH only) | | |
153
157
 
154
158
  Every command takes `--json` (machine output), `--conn` (pick a connection), and
@@ -193,7 +197,7 @@ Per-group write policy, `.pythia/policy.json` (defaults shown):
193
197
  | Group | Default | Is rollback real? |
194
198
  |---|---|---|
195
199
  | `plsql_source` | `confirm` | **Yes — completely.** Source is recoverable from `ALL_SOURCE`. |
196
- | `data_dml` | `deny` | **No.** After commit only Flashback Query remains, within undo retention. |
200
+ | `data_dml` | `deny` | **No.** After commit only Flashback Query remains, within undo retention. Revalidation checks the row set *before* the write; it is not an undo. |
197
201
  | `structural` | `deny` | **Almost never.** `DROP COLUMN` is permanent; a dropped table may be in the Recycle Bin. |
198
202
  | `grants` | `deny` | Yes, but by hand. |
199
203
  | `session` | `allow` | Not needed. |
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "pythia-plsql"
7
- version = "0.7.1"
7
+ version = "0.9.0"
8
8
  description = "PL/SQL development for AI agents on Oracle Database - expert data-dictionary queries, impact analysis, and a snapshot-verified write path with honest rollback."
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }