Compare commits

...

6 Commits

Author SHA1 Message Date
rob fc728f27f7 Fix Qt cleanup warning with proper worker lifecycle management
- Keep reference to active worker in dialog instance
- Use deleteLater() for Signals QObject cleanup
- Prevents "shared QObject deleted directly" warning

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 04:07:36 -04:00
rob 0041bc0fae Fix Qt cleanup warning on dialog close
Add closeEvent that waits for thread pool workers to finish
before closing, preventing "shared QObject deleted directly" warning.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 04:00:38 -04:00
rob 493a499888 Add missing Qt6 xcb platform dependencies
Added libxkbcommon-x11-0, libxcb-image0, libxcb-render0,
libxcb-shm0, libxcb-sync1, libxcb-xfixes0, libxcb-xkb1,
libx11-xcb1, libfontconfig1, libfreetype6

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 03:52:55 -04:00
rob c068b387a1 Fix Dockerfile to use ENTRYPOINT for argument passing
CMD was being replaced entirely when passing arguments.
ENTRYPOINT makes ramble the base command so arguments work:
  docker run image --provider mock

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 03:41:21 -04:00
rob aceb03f612 Update README with pre-built Docker container and links
- Add Quick Start section with pre-built container option
- Add Docker section with pull instructions
- Add Links section (repository, Docker image, issues)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 03:26:29 -04:00
rob a5be322bf0 Add issue templates for bug reports, feature requests, and questions
🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-30 03:25:43 -04:00
6 changed files with 144 additions and 17 deletions

View File

@ -0,0 +1,32 @@
---
name: Bug Report
about: Report something that isn't working
labels: bug
---
## Description
What happened?
## Steps to Reproduce
1.
2.
3.
## Expected Behavior
What should have happened?
## Environment
- OS:
- Ramble version:
- Provider (mock/claude/codex/gemini):
- Docker or native install?
## Error Output
```
Paste any error messages here
```

View File

@ -0,0 +1,21 @@
---
name: Feature Request
about: Suggest a new feature or improvement
labels: enhancement
---
## Feature Description
A clear description of the feature you'd like to see.
## Use Case
Why do you need this? What problem does it solve?
## Proposed Solution
How do you think it should work? (optional)
## Alternatives Considered
Any other approaches you've thought about? (optional)

View File

@ -0,0 +1,17 @@
---
name: Question
about: Ask a question about Ramble
labels: question
---
## Question
What would you like to know?
## What I've Tried
Any steps you've already taken to find the answer?
## Context
Any additional context that might help?

View File

@ -11,18 +11,29 @@ LABEL description="Ramble - AI-powered structured field extraction GUI"
# Install system dependencies
RUN apt-get update && apt-get install -y --no-install-recommends \
plantuml \
# Qt6 dependencies (Debian Trixie package names)
# Qt6 xcb platform plugin dependencies
libgl1 \
libegl1 \
libxkbcommon0 \
libxkbcommon-x11-0 \
libdbus-1-3 \
libxcb1 \
libxcb-cursor0 \
libxcb-icccm4 \
libxcb-image0 \
libxcb-keysyms1 \
libxcb-shape0 \
libxcb-xinerama0 \
libxcb-randr0 \
libxcb-render0 \
libxcb-render-util0 \
libxcb-shape0 \
libxcb-shm0 \
libxcb-sync1 \
libxcb-xfixes0 \
libxcb-xinerama0 \
libxcb-xkb1 \
libxcb-randr0 \
libx11-xcb1 \
libfontconfig1 \
libfreetype6 \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /app
@ -37,8 +48,10 @@ RUN pip install --no-cache-dir -e .
# Verify installation
RUN ramble --help
# Default: show help
CMD ["ramble", "--help"]
# ENTRYPOINT makes ramble the base command
# CMD provides default args (can be overridden)
ENTRYPOINT ["ramble"]
CMD ["--help"]
# ==============================================================================
# Usage Examples

View File

@ -15,10 +15,24 @@ A configurable GUI tool that lets users "ramble" about an idea and extracts stru
- **Multiple providers** - Claude, Codex, Gemini, or mock for testing
- **Headless mode** - Skip GUI, pass values directly via CLI
## Installation
## Quick Start
### Option 1: Pre-built Docker Container
```bash
# Allow X11 access
xhost +local:docker
# Run the GUI with mock provider (no AI required)
docker run -it --rm \
-e DISPLAY=$DISPLAY \
-v /tmp/.X11-unix:/tmp/.X11-unix \
gitea.brrd.tech/rob/ramble --provider mock
```
### Option 2: Native Install
```bash
# Clone and install
git clone https://gitea.brrd.tech/rob/ramble.git
cd ramble
pip install -e .
@ -29,17 +43,31 @@ sudo apt install plantuml # For diagram rendering
## Docker
Run without installing anything locally:
### Pre-built Image
```bash
# Pull the pre-built container
docker pull gitea.brrd.tech/rob/ramble:latest
# Run GUI (requires: xhost +local:docker)
docker run -it --rm \
-e DISPLAY=$DISPLAY \
-v /tmp/.X11-unix:/tmp/.X11-unix \
gitea.brrd.tech/rob/ramble --provider mock
# Headless mode
docker run -it --rm gitea.brrd.tech/rob/ramble \
--field-values '{"Title":"MyApp","Summary":"A cool app"}'
```
### Build from Source
```bash
# Clone the repo
git clone https://gitea.brrd.tech/rob/ramble.git
cd ramble
# Build
docker-compose build
# Launch GUI (requires: xhost +local:docker)
# Launch GUI
docker-compose run --rm gui
# Headless mode
@ -158,6 +186,12 @@ ramble/
└── pyproject.toml
```
## Links
- **Repository**: https://gitea.brrd.tech/rob/ramble
- **Docker Image**: `gitea.brrd.tech/rob/ramble:latest`
- **Issues**: https://gitea.brrd.tech/rob/ramble/issues
## License
MIT

View File

@ -197,6 +197,7 @@ class RambleDialog(QDialog):
self.thread_pool = QThreadPool.globalInstance()
self.result: Optional[RambleResult] = None
self._active_worker: Optional[GenWorker] = None # Keep reference to prevent premature GC
self.field_lock_boxes: Dict[str, QCheckBox] = {}
self.field_outputs: Dict[str, QTextEdit] = {}
@ -373,10 +374,10 @@ class RambleDialog(QDialog):
}
self._set_busy(True, "Generating...")
worker = GenWorker(self.provider, payload)
worker.signals.finished.connect(self._on_generated)
worker.signals.error.connect(self._on_gen_error)
self.thread_pool.start(worker)
self._active_worker = GenWorker(self.provider, payload)
self._active_worker.signals.finished.connect(self._on_generated)
self._active_worker.signals.error.connect(self._on_gen_error)
self.thread_pool.start(self._active_worker)
def _on_generated(self, data: Dict[str, Any]):
new_fields: Dict[str, str] = data.get("fields", {})
@ -428,6 +429,15 @@ class RambleDialog(QDialog):
self.result = RambleResult(summary=summary, fields=out_fields)
self.accept()
def closeEvent(self, event):
"""Wait for background workers to finish before closing."""
self.thread_pool.waitForDone(1000) # Wait up to 1 second
# Clean up worker reference to prevent Qt warning
if self._active_worker is not None:
self._active_worker.signals.deleteLater()
self._active_worker = None
super().closeEvent(event)
def open_ramble_dialog(
*,