dmddl 0.2.17__tar.gz → 0.2.19__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.
- {dmddl-0.2.17 → dmddl-0.2.19}/PKG-INFO +23 -4
- {dmddl-0.2.17 → dmddl-0.2.19}/README.md +18 -1
- {dmddl-0.2.17 → dmddl-0.2.19}/pyproject.toml +6 -4
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/cli.py +8 -4
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/models/llm.py +10 -7
- dmddl-0.2.17/src/dmddl/.ruff_cache/.gitignore +0 -2
- dmddl-0.2.17/src/dmddl/.ruff_cache/0.11.9/1354378795363258161 +0 -0
- dmddl-0.2.17/src/dmddl/.ruff_cache/CACHEDIR.TAG +0 -1
- dmddl-0.2.17/src/dmddl/config/.env +0 -2
- dmddl-0.2.17/src/dmddl/input.txt +0 -1
- dmddl-0.2.17/src/dmddl/output.txt +0 -62
- {dmddl-0.2.17 → dmddl-0.2.19}/LICENSE +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/__init__.py +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/config/__init__.py +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/config/proxy.py +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/config/settings.py +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/models/__init__.py +0 -0
- {dmddl-0.2.17 → dmddl-0.2.19}/src/dmddl/models/prompt.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: dmddl
|
3
|
-
Version: 0.2.
|
3
|
+
Version: 0.2.19
|
4
4
|
Summary: cli tool for creating insert script from ddl script
|
5
5
|
License: MIT
|
6
6
|
Author: HoJLter
|
@@ -11,8 +11,10 @@ Classifier: Programming Language :: Python :: 3
|
|
11
11
|
Classifier: Programming Language :: Python :: 3.13
|
12
12
|
Requires-Dist: aiohttp (>=3.11.18,<4.0.0)
|
13
13
|
Requires-Dist: bs4 (>=0.0.2,<0.0.3)
|
14
|
-
Requires-Dist:
|
15
|
-
Requires-Dist:
|
14
|
+
Requires-Dist: dotenv (>=0.9.9,<0.10.0)
|
15
|
+
Requires-Dist: questionary (>=2.1.0,<3.0.0)
|
16
|
+
Requires-Dist: requests (>=2.32.3,<3.0.0)
|
17
|
+
Requires-Dist: rich (>=14.0.0,<15.0.0)
|
16
18
|
Description-Content-Type: text/markdown
|
17
19
|
|
18
20
|
|
@@ -24,7 +26,7 @@ Description-Content-Type: text/markdown
|
|
24
26
|
<img src="https://img.shields.io/badge/License-MIT-yellow.svg">
|
25
27
|
</a>
|
26
28
|
</div>
|
27
|
-
<img src=".github/dmddl%
|
29
|
+
<img src=".github/dmddl%20logo_4.png" align="center">
|
28
30
|
|
29
31
|
<h3 align="center">
|
30
32
|
CLI app that generates insertion script from DDL
|
@@ -35,3 +37,20 @@ Description-Content-Type: text/markdown
|
|
35
37
|
🖥 Installation
|
36
38
|
</h2>
|
37
39
|
|
40
|
+
To install DMDDL you may use pip:
|
41
|
+
|
42
|
+
<img src=".github/pip_install.png" align="center">
|
43
|
+
|
44
|
+
<h2>
|
45
|
+
How to use it?
|
46
|
+
</h2>
|
47
|
+
|
48
|
+
|
49
|
+
|
50
|
+
<h2>
|
51
|
+
🤝 Contributing
|
52
|
+
</h2>
|
53
|
+
|
54
|
+
If you would like to contribute to this project, welcome to issues.
|
55
|
+
(if i don't answer, you can email me)
|
56
|
+
|
@@ -7,7 +7,7 @@
|
|
7
7
|
<img src="https://img.shields.io/badge/License-MIT-yellow.svg">
|
8
8
|
</a>
|
9
9
|
</div>
|
10
|
-
<img src=".github/dmddl%
|
10
|
+
<img src=".github/dmddl%20logo_4.png" align="center">
|
11
11
|
|
12
12
|
<h3 align="center">
|
13
13
|
CLI app that generates insertion script from DDL
|
@@ -17,3 +17,20 @@
|
|
17
17
|
<h2>
|
18
18
|
🖥 Installation
|
19
19
|
</h2>
|
20
|
+
|
21
|
+
To install DMDDL you may use pip:
|
22
|
+
|
23
|
+
<img src=".github/pip_install.png" align="center">
|
24
|
+
|
25
|
+
<h2>
|
26
|
+
How to use it?
|
27
|
+
</h2>
|
28
|
+
|
29
|
+
|
30
|
+
|
31
|
+
<h2>
|
32
|
+
🤝 Contributing
|
33
|
+
</h2>
|
34
|
+
|
35
|
+
If you would like to contribute to this project, welcome to issues.
|
36
|
+
(if i don't answer, you can email me)
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[project]
|
2
2
|
name = "dmddl"
|
3
|
-
version = "0.2.
|
3
|
+
version = "0.2.19"
|
4
4
|
description = "cli tool for creating insert script from ddl script"
|
5
5
|
authors = [
|
6
6
|
{name = "HoJLter",email = "hojlter.work@gmail.com"}
|
@@ -9,10 +9,12 @@ license = {text = "MIT License"}
|
|
9
9
|
readme = "README.md"
|
10
10
|
requires-python = ">=3.13"
|
11
11
|
dependencies = [
|
12
|
-
"pydantic (>=2.11.4,<3.0.0)",
|
13
|
-
"pydantic-settings (>=2.9.1,<3.0.0)",
|
14
12
|
"aiohttp (>=3.11.18,<4.0.0)",
|
15
|
-
"bs4 (>=0.0.2,<0.0.3)"
|
13
|
+
"bs4 (>=0.0.2,<0.0.3)",
|
14
|
+
"rich (>=14.0.0,<15.0.0)",
|
15
|
+
"questionary (>=2.1.0,<3.0.0)",
|
16
|
+
"requests (>=2.32.3,<3.0.0)",
|
17
|
+
"dotenv (>=0.9.9,<0.10.0)"
|
16
18
|
]
|
17
19
|
|
18
20
|
|
@@ -1,6 +1,8 @@
|
|
1
1
|
import asyncio
|
2
2
|
|
3
3
|
import questionary
|
4
|
+
from requests.exceptions import ProxyError
|
5
|
+
|
4
6
|
from dmddl.config.settings import LLMSettings
|
5
7
|
from rich import print
|
6
8
|
from rich.syntax import Syntax
|
@@ -113,10 +115,10 @@ def main():
|
|
113
115
|
|
114
116
|
|
115
117
|
if not args.source and not args.config and not args.proxy:
|
116
|
-
print("[red bold]You must provide
|
118
|
+
print("[red bold]You must provide some arguments:\n"
|
117
119
|
"-c (--config): opens settings menu\n"
|
118
|
-
"-s (--source): specify the input file"
|
119
|
-
"-
|
120
|
+
"-s (--source): specify the input file\n"
|
121
|
+
"-ps (--proxy-source): specify the input file (request with proxy)")
|
120
122
|
|
121
123
|
if args.config:
|
122
124
|
set_parameters()
|
@@ -133,7 +135,9 @@ def main():
|
|
133
135
|
for proxy in proxies:
|
134
136
|
print(f"[yellow bold]- {proxy}")
|
135
137
|
else:
|
136
|
-
print("[
|
138
|
+
print("[red bold] Proxy does not found :( \n Try again later. (it really helps)")
|
139
|
+
|
140
|
+
|
137
141
|
|
138
142
|
confirmation, user_prompt = input_prompt_dialogue(args)
|
139
143
|
|
@@ -19,13 +19,16 @@ def openai_request(prompt, api_key, proxies = None):
|
|
19
19
|
|
20
20
|
if proxies:
|
21
21
|
for proxy in proxies:
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
22
|
+
try:
|
23
|
+
print(f"[yellow bold]Using proxy: {proxy}")
|
24
|
+
req_proxies = {
|
25
|
+
"https": proxy
|
26
|
+
}
|
27
|
+
response = requests.post(url=url, headers=headers, json=data, proxies = req_proxies)
|
28
|
+
if response.status_code == 200:
|
29
|
+
break
|
30
|
+
except:
|
31
|
+
pass
|
29
32
|
|
30
33
|
else:
|
31
34
|
response = requests.post(url=url, headers=headers, json=data)
|
Binary file
|
@@ -1 +0,0 @@
|
|
1
|
-
Signature: 8a477f597d28d172789f06886806bc55
|
dmddl-0.2.17/src/dmddl/input.txt
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
test
|
@@ -1,62 +0,0 @@
|
|
1
|
-
-- TABLE: users (15 records)
|
2
|
-
INSERT INTO users (user_id, username, email) VALUES
|
3
|
-
(1, 'alice_jones', 'alice.jones@example.com'),
|
4
|
-
(2, 'bob_brown', 'bob.brown@example.com'),
|
5
|
-
(3, 'charlie_lee', 'charlie.lee@test.com'),
|
6
|
-
(4, 'david_clark', 'david.clark@example.com'),
|
7
|
-
(5, 'emily_williams', 'emily.williams@test.com'),
|
8
|
-
(6, 'frank_miller', 'frank.miller@example.com'),
|
9
|
-
(7, 'grace_king', 'grace.king@test.com'),
|
10
|
-
(8, 'hannah_white', 'hannah.white@example.com'),
|
11
|
-
(9, 'ian_green', 'ian.green@example.com'),
|
12
|
-
(10, 'jake_harris', 'jake.harris@test.com'),
|
13
|
-
(11, 'kate_scott', 'kate.scott@example.com'),
|
14
|
-
(12, 'luke_adams', 'luke.adams@test.com'),
|
15
|
-
(13, 'mike_james', 'mike.james@example.com'),
|
16
|
-
(14, 'nora_moore', 'nora.moore@test.com'),
|
17
|
-
(15, 'olivia_taylor', 'olivia.taylor@example.com');
|
18
|
-
|
19
|
-
-- TABLE: orders (40 records)
|
20
|
-
INSERT INTO orders (order_id, user_id, order_date) VALUES
|
21
|
-
(1, 1, '2023-01-01'),
|
22
|
-
(2, 1, '2023-01-05'),
|
23
|
-
(3, 2, '2023-01-02'),
|
24
|
-
(4, 3, '2023-01-01'),
|
25
|
-
(5, 3, '2023-01-03'),
|
26
|
-
(6, 4, '2023-01-04'),
|
27
|
-
(7, 4, '2023-01-07'),
|
28
|
-
(8, 5, '2023-01-02'),
|
29
|
-
(9, 5, '2023-01-06'),
|
30
|
-
(10, 6, '2023-01-05'),
|
31
|
-
(11, 6, '2023-01-08'),
|
32
|
-
(12, 7, '2023-01-01'),
|
33
|
-
(13, 8, '2023-01-03'),
|
34
|
-
(14, 8, '2023-01-09'),
|
35
|
-
(15, 9, '2023-01-01'),
|
36
|
-
(16, 10, '2023-01-02'),
|
37
|
-
(17, 10, '2023-01-06'),
|
38
|
-
(18, 11, '2023-01-04'),
|
39
|
-
(19, 11, '2023-01-10'),
|
40
|
-
(20, 12, '2023-01-01'),
|
41
|
-
(21, 12, '2023-01-03'),
|
42
|
-
(22, 13, '2023-01-02'),
|
43
|
-
(23, 13, '2023-01-05'),
|
44
|
-
(24, 14, '2023-01-04'),
|
45
|
-
(25, 14, '2023-01-08'),
|
46
|
-
(26, 15, '2023-01-02'),
|
47
|
-
(27, 15, '2023-01-09'),
|
48
|
-
(28, 1, '2023-01-06'),
|
49
|
-
(29, 2, '2023-01-03'),
|
50
|
-
(30, 3, '2023-01-07'),
|
51
|
-
(31, 4, '2023-01-08'),
|
52
|
-
(32, 5, '2023-01-01'),
|
53
|
-
(33, 6, '2023-01-05'),
|
54
|
-
(34, 7, '2023-01-02'),
|
55
|
-
(35, 8, '2023-01-10'),
|
56
|
-
(36, 9, '2023-01-06'),
|
57
|
-
(37, 10, '2023-01-04'),
|
58
|
-
(38, 11, '2023-01-03'),
|
59
|
-
(39, 12, '2023-01-07'),
|
60
|
-
(40, 13, '2023-01-09');
|
61
|
-
|
62
|
-
-- WARNING: Consider implementing ON DELETE CASCADE for foreign keys to maintain data integrity.
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|