{"id":23384,"library":"bullet","title":"Bullet","description":"Bullet is a beautiful Python prompt library for building interactive command-line interfaces with lists, checkboxes, input prompts, and yes/no confirmations. It supports emoji, colors, and custom indicators. Current version: 2.2.0. Release cadence: low (last release was in 2020).","status":"maintenance","version":"2.2.0","language":"python","source_language":"en","source_url":"https://github.com/Mckinsey666/bullets","tags":["interactive","cli","prompt","terminal","menus"],"install":[{"cmd":"pip install bullet","lang":"bash","label":"PyPI"}],"dependencies":[{"reason":"Optional: used for saving/loading config in older versions, not required for basic usage.","package":"pyyaml","optional":true}],"imports":[{"note":"Correct modern import path.","symbol":"Bullet","correct":"from bullet import Bullet"},{"note":"For multi-select checklists.","symbol":"Check","correct":"from bullet import Check"},{"note":"For yes/no prompts.","symbol":"YesNo","correct":"from bullet import YesNo"},{"note":"For free-text input.","symbol":"Input","correct":"from bullet import Input"},{"note":"Used for styling (foreground, background, etc.).","symbol":"colors","correct":"from bullet import colors"},{"note":"For scrolling long lists.","symbol":"ScrollBar","correct":"from bullet import ScrollBar"},{"note":"There is no 'client' module; do not import from bullet.client.","wrong":"from bullet import client","symbol":"client"},{"note":"Old users sometimes try 'from bullet import bullet' (lowercase) which doesn't work.","wrong":"from bullet import Bullet as Bullet","symbol":"Bullet (class)"}],"quickstart":{"code":"from bullet import Bullet, colors\n\ncli = Bullet(\n    prompt=\"Choose a color: \",\n    choices=[\"red\", \"green\", \"blue\"],\n    indent=0,\n    align=5,\n    margin=2,\n    bullet=\"➡️\",\n    bullet_color=colors.bright(colors.foreground[\"cyan\"]),\n    word_color=colors.bright(colors.foreground[\"white\"]),\n    word_on_switch=colors.bright(colors.foreground[\"green\"]),\n    background_color=colors.background[\"black\"]\n)\nresult = cli.launch()\nprint(f\"You picked {result}\")","lang":"python","description":"Basic single-select prompt with custom styling."},"warnings":[{"fix":"Run the script from a terminal (cmd, bash) – not the IDE's built-in console.","message":"Bullet uses carriage returns to render over the same lines; it does NOT work inside IDEs (PyCharm, VS Code terminal) that don't support raw terminal mode. Run scripts directly in a real terminal.","severity":"gotcha","affected_versions":"all"},{"fix":"Wrap the prompt in a try/finally block or use context managers. The library itself restores terminal on normal exit, but not on unhandled exceptions.","message":"The library sets the terminal to raw mode (no line buffering, no echo). If your script crashes without cleanup, your terminal might be left in a broken state (no echo, weird keys).","severity":"gotcha","affected_versions":"all"},{"fix":"Use simple ASCII symbols if you need to support legacy terminals. Set bullet='▸' or similar.","message":"Unicode/emoji characters may not render correctly on all terminals (especially Windows cmd with chcp 437). The bullet character defaults to a simple '> ' if the chosen character is not supported.","severity":"gotcha","affected_versions":"all"},{"fix":"Consider alternatives like 'questionary', 'pick', 'PyInquirer', or 'enquirer' for newer Pythons.","message":"The library is no longer actively maintained; last release was in 2020. Issues and pull requests are rarely addressed. Use with caution for new projects.","severity":"gotcha","affected_versions":"2.x"}],"env_vars":null,"last_verified":"2026-05-01T00:00:00.000Z","next_check":"2026-07-30T00:00:00.000Z","problems":[{"fix":"Run: pip install bullet","cause":"Library not installed.","error":"ModuleNotFoundError: No module named 'bullet'"},{"fix":"Check the documentation for correct parameters: Bullet(prompt, choices, ...). Do not use 'params'.","cause":"Using outdated or mistyped constructor arguments.","error":"TypeError: __init__() got an unexpected keyword argument 'params'"},{"fix":"Use: from bullet import Bullet","cause":"Importing incorrectly. There is no 'bullet.Bullet' because 'bullet' is the package, not a module inside it.","error":"AttributeError: module 'bullet' has no attribute 'Bullet'"},{"fix":"Pass a list of strings, or define a class with __str__ method if custom objects are needed.","cause":"Using raw strings vs. custom choice objects incorrectly. The choices parameter expects strings or custom objects with __str__.","error":"ValueError: The truth value of a Choice is ambiguous"}],"ecosystem":"pypi","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}