pywinpty 3.0.0__tar.gz → 3.0.2__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.
- pywinpty-3.0.2/.github/FUNDING.yml +2 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.github/workflows/linux_sdist.yml +1 -1
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.github/workflows/windows_build.yml +5 -11
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.github/workflows/windows_release.yml +5 -4
- {pywinpty-3.0.0 → pywinpty-3.0.2}/CHANGELOG.md +28 -2
- {pywinpty-3.0.0 → pywinpty-3.0.2}/Cargo.lock +80 -136
- {pywinpty-3.0.0 → pywinpty-3.0.2}/Cargo.toml +4 -4
- pywinpty-3.0.2/PKG-INFO +160 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/README.md +8 -1
- {pywinpty-3.0.0 → pywinpty-3.0.2}/build.rs +1 -0
- pywinpty-3.0.2/pyproject.toml +29 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/runtests.py +1 -1
- {pywinpty-3.0.0 → pywinpty-3.0.2}/src/lib.rs +8 -14
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/enums.py +1 -1
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/ptyprocess.py +1 -1
- pywinpty-3.0.0/PKG-INFO +0 -5
- pywinpty-3.0.0/pyproject.toml +0 -8
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.github/dependabot.yml +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.github/scripts/copy_winpty.sh +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/.gitignore +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/LICENSE.txt +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/MANIFEST.in +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/RELEASE.md +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/nuget.config +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/__init__.py +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/tests/__init__.py +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/tests/test_pty.py +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/tests/test_ptyprocess.py +0 -0
- {pywinpty-3.0.0 → pywinpty-3.0.2}/winpty/winpty.pyi +0 -0
|
@@ -20,17 +20,10 @@ jobs:
|
|
|
20
20
|
strategy:
|
|
21
21
|
fail-fast: false
|
|
22
22
|
matrix:
|
|
23
|
-
PYTHON_VERSION: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t"]
|
|
23
|
+
PYTHON_VERSION: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t", "3.14", "3.14t"]
|
|
24
24
|
steps:
|
|
25
25
|
- name: Checkout branch
|
|
26
|
-
uses: actions/checkout@
|
|
27
|
-
- name: Install latest Rust stable
|
|
28
|
-
uses: actions-rs/toolchain@v1
|
|
29
|
-
with:
|
|
30
|
-
toolchain: stable
|
|
31
|
-
target: x86_64-pc-windows-msvc
|
|
32
|
-
override: true
|
|
33
|
-
components: rustfmt, clippy
|
|
26
|
+
uses: actions/checkout@v5
|
|
34
27
|
- uses: nuget/setup-nuget@v2
|
|
35
28
|
with:
|
|
36
29
|
nuget-version: '5.x'
|
|
@@ -49,8 +42,9 @@ jobs:
|
|
|
49
42
|
uses: conda-incubator/setup-miniconda@v3
|
|
50
43
|
with:
|
|
51
44
|
auto-update-conda: true
|
|
52
|
-
|
|
53
|
-
channels: conda-forge,
|
|
45
|
+
miniforge-version: latest
|
|
46
|
+
channels: conda-forge/label/python_rc,conda-forge
|
|
47
|
+
conda-remove-defaults: "true"
|
|
54
48
|
python-version: ${{ env.PYTHON_VERSION_NONSUFFIX }}
|
|
55
49
|
- name: Reinstall free-threaded Python
|
|
56
50
|
if: ${{ endsWith(matrix.PYTHON_VERSION, 't') }}
|
|
@@ -15,10 +15,10 @@ jobs:
|
|
|
15
15
|
strategy:
|
|
16
16
|
fail-fast: false
|
|
17
17
|
matrix:
|
|
18
|
-
PYTHON_VERSION: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t"]
|
|
18
|
+
PYTHON_VERSION: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.13t", "3.14", "3.14t"]
|
|
19
19
|
steps:
|
|
20
20
|
- name: Checkout branch
|
|
21
|
-
uses: actions/checkout@
|
|
21
|
+
uses: actions/checkout@v5
|
|
22
22
|
- name: Install latest Rust stable
|
|
23
23
|
uses: actions-rs/toolchain@v1
|
|
24
24
|
with:
|
|
@@ -44,8 +44,9 @@ jobs:
|
|
|
44
44
|
uses: conda-incubator/setup-miniconda@v3
|
|
45
45
|
with:
|
|
46
46
|
auto-update-conda: true
|
|
47
|
-
|
|
48
|
-
channels: conda-forge,
|
|
47
|
+
miniforge-version: latest
|
|
48
|
+
channels: conda-forge/label/python_rc,conda-forge
|
|
49
|
+
conda-remove-defaults: "true"
|
|
49
50
|
python-version: ${{ env.PYTHON_VERSION_NONSUFFIX }}
|
|
50
51
|
- name: Reinstall free-threaded Python
|
|
51
52
|
if: ${{ endsWith(matrix.PYTHON_VERSION, 't') }}
|
|
@@ -1,3 +1,29 @@
|
|
|
1
|
+
## Version 3.0.2 (2025/10/03)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Pull Requests Merged
|
|
5
|
+
|
|
6
|
+
* [PR 541](https://github.com/andfoy/pywinpty/pull/541) - Add README section in pyproject.toml, by [@andfoy](https://github.com/andfoy)
|
|
7
|
+
|
|
8
|
+
In this release 1 pull request was closed.
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
## Version 3.0.1 (2025/10/03)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Pull Requests Merged
|
|
15
|
+
|
|
16
|
+
* [PR 540](https://github.com/andfoy/pywinpty/pull/540) - Update Rust dependencies ahead of v3.0.1, by [@andfoy](https://github.com/andfoy)
|
|
17
|
+
* [PR 539](https://github.com/andfoy/pywinpty/pull/539) - Fix typos discovered by codespell, by [@cclauss](https://github.com/cclauss)
|
|
18
|
+
* [PR 538](https://github.com/andfoy/pywinpty/pull/538) - Remove deprecated actions-rs/toolchain, by [@cclauss](https://github.com/cclauss)
|
|
19
|
+
* [PR 535](https://github.com/andfoy/pywinpty/pull/535) - Support Python 3.14(t), by [@ngoldbaum](https://github.com/ngoldbaum)
|
|
20
|
+
* [PR 534](https://github.com/andfoy/pywinpty/pull/534) - Bump serde_json from 1.0.142 to 1.0.145, by [@dependabot[bot]](https://github.com/apps/dependabot)
|
|
21
|
+
* [PR 533](https://github.com/andfoy/pywinpty/pull/533) - Update build.rs, by [@ImmortalEmperor](https://github.com/ImmortalEmperor)
|
|
22
|
+
* [PR 520](https://github.com/andfoy/pywinpty/pull/520) - Bump actions/checkout from 4 to 5, by [@dependabot[bot]](https://github.com/apps/dependabot)
|
|
23
|
+
|
|
24
|
+
In this release 7 pull requests were closed.
|
|
25
|
+
|
|
26
|
+
|
|
1
27
|
## Version 3.0.0 (2025/08/12)
|
|
2
28
|
|
|
3
29
|
|
|
@@ -470,7 +496,7 @@ In this release 1 pull request was closed.
|
|
|
470
496
|
### Issues Closed
|
|
471
497
|
|
|
472
498
|
* [Issue 126](https://github.com/spyder-ide/pywinpty/issues/126) - Release v0.5.6
|
|
473
|
-
* [Issue 123](https://github.com/spyder-ide/pywinpty/issues/123) - pip install fails on Python 3.8/
|
|
499
|
+
* [Issue 123](https://github.com/spyder-ide/pywinpty/issues/123) - pip install fails on Python 3.8/Windows ([PR 125](https://github.com/spyder-ide/pywinpty/pull/125))
|
|
474
500
|
|
|
475
501
|
In this release 2 issues were closed.
|
|
476
502
|
|
|
@@ -511,7 +537,7 @@ In this release 4 issues were closed.
|
|
|
511
537
|
|
|
512
538
|
### Pull Requests Merged
|
|
513
539
|
|
|
514
|
-
* [PR 113](https://github.com/spyder-ide/pywinpty/pull/113) - PR: Add PYWINPTY_BLOCK
|
|
540
|
+
* [PR 113](https://github.com/spyder-ide/pywinpty/pull/113) - PR: Add PYWINPTY_BLOCK environment variable to disable ptyprocess read block ([110](https://github.com/spyder-ide/pywinpty/issues/110))
|
|
515
541
|
* [PR 112](https://github.com/spyder-ide/pywinpty/pull/112) - PR: Remove import-time verification ([111](https://github.com/spyder-ide/pywinpty/issues/111))
|
|
516
542
|
* [PR 109](https://github.com/spyder-ide/pywinpty/pull/109) - PR: Fix for access violation error ([108](https://github.com/spyder-ide/pywinpty/issues/108))
|
|
517
543
|
|
|
@@ -10,9 +10,9 @@ checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8"
|
|
|
10
10
|
|
|
11
11
|
[[package]]
|
|
12
12
|
name = "bitflags"
|
|
13
|
-
version = "2.9.
|
|
13
|
+
version = "2.9.4"
|
|
14
14
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
15
|
-
checksum = "
|
|
15
|
+
checksum = "2261d10cca569e4643e526d8dc2e62e433cc8aba21ab764233731f8d369bf394"
|
|
16
16
|
|
|
17
17
|
[[package]]
|
|
18
18
|
name = "crossbeam-channel"
|
|
@@ -48,9 +48,9 @@ checksum = "c7f84e12ccf0a7ddc17a6c41c93326024c42920d7ee630d04950e6926645c0fe"
|
|
|
48
48
|
|
|
49
49
|
[[package]]
|
|
50
50
|
name = "errno"
|
|
51
|
-
version = "0.3.
|
|
51
|
+
version = "0.3.14"
|
|
52
52
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
53
|
-
checksum = "
|
|
53
|
+
checksum = "39cab71617ae0d63f51a36d69f866391735b51691dbda63cf6f96d042b63efeb"
|
|
54
54
|
dependencies = [
|
|
55
55
|
"libc",
|
|
56
56
|
"windows-sys",
|
|
@@ -58,9 +58,9 @@ dependencies = [
|
|
|
58
58
|
|
|
59
59
|
[[package]]
|
|
60
60
|
name = "glob"
|
|
61
|
-
version = "0.3.
|
|
61
|
+
version = "0.3.3"
|
|
62
62
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
63
|
-
checksum = "
|
|
63
|
+
checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280"
|
|
64
64
|
|
|
65
65
|
[[package]]
|
|
66
66
|
name = "heck"
|
|
@@ -82,21 +82,21 @@ checksum = "4a5f13b858c8d314ee3e8f639011f7ccefe71f97f96e50151fb991f267928e2c"
|
|
|
82
82
|
|
|
83
83
|
[[package]]
|
|
84
84
|
name = "libc"
|
|
85
|
-
version = "0.2.
|
|
85
|
+
version = "0.2.176"
|
|
86
86
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
87
|
-
checksum = "
|
|
87
|
+
checksum = "58f929b4d672ea937a23a1ab494143d968337a5f47e56d0815df1e0890ddf174"
|
|
88
88
|
|
|
89
89
|
[[package]]
|
|
90
90
|
name = "linux-raw-sys"
|
|
91
|
-
version = "0.
|
|
91
|
+
version = "0.11.0"
|
|
92
92
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
93
|
-
checksum = "
|
|
93
|
+
checksum = "df1d3c3b53da64cf5760482273a98e575c651a67eec7f77df96b5b642de8f039"
|
|
94
94
|
|
|
95
95
|
[[package]]
|
|
96
96
|
name = "memchr"
|
|
97
|
-
version = "2.7.
|
|
97
|
+
version = "2.7.6"
|
|
98
98
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
99
|
-
checksum = "
|
|
99
|
+
checksum = "f52b00d39961fc5b2736ea853c9cc86238e165017a493d1d5c8eac6bdc4cc273"
|
|
100
100
|
|
|
101
101
|
[[package]]
|
|
102
102
|
name = "memoffset"
|
|
@@ -130,18 +130,18 @@ checksum = "f84267b20a16ea918e43c6a88433c2d54fa145c92a811b5b047ccbe153674483"
|
|
|
130
130
|
|
|
131
131
|
[[package]]
|
|
132
132
|
name = "proc-macro2"
|
|
133
|
-
version = "1.0.
|
|
133
|
+
version = "1.0.101"
|
|
134
134
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
135
|
-
checksum = "
|
|
135
|
+
checksum = "89ae43fd86e4158d6db51ad8e2b80f313af9cc74f5c0e03ccb87de09998732de"
|
|
136
136
|
dependencies = [
|
|
137
137
|
"unicode-ident",
|
|
138
138
|
]
|
|
139
139
|
|
|
140
140
|
[[package]]
|
|
141
141
|
name = "pyo3"
|
|
142
|
-
version = "0.
|
|
142
|
+
version = "0.26.0"
|
|
143
143
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
144
|
-
checksum = "
|
|
144
|
+
checksum = "7ba0117f4212101ee6544044dae45abe1083d30ce7b29c4b5cbdfa2354e07383"
|
|
145
145
|
dependencies = [
|
|
146
146
|
"indoc",
|
|
147
147
|
"libc",
|
|
@@ -156,19 +156,18 @@ dependencies = [
|
|
|
156
156
|
|
|
157
157
|
[[package]]
|
|
158
158
|
name = "pyo3-build-config"
|
|
159
|
-
version = "0.
|
|
159
|
+
version = "0.26.0"
|
|
160
160
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
161
|
-
checksum = "
|
|
161
|
+
checksum = "4fc6ddaf24947d12a9aa31ac65431fb1b851b8f4365426e182901eabfb87df5f"
|
|
162
162
|
dependencies = [
|
|
163
|
-
"once_cell",
|
|
164
163
|
"target-lexicon",
|
|
165
164
|
]
|
|
166
165
|
|
|
167
166
|
[[package]]
|
|
168
167
|
name = "pyo3-ffi"
|
|
169
|
-
version = "0.
|
|
168
|
+
version = "0.26.0"
|
|
170
169
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
171
|
-
checksum = "
|
|
170
|
+
checksum = "025474d3928738efb38ac36d4744a74a400c901c7596199e20e45d98eb194105"
|
|
172
171
|
dependencies = [
|
|
173
172
|
"libc",
|
|
174
173
|
"pyo3-build-config",
|
|
@@ -176,9 +175,9 @@ dependencies = [
|
|
|
176
175
|
|
|
177
176
|
[[package]]
|
|
178
177
|
name = "pyo3-macros"
|
|
179
|
-
version = "0.
|
|
178
|
+
version = "0.26.0"
|
|
180
179
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
181
|
-
checksum = "
|
|
180
|
+
checksum = "2e64eb489f22fe1c95911b77c44cc41e7c19f3082fc81cce90f657cdc42ffded"
|
|
182
181
|
dependencies = [
|
|
183
182
|
"proc-macro2",
|
|
184
183
|
"pyo3-macros-backend",
|
|
@@ -188,9 +187,9 @@ dependencies = [
|
|
|
188
187
|
|
|
189
188
|
[[package]]
|
|
190
189
|
name = "pyo3-macros-backend"
|
|
191
|
-
version = "0.
|
|
190
|
+
version = "0.26.0"
|
|
192
191
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
193
|
-
checksum = "
|
|
192
|
+
checksum = "100246c0ecf400b475341b8455a9213344569af29a3c841d29270e53102e0fcf"
|
|
194
193
|
dependencies = [
|
|
195
194
|
"heck",
|
|
196
195
|
"proc-macro2",
|
|
@@ -201,7 +200,7 @@ dependencies = [
|
|
|
201
200
|
|
|
202
201
|
[[package]]
|
|
203
202
|
name = "pywinpty"
|
|
204
|
-
version = "3.0.
|
|
203
|
+
version = "3.0.2"
|
|
205
204
|
dependencies = [
|
|
206
205
|
"glob",
|
|
207
206
|
"pyo3",
|
|
@@ -210,18 +209,18 @@ dependencies = [
|
|
|
210
209
|
|
|
211
210
|
[[package]]
|
|
212
211
|
name = "quote"
|
|
213
|
-
version = "1.0.
|
|
212
|
+
version = "1.0.41"
|
|
214
213
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
215
|
-
checksum = "
|
|
214
|
+
checksum = "ce25767e7b499d1b604768e7cde645d14cc8584231ea6b295e9c9eb22c02e1d1"
|
|
216
215
|
dependencies = [
|
|
217
216
|
"proc-macro2",
|
|
218
217
|
]
|
|
219
218
|
|
|
220
219
|
[[package]]
|
|
221
220
|
name = "rustix"
|
|
222
|
-
version = "1.
|
|
221
|
+
version = "1.1.2"
|
|
223
222
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
224
|
-
checksum = "
|
|
223
|
+
checksum = "cd15f8a2c5551a84d56efdc1cd049089e409ac19a3072d5037a17fd70719ff3e"
|
|
225
224
|
dependencies = [
|
|
226
225
|
"bitflags",
|
|
227
226
|
"errno",
|
|
@@ -238,18 +237,28 @@ checksum = "28d3b2b1366ec20994f1fd18c3c594f05c5dd4bc44d8bb0c1c632c8d6829481f"
|
|
|
238
237
|
|
|
239
238
|
[[package]]
|
|
240
239
|
name = "serde"
|
|
241
|
-
version = "1.0.
|
|
240
|
+
version = "1.0.228"
|
|
241
|
+
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
242
|
+
checksum = "9a8e94ea7f378bd32cbbd37198a4a91436180c5bb472411e48b5ec2e2124ae9e"
|
|
243
|
+
dependencies = [
|
|
244
|
+
"serde_core",
|
|
245
|
+
"serde_derive",
|
|
246
|
+
]
|
|
247
|
+
|
|
248
|
+
[[package]]
|
|
249
|
+
name = "serde_core"
|
|
250
|
+
version = "1.0.228"
|
|
242
251
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
243
|
-
checksum = "
|
|
252
|
+
checksum = "41d385c7d4ca58e59fc732af25c3983b67ac852c1a25000afe1175de458b67ad"
|
|
244
253
|
dependencies = [
|
|
245
254
|
"serde_derive",
|
|
246
255
|
]
|
|
247
256
|
|
|
248
257
|
[[package]]
|
|
249
258
|
name = "serde_derive"
|
|
250
|
-
version = "1.0.
|
|
259
|
+
version = "1.0.228"
|
|
251
260
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
252
|
-
checksum = "
|
|
261
|
+
checksum = "d540f220d3187173da220f885ab66608367b6574e925011a9353e4badda91d79"
|
|
253
262
|
dependencies = [
|
|
254
263
|
"proc-macro2",
|
|
255
264
|
"quote",
|
|
@@ -258,21 +267,22 @@ dependencies = [
|
|
|
258
267
|
|
|
259
268
|
[[package]]
|
|
260
269
|
name = "serde_json"
|
|
261
|
-
version = "1.0.
|
|
270
|
+
version = "1.0.145"
|
|
262
271
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
263
|
-
checksum = "
|
|
272
|
+
checksum = "402a6f66d8c709116cf22f558eab210f5a50187f702eb4d7e5ef38d9a7f1c79c"
|
|
264
273
|
dependencies = [
|
|
265
274
|
"itoa",
|
|
266
275
|
"memchr",
|
|
267
276
|
"ryu",
|
|
268
277
|
"serde",
|
|
278
|
+
"serde_core",
|
|
269
279
|
]
|
|
270
280
|
|
|
271
281
|
[[package]]
|
|
272
282
|
name = "syn"
|
|
273
|
-
version = "2.0.
|
|
283
|
+
version = "2.0.106"
|
|
274
284
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
275
|
-
checksum = "
|
|
285
|
+
checksum = "ede7c438028d4436d71104916910f5bb611972c5cfd7f89b8300a8186e6fada6"
|
|
276
286
|
dependencies = [
|
|
277
287
|
"proc-macro2",
|
|
278
288
|
"quote",
|
|
@@ -281,15 +291,15 @@ dependencies = [
|
|
|
281
291
|
|
|
282
292
|
[[package]]
|
|
283
293
|
name = "target-lexicon"
|
|
284
|
-
version = "0.13.
|
|
294
|
+
version = "0.13.3"
|
|
285
295
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
286
|
-
checksum = "
|
|
296
|
+
checksum = "df7f62577c25e07834649fc3b39fafdc597c0a3527dc1c60129201ccfcbaa50c"
|
|
287
297
|
|
|
288
298
|
[[package]]
|
|
289
299
|
name = "unicode-ident"
|
|
290
|
-
version = "1.0.
|
|
300
|
+
version = "1.0.19"
|
|
291
301
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
292
|
-
checksum = "
|
|
302
|
+
checksum = "f63a545481291138910575129486daeaf8ac54aee4387fe7906919f7830c7d9d"
|
|
293
303
|
|
|
294
304
|
[[package]]
|
|
295
305
|
name = "unindent"
|
|
@@ -310,22 +320,21 @@ dependencies = [
|
|
|
310
320
|
|
|
311
321
|
[[package]]
|
|
312
322
|
name = "windows"
|
|
313
|
-
version = "0.
|
|
323
|
+
version = "0.62.1"
|
|
314
324
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
315
|
-
checksum = "
|
|
325
|
+
checksum = "49e6c4a1f363c8210c6f77ba24f645c61c6fb941eccf013da691f7e09515b8ac"
|
|
316
326
|
dependencies = [
|
|
317
327
|
"windows-collections",
|
|
318
328
|
"windows-core",
|
|
319
329
|
"windows-future",
|
|
320
|
-
"windows-link",
|
|
321
330
|
"windows-numerics",
|
|
322
331
|
]
|
|
323
332
|
|
|
324
333
|
[[package]]
|
|
325
334
|
name = "windows-bindgen"
|
|
326
|
-
version = "0.
|
|
335
|
+
version = "0.64.0"
|
|
327
336
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
328
|
-
checksum = "
|
|
337
|
+
checksum = "dccf77071e0b253f8918f49f8aed05827e0b3f03813d663da0df24ee979e725c"
|
|
329
338
|
dependencies = [
|
|
330
339
|
"serde",
|
|
331
340
|
"serde_json",
|
|
@@ -334,18 +343,18 @@ dependencies = [
|
|
|
334
343
|
|
|
335
344
|
[[package]]
|
|
336
345
|
name = "windows-collections"
|
|
337
|
-
version = "0.
|
|
346
|
+
version = "0.3.1"
|
|
338
347
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
339
|
-
checksum = "
|
|
348
|
+
checksum = "123e712f464a8a60ce1a13f4c446d2d43ab06464cb5842ff68f5c71b6fb7852e"
|
|
340
349
|
dependencies = [
|
|
341
350
|
"windows-core",
|
|
342
351
|
]
|
|
343
352
|
|
|
344
353
|
[[package]]
|
|
345
354
|
name = "windows-core"
|
|
346
|
-
version = "0.
|
|
355
|
+
version = "0.62.1"
|
|
347
356
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
348
|
-
checksum = "
|
|
357
|
+
checksum = "6844ee5416b285084d3d3fffd743b925a6c9385455f64f6d4fa3031c4c2749a9"
|
|
349
358
|
dependencies = [
|
|
350
359
|
"windows-implement",
|
|
351
360
|
"windows-interface",
|
|
@@ -356,9 +365,9 @@ dependencies = [
|
|
|
356
365
|
|
|
357
366
|
[[package]]
|
|
358
367
|
name = "windows-future"
|
|
359
|
-
version = "0.
|
|
368
|
+
version = "0.3.1"
|
|
360
369
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
361
|
-
checksum = "
|
|
370
|
+
checksum = "68f3db6b24b120200d649cd4811b4947188ed3a8d2626f7075146c5d178a9a4a"
|
|
362
371
|
dependencies = [
|
|
363
372
|
"windows-core",
|
|
364
373
|
"windows-link",
|
|
@@ -367,9 +376,9 @@ dependencies = [
|
|
|
367
376
|
|
|
368
377
|
[[package]]
|
|
369
378
|
name = "windows-implement"
|
|
370
|
-
version = "0.60.
|
|
379
|
+
version = "0.60.1"
|
|
371
380
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
372
|
-
checksum = "
|
|
381
|
+
checksum = "edb307e42a74fb6de9bf3a02d9712678b22399c87e6fa869d6dfcd8c1b7754e0"
|
|
373
382
|
dependencies = [
|
|
374
383
|
"proc-macro2",
|
|
375
384
|
"quote",
|
|
@@ -378,9 +387,9 @@ dependencies = [
|
|
|
378
387
|
|
|
379
388
|
[[package]]
|
|
380
389
|
name = "windows-interface"
|
|
381
|
-
version = "0.59.
|
|
390
|
+
version = "0.59.2"
|
|
382
391
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
383
|
-
checksum = "
|
|
392
|
+
checksum = "c0abd1ddbc6964ac14db11c7213d6532ef34bd9aa042c2e5935f59d7908b46a5"
|
|
384
393
|
dependencies = [
|
|
385
394
|
"proc-macro2",
|
|
386
395
|
"quote",
|
|
@@ -389,15 +398,15 @@ dependencies = [
|
|
|
389
398
|
|
|
390
399
|
[[package]]
|
|
391
400
|
name = "windows-link"
|
|
392
|
-
version = "0.
|
|
401
|
+
version = "0.2.0"
|
|
393
402
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
394
|
-
checksum = "
|
|
403
|
+
checksum = "45e46c0661abb7180e7b9c281db115305d49ca1709ab8242adf09666d2173c65"
|
|
395
404
|
|
|
396
405
|
[[package]]
|
|
397
406
|
name = "windows-numerics"
|
|
398
|
-
version = "0.
|
|
407
|
+
version = "0.3.0"
|
|
399
408
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
400
|
-
checksum = "
|
|
409
|
+
checksum = "2ce3498fe0aba81e62e477408383196b4b0363db5e0c27646f932676283b43d8"
|
|
401
410
|
dependencies = [
|
|
402
411
|
"windows-core",
|
|
403
412
|
"windows-link",
|
|
@@ -405,110 +414,45 @@ dependencies = [
|
|
|
405
414
|
|
|
406
415
|
[[package]]
|
|
407
416
|
name = "windows-result"
|
|
408
|
-
version = "0.
|
|
417
|
+
version = "0.4.0"
|
|
409
418
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
410
|
-
checksum = "
|
|
419
|
+
checksum = "7084dcc306f89883455a206237404d3eaf961e5bd7e0f312f7c91f57eb44167f"
|
|
411
420
|
dependencies = [
|
|
412
421
|
"windows-link",
|
|
413
422
|
]
|
|
414
423
|
|
|
415
424
|
[[package]]
|
|
416
425
|
name = "windows-strings"
|
|
417
|
-
version = "0.
|
|
426
|
+
version = "0.5.0"
|
|
418
427
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
419
|
-
checksum = "
|
|
428
|
+
checksum = "7218c655a553b0bed4426cf54b20d7ba363ef543b52d515b3e48d7fd55318dda"
|
|
420
429
|
dependencies = [
|
|
421
430
|
"windows-link",
|
|
422
431
|
]
|
|
423
432
|
|
|
424
433
|
[[package]]
|
|
425
434
|
name = "windows-sys"
|
|
426
|
-
version = "0.
|
|
427
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
428
|
-
checksum = "f2f500e4d28234f72040990ec9d39e3a6b950f9f22d3dba18416c35882612bcb"
|
|
429
|
-
dependencies = [
|
|
430
|
-
"windows-targets",
|
|
431
|
-
]
|
|
432
|
-
|
|
433
|
-
[[package]]
|
|
434
|
-
name = "windows-targets"
|
|
435
|
-
version = "0.53.3"
|
|
435
|
+
version = "0.61.1"
|
|
436
436
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
437
|
-
checksum = "
|
|
437
|
+
checksum = "6f109e41dd4a3c848907eb83d5a42ea98b3769495597450cf6d153507b166f0f"
|
|
438
438
|
dependencies = [
|
|
439
439
|
"windows-link",
|
|
440
|
-
"windows_aarch64_gnullvm",
|
|
441
|
-
"windows_aarch64_msvc",
|
|
442
|
-
"windows_i686_gnu",
|
|
443
|
-
"windows_i686_gnullvm",
|
|
444
|
-
"windows_i686_msvc",
|
|
445
|
-
"windows_x86_64_gnu",
|
|
446
|
-
"windows_x86_64_gnullvm",
|
|
447
|
-
"windows_x86_64_msvc",
|
|
448
440
|
]
|
|
449
441
|
|
|
450
442
|
[[package]]
|
|
451
443
|
name = "windows-threading"
|
|
452
|
-
version = "0.
|
|
444
|
+
version = "0.2.0"
|
|
453
445
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
454
|
-
checksum = "
|
|
446
|
+
checksum = "ab47f085ad6932defa48855254c758cdd0e2f2d48e62a34118a268d8f345e118"
|
|
455
447
|
dependencies = [
|
|
456
448
|
"windows-link",
|
|
457
449
|
]
|
|
458
450
|
|
|
459
|
-
[[package]]
|
|
460
|
-
name = "windows_aarch64_gnullvm"
|
|
461
|
-
version = "0.53.0"
|
|
462
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
463
|
-
checksum = "86b8d5f90ddd19cb4a147a5fa63ca848db3df085e25fee3cc10b39b6eebae764"
|
|
464
|
-
|
|
465
|
-
[[package]]
|
|
466
|
-
name = "windows_aarch64_msvc"
|
|
467
|
-
version = "0.53.0"
|
|
468
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
469
|
-
checksum = "c7651a1f62a11b8cbd5e0d42526e55f2c99886c77e007179efff86c2b137e66c"
|
|
470
|
-
|
|
471
|
-
[[package]]
|
|
472
|
-
name = "windows_i686_gnu"
|
|
473
|
-
version = "0.53.0"
|
|
474
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
475
|
-
checksum = "c1dc67659d35f387f5f6c479dc4e28f1d4bb90ddd1a5d3da2e5d97b42d6272c3"
|
|
476
|
-
|
|
477
|
-
[[package]]
|
|
478
|
-
name = "windows_i686_gnullvm"
|
|
479
|
-
version = "0.53.0"
|
|
480
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
481
|
-
checksum = "9ce6ccbdedbf6d6354471319e781c0dfef054c81fbc7cf83f338a4296c0cae11"
|
|
482
|
-
|
|
483
|
-
[[package]]
|
|
484
|
-
name = "windows_i686_msvc"
|
|
485
|
-
version = "0.53.0"
|
|
486
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
487
|
-
checksum = "581fee95406bb13382d2f65cd4a908ca7b1e4c2f1917f143ba16efe98a589b5d"
|
|
488
|
-
|
|
489
|
-
[[package]]
|
|
490
|
-
name = "windows_x86_64_gnu"
|
|
491
|
-
version = "0.53.0"
|
|
492
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
493
|
-
checksum = "2e55b5ac9ea33f2fc1716d1742db15574fd6fc8dadc51caab1c16a3d3b4190ba"
|
|
494
|
-
|
|
495
|
-
[[package]]
|
|
496
|
-
name = "windows_x86_64_gnullvm"
|
|
497
|
-
version = "0.53.0"
|
|
498
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
499
|
-
checksum = "0a6e035dd0599267ce1ee132e51c27dd29437f63325753051e71dd9e42406c57"
|
|
500
|
-
|
|
501
|
-
[[package]]
|
|
502
|
-
name = "windows_x86_64_msvc"
|
|
503
|
-
version = "0.53.0"
|
|
504
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
505
|
-
checksum = "271414315aff87387382ec3d271b52d7ae78726f5d44ac98b4f4030c91880486"
|
|
506
|
-
|
|
507
451
|
[[package]]
|
|
508
452
|
name = "winpty-rs"
|
|
509
|
-
version = "1.0.
|
|
453
|
+
version = "1.0.4"
|
|
510
454
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
511
|
-
checksum = "
|
|
455
|
+
checksum = "40de59a23f65026b6aad538a1acd6c5fa996894df469e2039eee1322e97581e8"
|
|
512
456
|
dependencies = [
|
|
513
457
|
"bitflags",
|
|
514
458
|
"crossbeam-channel",
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
[package]
|
|
2
2
|
name = "pywinpty"
|
|
3
|
-
version = "3.0.
|
|
3
|
+
version = "3.0.2"
|
|
4
4
|
authors = ["Edgar Andrés Margffoy Tuay <andfoy@gmail.com>"]
|
|
5
5
|
description = "Pseudo terminal support for Windows from Python."
|
|
6
6
|
repository = "https://github.com/spyder-ide/pywinpty"
|
|
7
7
|
license = "MIT"
|
|
8
8
|
keywords = ["pty", "pseudo-terminal", "conpty", "windows", "winpty"]
|
|
9
9
|
readme = "README.md"
|
|
10
|
-
edition = "
|
|
10
|
+
edition = "2024"
|
|
11
11
|
|
|
12
12
|
[lib]
|
|
13
13
|
name = "winpty"
|
|
@@ -17,10 +17,10 @@ crate-type = ["cdylib"]
|
|
|
17
17
|
glob = "0.3.2"
|
|
18
18
|
|
|
19
19
|
[dependencies]
|
|
20
|
-
winpty-rs = "1.0.
|
|
20
|
+
winpty-rs = "1.0.4"
|
|
21
21
|
|
|
22
22
|
[dependencies.pyo3]
|
|
23
|
-
version = "0.
|
|
23
|
+
version = "0.26.0"
|
|
24
24
|
features = ["extension-module"]
|
|
25
25
|
|
|
26
26
|
[package.metadata.docs.rs]
|
pywinpty-3.0.2/PKG-INFO
ADDED
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: pywinpty
|
|
3
|
+
Version: 3.0.2
|
|
4
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
5
|
+
Classifier: Programming Language :: Python
|
|
6
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
7
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
8
|
+
Classifier: Programming Language :: Python :: Free Threading
|
|
9
|
+
Classifier: Programming Language :: Python :: 3
|
|
10
|
+
Classifier: Topic :: Terminals
|
|
11
|
+
Classifier: Topic :: Terminals :: Terminal Emulators/X Terminals
|
|
12
|
+
Classifier: Programming Language :: Rust
|
|
13
|
+
License-File: LICENSE.txt
|
|
14
|
+
Summary: Pseudo terminal support for Windows from Python.
|
|
15
|
+
Keywords: PTY,Windows,pseudo-terminal,PyO3
|
|
16
|
+
Author: Edgar Margffoy
|
|
17
|
+
Author-email: andfoy@gmail.com
|
|
18
|
+
Maintainer-email: Edgar Margffoy <andfoy@gmail.com>
|
|
19
|
+
Requires-Python: >=3.9
|
|
20
|
+
Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
|
|
21
|
+
|
|
22
|
+
# PyWinpty: Pseudoterminals for Windows in Python
|
|
23
|
+
|
|
24
|
+
[](./LICENSE.txt)
|
|
25
|
+
[](https://pypi.org/project/pywinpty/)
|
|
26
|
+
[](https://www.anaconda.com/download/)
|
|
27
|
+
[](https://www.anaconda.com/download/)
|
|
28
|
+
[](https://pepy.tech/project/pywinpty)
|
|
29
|
+
[](https://github.com/spyder-ide/pywinpty)
|
|
30
|
+
[](https://github.com/andfoy/pywinpty/actions/workflows/windows_build.yml)
|
|
31
|
+
|
|
32
|
+
*Copyright © 2017–2022 Spyder Project Contributors*
|
|
33
|
+
*Copyright © 2022– Edgar Andrés Margffoy Tuay*
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
## Overview
|
|
37
|
+
|
|
38
|
+
PyWinpty allows creating and communicating with Windows processes that receive input and print outputs via console input and output pipes. PyWinpty supports both the native [ConPTY](https://devblogs.microsoft.com/commandline/windows-command-line-introducing-the-windows-pseudo-console-conpty/) interface and the previous, fallback [winpty](https://github.com/rprichard/winpty) library.
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
## Dependencies
|
|
42
|
+
To compile pywinpty sources, you must have [Rust](https://rustup.rs/) installed.
|
|
43
|
+
Optionally, you can also have Winpty's C header and library files available on your include path.
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
## Installation
|
|
47
|
+
You can install this library by using conda or pip package managers, as it follows:
|
|
48
|
+
|
|
49
|
+
Using conda (Recommended):
|
|
50
|
+
```bash
|
|
51
|
+
conda install pywinpty
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
Using pip:
|
|
55
|
+
```bash
|
|
56
|
+
pip install pywinpty
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
## Building from source
|
|
60
|
+
|
|
61
|
+
To build from sources, you will require both a working stable or nightly Rust toolchain with
|
|
62
|
+
target `x86_64-pc-windows-msvc`, which can be installed using [rustup](https://rustup.rs/).
|
|
63
|
+
|
|
64
|
+
Optionally, this library can be linked against winpty library, which you can install using conda-forge:
|
|
65
|
+
|
|
66
|
+
```batch
|
|
67
|
+
conda install winpty -c conda-forge
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
If you don't want to use conda, you will need to have the winpty binaries and headers available on your PATH.
|
|
71
|
+
|
|
72
|
+
Finally, pywinpty uses [Maturin](https://github.com/PyO3/maturin) as the build backend, which can be installed using `pip`:
|
|
73
|
+
|
|
74
|
+
```batch
|
|
75
|
+
pip install maturin
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
To test your compilation environment settings, you can build pywinpty sources locally, by
|
|
79
|
+
executing:
|
|
80
|
+
|
|
81
|
+
```bash
|
|
82
|
+
maturin develop
|
|
83
|
+
```
|
|
84
|
+
|
|
85
|
+
This package depends on the following Rust crates:
|
|
86
|
+
|
|
87
|
+
* [PyO3](https://github.com/PyO3/pyo3): Library used to produce Python bindings from Rust code.
|
|
88
|
+
* [WinPTY-rs](https://github.com/andfoy/winpty-rs): Create and spawn processes inside a pseudoterminal in Windows from Rust.
|
|
89
|
+
* [Maturin](https://github.com/PyO3/maturin): Build system to build and publish Rust-based Python packages.
|
|
90
|
+
|
|
91
|
+
## Package usage
|
|
92
|
+
Pywinpty offers a single python wrapper around winpty library functions.
|
|
93
|
+
This implies that using a single object (``winpty.PTY``) it is possible to access to all functionality, as it follows:
|
|
94
|
+
|
|
95
|
+
```python
|
|
96
|
+
# High level usage using `spawn`
|
|
97
|
+
from winpty import PtyProcess
|
|
98
|
+
|
|
99
|
+
proc = PtyProcess.spawn('python')
|
|
100
|
+
proc.write('print("hello, world!")\r\n')
|
|
101
|
+
proc.write('exit()\r\n')
|
|
102
|
+
while proc.isalive():
|
|
103
|
+
print(proc.readline())
|
|
104
|
+
|
|
105
|
+
# Low level usage using the raw `PTY` object
|
|
106
|
+
from winpty import PTY
|
|
107
|
+
|
|
108
|
+
# Start a new winpty-agent process of size (cols, rows)
|
|
109
|
+
cols, rows = 80, 25
|
|
110
|
+
process = PTY(cols, rows)
|
|
111
|
+
|
|
112
|
+
# Spawn a new console process, e.g., CMD
|
|
113
|
+
process.spawn(br'C:\windows\system32\cmd.exe')
|
|
114
|
+
|
|
115
|
+
# Read console output (Unicode)
|
|
116
|
+
process.read()
|
|
117
|
+
|
|
118
|
+
# Write input to console (Unicode)
|
|
119
|
+
process.write(b'Text')
|
|
120
|
+
|
|
121
|
+
# Resize console size
|
|
122
|
+
new_cols, new_rows = 90, 30
|
|
123
|
+
process.set_size(new_cols, new_rows)
|
|
124
|
+
|
|
125
|
+
# Know if the process is alive
|
|
126
|
+
alive = process.isalive()
|
|
127
|
+
|
|
128
|
+
# End winpty-agent process
|
|
129
|
+
del process
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
## Running tests
|
|
133
|
+
We use pytest to run tests as it follows (after calling ``maturin develop``), the test suite depends
|
|
134
|
+
on pytest-lazy-fixture, which can be installed via pip:
|
|
135
|
+
|
|
136
|
+
```batch
|
|
137
|
+
pip install pytest pytest-lazy-fixture flaky
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
All the tests can be executed using the following command
|
|
141
|
+
|
|
142
|
+
```bash
|
|
143
|
+
python runtests.py
|
|
144
|
+
```
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
## Changelog
|
|
148
|
+
Visit our [CHANGELOG](CHANGELOG.md) file to learn more about our new features and improvements.
|
|
149
|
+
|
|
150
|
+
|
|
151
|
+
## Contribution guidelines
|
|
152
|
+
We follow PEP8 and PEP257 for pure python packages and Rust to compile extensions. We use MyPy type annotations for all functions and classes declared on this package. Feel free to send a PR or create an issue if you have any problem/question.
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
## Security contact information
|
|
156
|
+
|
|
157
|
+
To report a security vulnerability, please use the
|
|
158
|
+
[Tidelift security contact](https://tidelift.com/security).
|
|
159
|
+
Tidelift will coordinate the fix and disclosure.
|
|
160
|
+
|
|
@@ -116,7 +116,7 @@ on pytest-lazy-fixture, which can be installed via pip:
|
|
|
116
116
|
pip install pytest pytest-lazy-fixture flaky
|
|
117
117
|
```
|
|
118
118
|
|
|
119
|
-
All the tests can be
|
|
119
|
+
All the tests can be executed using the following command
|
|
120
120
|
|
|
121
121
|
```bash
|
|
122
122
|
python runtests.py
|
|
@@ -129,3 +129,10 @@ Visit our [CHANGELOG](CHANGELOG.md) file to learn more about our new features an
|
|
|
129
129
|
|
|
130
130
|
## Contribution guidelines
|
|
131
131
|
We follow PEP8 and PEP257 for pure python packages and Rust to compile extensions. We use MyPy type annotations for all functions and classes declared on this package. Feel free to send a PR or create an issue if you have any problem/question.
|
|
132
|
+
|
|
133
|
+
|
|
134
|
+
## Security contact information
|
|
135
|
+
|
|
136
|
+
To report a security vulnerability, please use the
|
|
137
|
+
[Tidelift security contact](https://tidelift.com/security).
|
|
138
|
+
Tidelift will coordinate the fix and disclosure.
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
[project]
|
|
2
|
+
name = "pywinpty"
|
|
3
|
+
readme = "README.md"
|
|
4
|
+
requires-python = ">=3.9"
|
|
5
|
+
dynamic = ["version", "description"]
|
|
6
|
+
classifiers = [
|
|
7
|
+
"Development Status :: 5 - Production/Stable",
|
|
8
|
+
"Programming Language :: Python",
|
|
9
|
+
"License :: OSI Approved :: MIT License",
|
|
10
|
+
"Operating System :: Microsoft :: Windows",
|
|
11
|
+
"Programming Language :: Python :: Free Threading",
|
|
12
|
+
"Programming Language :: Python :: 3",
|
|
13
|
+
"Topic :: Terminals",
|
|
14
|
+
"Topic :: Terminals :: Terminal Emulators/X Terminals",
|
|
15
|
+
"Programming Language :: Rust"
|
|
16
|
+
|
|
17
|
+
]
|
|
18
|
+
keywords = ["PTY", "Windows", "pseudo-terminal", "PyO3"]
|
|
19
|
+
authors = [
|
|
20
|
+
{email = "andfoy@gmail.com"},
|
|
21
|
+
{name = "Edgar Margffoy"}
|
|
22
|
+
]
|
|
23
|
+
maintainers = [
|
|
24
|
+
{name = "Edgar Margffoy", email = "andfoy@gmail.com"}
|
|
25
|
+
]
|
|
26
|
+
|
|
27
|
+
[build-system]
|
|
28
|
+
requires = ["maturin>=1.1,<2.0"]
|
|
29
|
+
build-backend = "maturin"
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
|
|
2
|
-
use std::
|
|
3
|
-
// use cxx::Exception;
|
|
4
|
-
use std::{ffi::OsString, sync::Arc};
|
|
5
|
-
use std::sync::RwLock;
|
|
2
|
+
use std::ffi::OsString;
|
|
6
3
|
|
|
7
4
|
use pyo3::create_exception;
|
|
8
5
|
use pyo3::exceptions::PyException;
|
|
9
6
|
use pyo3::prelude::*;
|
|
10
|
-
use pyo3::sync::MutexExt;
|
|
11
7
|
|
|
12
|
-
// use pyo3::types::PyBytes;
|
|
13
8
|
use winptyrs::{PTY, PTYArgs, PTYBackend, MouseMode, AgentConfig};
|
|
14
|
-
// use winptyrs::pty::PTYImpl;
|
|
15
9
|
|
|
16
10
|
// Package version
|
|
17
11
|
const VERSION: &'static str = env!("CARGO_PKG_VERSION");
|
|
@@ -194,7 +188,7 @@ impl PyPTY {
|
|
|
194
188
|
///
|
|
195
189
|
fn set_size(&self, cols: i32, rows: i32, py: Python) -> PyResult<()> {
|
|
196
190
|
let result: Result<(), OsString> =
|
|
197
|
-
py.
|
|
191
|
+
py.detach(|| self.pty.set_size(cols, rows));
|
|
198
192
|
match result {
|
|
199
193
|
Ok(()) => Ok(()),
|
|
200
194
|
Err(error) => {
|
|
@@ -234,7 +228,7 @@ impl PyPTY {
|
|
|
234
228
|
fn read<'p>(&self, blocking: bool, py: Python<'p>) -> PyResult<OsString> {
|
|
235
229
|
// let result = self.pty.read(length, blocking);
|
|
236
230
|
let result: Result<OsString, OsString> =
|
|
237
|
-
py.
|
|
231
|
+
py.detach(move || self.pty.read(blocking));
|
|
238
232
|
|
|
239
233
|
match result {
|
|
240
234
|
Ok(bytes) => Ok(bytes),
|
|
@@ -268,7 +262,7 @@ impl PyPTY {
|
|
|
268
262
|
// let _guard = borrow_lock.lock_py_attached(py).unwrap();
|
|
269
263
|
//let utf16_str: Vec<u16> = to_write.encode_utf16().collect();
|
|
270
264
|
let result: Result<u32, OsString> =
|
|
271
|
-
py.
|
|
265
|
+
py.detach(move || {
|
|
272
266
|
self.pty.write(to_write)
|
|
273
267
|
});
|
|
274
268
|
match result {
|
|
@@ -293,7 +287,7 @@ impl PyPTY {
|
|
|
293
287
|
/// If there was an error whilst trying to determine the status of the process.
|
|
294
288
|
///
|
|
295
289
|
fn isalive(&self) -> PyResult<bool> {
|
|
296
|
-
// let result: Result<bool, OsString> = py.
|
|
290
|
+
// let result: Result<bool, OsString> = py.detach(move || self.pty.is_alive());
|
|
297
291
|
match self.pty.is_alive() {
|
|
298
292
|
Ok(alive) => Ok(alive),
|
|
299
293
|
Err(error) => {
|
|
@@ -318,7 +312,7 @@ impl PyPTY {
|
|
|
318
312
|
///
|
|
319
313
|
fn get_exitstatus(&self, py: Python) -> PyResult<Option<u32>> {
|
|
320
314
|
let result: Result<Option<u32>, OsString> =
|
|
321
|
-
py.
|
|
315
|
+
py.detach(|| self.pty.get_exitstatus());
|
|
322
316
|
match result {
|
|
323
317
|
Ok(status) => Ok(status),
|
|
324
318
|
Err(error) => {
|
|
@@ -341,7 +335,7 @@ impl PyPTY {
|
|
|
341
335
|
/// If there was an error whilst trying to determine the EOF status of the process.
|
|
342
336
|
///
|
|
343
337
|
fn iseof(&self, py: Python) -> PyResult<bool> {
|
|
344
|
-
let result: Result<bool, OsString> = py.
|
|
338
|
+
let result: Result<bool, OsString> = py.detach(|| self.pty.is_eof());
|
|
345
339
|
match result {
|
|
346
340
|
Ok(eof) => Ok(eof),
|
|
347
341
|
Err(error) => {
|
|
@@ -372,7 +366,7 @@ impl PyPTY {
|
|
|
372
366
|
|
|
373
367
|
/// Cancel all pending I/O.
|
|
374
368
|
fn cancel_io(&self, py: Python) -> PyResult<bool> {
|
|
375
|
-
let result: Result<bool, OsString> = py.
|
|
369
|
+
let result: Result<bool, OsString> = py.detach(|| self.pty.cancel_io());
|
|
376
370
|
match result {
|
|
377
371
|
Ok(cancel) => Ok(cancel),
|
|
378
372
|
Err(error) => {
|
|
@@ -97,7 +97,7 @@ class PtyProcess(object):
|
|
|
97
97
|
proc = PTY(dimensions[1], dimensions[0],
|
|
98
98
|
backend=backend)
|
|
99
99
|
|
|
100
|
-
# Create the
|
|
100
|
+
# Create the environment string.
|
|
101
101
|
envStrs = []
|
|
102
102
|
for (key, value) in env.items():
|
|
103
103
|
envStrs.append('%s=%s' % (key, value))
|
pywinpty-3.0.0/PKG-INFO
DELETED
pywinpty-3.0.0/pyproject.toml
DELETED
|
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
|