s3ui 1.0.0__py3-none-any.whl

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.
@@ -0,0 +1,153 @@
1
+ """Transfer panel widget for the bottom dock."""
2
+
3
+ from __future__ import annotations
4
+
5
+ import logging
6
+ from typing import TYPE_CHECKING
7
+
8
+ from PyQt6.QtCore import Qt, pyqtSignal
9
+ from PyQt6.QtWidgets import (
10
+ QAbstractItemView,
11
+ QHBoxLayout,
12
+ QHeaderView,
13
+ QLabel,
14
+ QPushButton,
15
+ QTableView,
16
+ QVBoxLayout,
17
+ QWidget,
18
+ )
19
+
20
+ from s3ui.models.transfer_model import TransferModel
21
+
22
+ if TYPE_CHECKING:
23
+ from s3ui.core.transfers import TransferEngine
24
+ from s3ui.db.database import Database
25
+
26
+ logger = logging.getLogger("s3ui.transfer_panel")
27
+
28
+
29
+ class TransferPanelWidget(QWidget):
30
+ """Panel showing active and completed transfers."""
31
+
32
+ pause_requested = pyqtSignal(int) # transfer_id
33
+ resume_requested = pyqtSignal(int) # transfer_id
34
+ cancel_requested = pyqtSignal(int) # transfer_id
35
+ retry_requested = pyqtSignal(int) # transfer_id
36
+
37
+ def __init__(self, db: Database | None = None, parent=None) -> None:
38
+ super().__init__(parent)
39
+ self._db = db
40
+ self._engine: TransferEngine | None = None
41
+ self._paused_global = False
42
+
43
+ self._setup_ui()
44
+
45
+ def _setup_ui(self) -> None:
46
+ layout = QVBoxLayout(self)
47
+ layout.setContentsMargins(0, 0, 0, 0)
48
+ layout.setSpacing(0)
49
+
50
+ # Header bar
51
+ header = QHBoxLayout()
52
+ header.setContentsMargins(8, 4, 8, 4)
53
+ self._header_label = QLabel("Transfers")
54
+ header.addWidget(self._header_label)
55
+ header.addStretch()
56
+
57
+ self._pause_all_btn = QPushButton("Pause All")
58
+ self._pause_all_btn.clicked.connect(self._on_pause_all)
59
+ header.addWidget(self._pause_all_btn)
60
+
61
+ header_widget = QWidget()
62
+ header_widget.setLayout(header)
63
+ layout.addWidget(header_widget)
64
+
65
+ # Transfer table
66
+ self._model = TransferModel(self._db)
67
+ self._table = QTableView()
68
+ self._table.setModel(self._model)
69
+ self._table.setSelectionMode(QAbstractItemView.SelectionMode.SingleSelection)
70
+ self._table.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
71
+ self._table.setShowGrid(False)
72
+ self._table.setAlternatingRowColors(True)
73
+ self._table.verticalHeader().setVisible(False)
74
+ self._table.horizontalHeader().setStretchLastSection(True)
75
+ self._table.horizontalHeader().setSectionResizeMode(1, QHeaderView.ResizeMode.Stretch)
76
+ # Direction column narrow
77
+ self._table.setColumnWidth(0, 30)
78
+ self._table.setContextMenuPolicy(Qt.ContextMenuPolicy.CustomContextMenu)
79
+ self._table.customContextMenuRequested.connect(self._on_context_menu)
80
+ layout.addWidget(self._table)
81
+
82
+ @property
83
+ def model(self) -> TransferModel:
84
+ return self._model
85
+
86
+ def set_engine(self, engine: TransferEngine) -> None:
87
+ """Wire the transfer engine signals to the model."""
88
+ self._engine = engine
89
+ engine.transfer_progress.connect(self._model.on_progress)
90
+ engine.transfer_speed.connect(self._model.on_speed)
91
+ engine.transfer_status_changed.connect(self._model.on_status_changed)
92
+ engine.transfer_error.connect(self._model.on_error)
93
+ engine.transfer_finished.connect(self._model.on_finished)
94
+
95
+ def add_transfer(self, transfer_id: int) -> None:
96
+ """Add a transfer to the panel."""
97
+ self._model.add_transfer(transfer_id)
98
+ self._update_header()
99
+
100
+ def _update_header(self) -> None:
101
+ active = self._model.active_count()
102
+ queued = self._model.queued_count()
103
+ parts = []
104
+ if active:
105
+ parts.append(f"{active} active")
106
+ if queued:
107
+ parts.append(f"{queued} queued")
108
+ if parts:
109
+ self._header_label.setText(f"Transfers ({', '.join(parts)})")
110
+ else:
111
+ self._header_label.setText("Transfers")
112
+
113
+ def _on_pause_all(self) -> None:
114
+ if not self._engine:
115
+ return
116
+ if self._paused_global:
117
+ self._engine.resume_all()
118
+ self._pause_all_btn.setText("Pause All")
119
+ self._paused_global = False
120
+ else:
121
+ self._engine.pause_all()
122
+ self._pause_all_btn.setText("Resume All")
123
+ self._paused_global = True
124
+
125
+ def _on_context_menu(self, pos) -> None:
126
+ from PyQt6.QtWidgets import QMenu
127
+
128
+ index = self._table.indexAt(pos)
129
+ if not index.isValid():
130
+ return
131
+
132
+ row_data = self._model.get_transfer_row(self._model._rows[index.row()].transfer_id)
133
+ if not row_data:
134
+ return
135
+
136
+ menu = QMenu(self)
137
+ tid = row_data.transfer_id
138
+
139
+ if row_data.status == "in_progress":
140
+ pause_action = menu.addAction("Pause")
141
+ pause_action.triggered.connect(lambda: self.pause_requested.emit(tid))
142
+ elif row_data.status == "paused":
143
+ resume_action = menu.addAction("Resume")
144
+ resume_action.triggered.connect(lambda: self.resume_requested.emit(tid))
145
+ elif row_data.status == "failed":
146
+ retry_action = menu.addAction("Retry")
147
+ retry_action.triggered.connect(lambda: self.retry_requested.emit(tid))
148
+
149
+ if row_data.status in ("queued", "in_progress", "paused"):
150
+ cancel_action = menu.addAction("Cancel")
151
+ cancel_action.triggered.connect(lambda: self.cancel_requested.emit(tid))
152
+
153
+ menu.exec(self._table.viewport().mapToGlobal(pos))
@@ -0,0 +1,118 @@
1
+ Metadata-Version: 2.4
2
+ Name: s3ui
3
+ Version: 1.0.0
4
+ Summary: A native file manager for Amazon S3
5
+ Project-URL: Homepage, https://github.com/justinGrosvenor/s3ui
6
+ Project-URL: Documentation, https://github.com/justinGrosvenor/s3ui/tree/main/docs
7
+ Project-URL: Repository, https://github.com/justinGrosvenor/s3ui
8
+ Project-URL: Issues, https://github.com/justinGrosvenor/s3ui/issues
9
+ Author: S3UI Contributors
10
+ License-Expression: MIT
11
+ License-File: LICENSE
12
+ Keywords: aws,desktop,file-manager,pyqt6,s3
13
+ Classifier: Development Status :: 3 - Alpha
14
+ Classifier: Environment :: MacOS X
15
+ Classifier: Environment :: Win32 (MS Windows)
16
+ Classifier: Environment :: X11 Applications :: Qt
17
+ Classifier: Intended Audience :: End Users/Desktop
18
+ Classifier: License :: OSI Approved :: MIT License
19
+ Classifier: Operating System :: OS Independent
20
+ Classifier: Programming Language :: Python :: 3.11
21
+ Classifier: Programming Language :: Python :: 3.12
22
+ Classifier: Programming Language :: Python :: 3.13
23
+ Classifier: Topic :: Desktop Environment :: File Managers
24
+ Classifier: Topic :: System :: Archiving
25
+ Requires-Python: >=3.11
26
+ Requires-Dist: boto3>=1.28
27
+ Requires-Dist: keyring>=24.0
28
+ Requires-Dist: pyqt6>=6.5
29
+ Provides-Extra: dev
30
+ Requires-Dist: moto[s3]>=4.0; extra == 'dev'
31
+ Requires-Dist: pre-commit>=3.0; extra == 'dev'
32
+ Requires-Dist: pyinstaller>=6.0; extra == 'dev'
33
+ Requires-Dist: pytest-qt>=4.2; extra == 'dev'
34
+ Requires-Dist: pytest>=7.0; extra == 'dev'
35
+ Requires-Dist: ruff>=0.1; extra == 'dev'
36
+ Description-Content-Type: text/markdown
37
+
38
+ <p align="center">
39
+ <img src="s3ui.png" alt="S3UI" width="128">
40
+ </p>
41
+
42
+ <h1 align="center">S3UI</h1>
43
+
44
+ <p align="center">
45
+ A native desktop file manager for Amazon S3 and S3-compatible services.
46
+ </p>
47
+
48
+ <p align="center">
49
+ <a href="https://pypi.org/project/s3ui/"><img src="https://img.shields.io/pypi/v/s3ui" alt="PyPI"></a>
50
+ <a href="https://pypi.org/project/s3ui/"><img src="https://img.shields.io/pypi/pyversions/s3ui" alt="Python"></a>
51
+ <a href="LICENSE"><img src="https://img.shields.io/github/license/justinGrosvenor/s3ui" alt="License"></a>
52
+ </p>
53
+
54
+ ---
55
+
56
+ S3UI is a free, open-source, cross-platform desktop app that makes Amazon S3 feel like a local file system. It provides a dual-pane file manager — local files on the left, S3 on the right — with drag-and-drop transfers, large-file handling, and built-in cost tracking.
57
+
58
+ Works with **Amazon S3**, **MinIO**, and any S3-compatible storage.
59
+
60
+ ## Features
61
+
62
+ - **Dual-pane browser** — local filesystem and S3 side by side
63
+ - **Drag and drop** — drop files onto the S3 pane to upload
64
+ - **Upload and download** — right-click context menus or drag and drop
65
+ - **New folder** — toolbar button and context menu
66
+ - **Multipart uploads** — large files are split and uploaded in parallel
67
+ - **Resume support** — interrupted transfers pick up where they left off
68
+ - **Transfer queue** — pause, resume, cancel, and retry individual transfers
69
+ - **Cost tracking** — estimates your monthly S3 costs as you work
70
+ - **AWS CLI profiles** — auto-discovers profiles from `~/.aws/config`
71
+ - **Custom endpoints** — connect to MinIO, LocalStack, or any S3-compatible service
72
+ - **Secure credentials** — stored in your OS keychain via `keyring`
73
+ - **Setup wizard** — guided first-run configuration
74
+ - **Keyboard shortcuts** — Ctrl+1/2 to switch panes, Ctrl+R to refresh, Ctrl+F to filter
75
+ - **System notifications** — notifies on large transfer completion when the app is in the background
76
+
77
+ ## Install
78
+
79
+ ```
80
+ pip install s3ui
81
+ ```
82
+
83
+ Requires Python 3.11+ and a running display server (X11, Wayland, macOS, or Windows).
84
+
85
+ ## Quick start
86
+
87
+ ```
88
+ s3ui
89
+ ```
90
+
91
+ On first launch, the setup wizard walks you through connecting your AWS account or S3-compatible service. You can also configure connections later from **Settings**.
92
+
93
+ ### MinIO example
94
+
95
+ In the setup wizard or Settings > Credentials > Add Profile:
96
+
97
+ | Field | Value |
98
+ |---|---|
99
+ | Profile Name | `my-minio` |
100
+ | Access Key ID | `minioadmin` |
101
+ | Secret Access Key | `minioadmin` |
102
+ | Region | `us-east-1` |
103
+ | Endpoint URL | `http://localhost:9000` |
104
+
105
+ ## Development
106
+
107
+ ```bash
108
+ git clone https://github.com/justinGrosvenor/s3ui.git
109
+ cd s3ui
110
+ python -m venv .venv && source .venv/bin/activate
111
+ pip install -e ".[dev]"
112
+ pre-commit install
113
+ pytest
114
+ ```
115
+
116
+ ## License
117
+
118
+ [MIT](LICENSE)
@@ -0,0 +1,40 @@
1
+ s3ui/__init__.py,sha256=J-j-u0itpEFT6irdmWmixQqYMadNl1X91TxUmoiLHMI,22
2
+ s3ui/app.py,sha256=RyLMR08xHXWSjh7DdDC6545jw0EzMWpFIWT88dT82X8,1428
3
+ s3ui/constants.py,sha256=qU8d6BpEvBnFDVRI4ktJRNDoOQPwmR2EK9KB5qbnCzU,998
4
+ s3ui/logging_setup.py,sha256=B4wAfuuFqk6GZfad0ynueGofdX0nM32Mv1M6FbmFP48,596
5
+ s3ui/main_window.py,sha256=Mu7Fh0dB9NR50UArkN4UOe6px9vaVuQoeB-EFhUxrPk,35756
6
+ s3ui/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
7
+ s3ui/core/cost.py,sha256=iGe3OZx35XA5sqE3Ikul9TtlPnrv1G5-3gN19HokNoQ,7988
8
+ s3ui/core/credentials.py,sha256=awCnOiuCJF0B5yosGPRkANfaXLJwlNkXz2m8HTlirT4,5858
9
+ s3ui/core/download_worker.py,sha256=ypFUURMoSt7Ad43GNdIhglRNQc5J_I6qBNRXvm0nIyI,9233
10
+ s3ui/core/errors.py,sha256=RfYkgTn5pUAg8Cnoq7wFlux3O86LuJtPbL736D-PpwA,3490
11
+ s3ui/core/listing_cache.py,sha256=j4v6RtuPc5LN0LrpA_ktzWTIhknJgiCcpUp6-a4DHoI,6386
12
+ s3ui/core/s3_client.py,sha256=eP9mC9XyYH6vfBcZlKYYOlcxp0xzsfA8SsA21CrceHw,13726
13
+ s3ui/core/stats.py,sha256=N39DbEQQjOHWVQByARR2PxuBjnz12aN9lBSAyS6OfLM,4206
14
+ s3ui/core/transfers.py,sha256=j52WB8Lh9_D7Q3pGp4c-nhrRZrrs_qzc7onZTGot21E,10300
15
+ s3ui/core/upload_worker.py,sha256=JB9kn44Jl9SqpjXH7RzmOiT3g4zPNCFHjzsvfoAgNgU,11453
16
+ s3ui/db/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
17
+ s3ui/db/database.py,sha256=Evb27RAjQ98BPJfIQ6wPW0e3RssQ5IcCqZBuy5ubbJg,5078
18
+ s3ui/db/migrations/001_initial.sql,sha256=r6uzCaG4D-W3pDHP7sCD31XucPaVioTAP2MyRqLPlOo,4657
19
+ s3ui/models/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
20
+ s3ui/models/s3_objects.py,sha256=r-ejl8sOYBL5HZrDEjWJmykIRbmttyqdlotiMck5y1s,9789
21
+ s3ui/models/transfer_model.py,sha256=DcjwR1edLxKIfZgRlfGoKatBOkw6pAmSJZmj8SO0Up0,9166
22
+ s3ui/resources/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
23
+ s3ui/resources/s3ui.png,sha256=KR06DVDjEzwxOK900qnDEBzW4gbVkwbGfNHTsi8GETg,1260324
24
+ s3ui/ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
25
+ s3ui/ui/breadcrumb_bar.py,sha256=rPLcPE0PBpb7EBzAtMVnoH5s5ozwyiMQCzCIRDjCnRw,5082
26
+ s3ui/ui/confirm_delete.py,sha256=w_UbOunh6ZWQIavyXzxIuBvuIDIrKkE_ep1HY7NrlTg,1655
27
+ s3ui/ui/cost_dialog.py,sha256=UlDkOtu86Erl9Vb1UUS9aElLkWg38AyOn4Ibpo14TiY,5904
28
+ s3ui/ui/get_info.py,sha256=S6jpnaoIhMSAsCZ999DFqpNpQJNWPi6g_3qPicXMzCs,1477
29
+ s3ui/ui/local_pane.py,sha256=UXOB9PzeSRBGiS6myUvqrC0grH9r0OPRlgixTsra0uM,8127
30
+ s3ui/ui/name_conflict.py,sha256=4v8i9fyFFUoY1j6806l8-AUiwsvzbOC5EmbNbMau9Qs,2116
31
+ s3ui/ui/s3_pane.py,sha256=OIxcgRnxh6ucEGduHIX6_B9epzDy4ZWd1_Ave7uEpDQ,20438
32
+ s3ui/ui/settings_dialog.py,sha256=7xUdSOYqy0hIVDIch6dRnKyB6srJohrXaPBY7SAAeg0,10828
33
+ s3ui/ui/setup_wizard.py,sha256=x6d6xE0WxHepQ-9FbN_lql5nXono8600oss03jicQY4,17063
34
+ s3ui/ui/stats_dialog.py,sha256=SNUi4mz_9fYgX27xpDL7OGIb_hf3-JmnWP8MLy7jqQc,5997
35
+ s3ui/ui/transfer_panel.py,sha256=OYH8yxRdabU7pvyUvhz360Yyl9qAvS9bRcHte16dAS0,5398
36
+ s3ui-1.0.0.dist-info/METADATA,sha256=dGRvuGeHYTToLtAw912VDcd-q8qG640AhGjgRFpGz3U,4260
37
+ s3ui-1.0.0.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
38
+ s3ui-1.0.0.dist-info/entry_points.txt,sha256=QeGaHmKRofZDCm4oWvH3_8nhl8gKWw3SSyYoc7MfUTg,39
39
+ s3ui-1.0.0.dist-info/licenses/LICENSE,sha256=w83Hvu4TWOszaK7RWJ8LgS7tWsBMVeQW3_EjG42nOP0,1078
40
+ s3ui-1.0.0.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: hatchling 1.28.0
3
+ Root-Is-Purelib: true
4
+ Tag: py3-none-any
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ s3ui = s3ui.app:main
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025-2026 Justin Grosvenor
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.