Bug reports, feature ideas, documentation fixes and pull requests are all welcome.
- Code of Conduct
- Reporting Bugs
- Suggesting Features
- Setting Up the Dev Environment
- Project Structure
- Making a Pull Request
- Style Guidelines
Be respectful. Everyone contributing here is doing so voluntarily. Constructive criticism is welcome; personal attacks are not.
Check the Issues page first.
A useful report includes:
- OS and version
- Python version (
python --version) - pip version (
pip --version) - Cokpyt version (shown in Settings)
- Steps to reproduce
- What you expected, and what happened
- Console output — hit copy in the console header, or open Settings → View the log
Open an issue with a [Feature] prefix. Describe the problem you are trying to solve, and how the
feature would address it. Screenshots and references to how other tools do it help.
| Tool | Version |
|---|---|
| Go | 1.23 or later |
| Wails CLI | v3 |
| Node.js | 20 or later (Vite 8) |
Install the Wails v3 CLI:
go install github.com/wailsapp/wails/v3/cmd/wails3@latestwails3 task deps installs the frontend's npm packages; wails3 build and wails3 dev do it for
you.
git clone https://github.com/d3uceY/Cokpyt.git
cd Cokpyt
# Rebuild and rerun on every Go change
wails3 devOther commands you will want:
wails3 task test # build the frontend, then go test ./...
wails3 task build # regenerate bindings, build the frontend, then build Go
wails3 task run # run the binary that is already built
wails3 task frontend # Vite dev server on its ownwails3 build # current OS
wails3 package # NSIS installer on Windows, .app bundle on macOSCross-compiling is a matter of setting GOOS and GOARCH. The Linux and macOS builds need
CGO_ENABLED=1 and a platform toolchain; the Windows build does not.
Cokpyt/
main.go -- Entry point: Wails options, window, service registration
app.go -- The service the frontend calls; the whole API surface
backend/
environments/ -- Finds every Python environment on the machine
env.go -- The Env type, and how a command runs against it
discover.go -- The launcher, install directories, and the marker sweep
pip/ -- Package operations, PyPI search, doctor, cleanup, history
platform/ -- OS-specific process handling
frontend/
index.html -- The Vite entry point
vite.config.js -- React plugin, dev-server port, asset layout
package.json -- React, Vite, and the two npm scripts
src/
main.jsx -- Mounts the providers and the app
App.jsx -- Hash router, layout, and the page outlet
api.js -- Wrapper over the generated bindings
app/
AppProvider.jsx -- Environments, operation record, theme (useReducer)
DataProvider.jsx -- The cached, expensive reads
DialogProvider.jsx -- The one dialog that can be open
ToastProvider.jsx -- The toast list and its timers
hooks.js -- usePackages, useOutdated, useHistory, useRunning
useResource.js -- One async read, keyed and refetchable
routes.js -- The page table the sidebar and router share
components/ -- Sidebar, page head, status bar, toasts, tables
pages/ -- One component per page
ui/ -- Design-system primitives
lib/ -- Pure helpers: formatting, environment, operations
styles/app.css -- The design system
public/assets/ -- Fonts, logos, and the icon sprite
bindings/ -- GENERATED by `wails3 generate bindings`. Do not edit.
dist/ -- GENERATED by `vite build`. Embedded by main.go.
build/
Taskfile.yml -- Shared build steps; per-platform Taskfiles sit beside it
config.yml -- App metadata and dev-mode settings
scripts/
fetch-icons.ps1 -- Regenerates frontend/public/assets/icons.svg
A public method on App is callable from the frontend with no wiring beyond regenerating the
bindings. Run wails3 task bindings, or just wails3 task compile, after changing Go signatures.
- Fork the repo and create a branch from
main:git checkout -b fix/your-branch-name
- Make your changes and make sure the project still builds (
wails3 build). - If you changed frontend code, make sure it builds, and add or update a Go test for any
non-trivial logic you touched:
wails3 task test # builds the frontend, then runs go test ./...
- Commit with a message describing what changed and why.
- Push your branch and open a pull request against
main, linking related issues.
Keep pull requests focused. One fix or feature per PR.
Go
- Follow standard Go formatting. Run
gofmtbefore committing. - Return errors, do not panic in library code.
- Comments explain why, especially where a decision looks odd. Two examples worth reading before
you touch them: why the discovery sweep has no depth limit, and why
collapsefolds launcher shims onto their target interpreter. - Non-trivial logic leaves one runnable check behind. Table-driven tests with real-world input are preferred over fixtures.
React
- Function components and hooks. The only dependencies are React, Vite, and the plugin that compiles JSX; do not add a component library, a router, or a state manager for what is here.
- User-supplied strings are rendered as text, never as markup.
- State is React state. Anything shared lives in a provider under
src/app/and is read with a hook; there is no module-level mutable state and no manual subscription mechanism. - A page renders its own
PageShellso its subtitle and actions can follow its state. Reads go throughuseResource(or theusePackages/useOutdated/useHistoryhooks), which own loading, errors, and the refetch after an operation. useEffectowns every side effect — the runtime event subscriptions, the timers, the fetches — and returns its cleanup, so StrictMode's double mount does not leave anything behind.- Comments explain why, in the same voice as the Go.
CSS
app.cssis the design system. The rules are: square corners, 1px borders, uppercase micro-labels at 10px with wide tracking, one accent colour (#0048ad) that means "this is the action", and no decoration that does not carry information.- Everything is a token in
:root. A dark value belongs in the[data-theme="dark"]block, not in a media query. - Do not introduce a UI library or an icon font. The icons are a ~11 KB SVG sprite; regenerate it
with
scripts/fetch-icons.ps1.
Open an issue or a discussion on the GitHub repo.