{"id":7090,"library":"cmeel-console-bridge","title":"cmeel-console-bridge","description":"cmeel-console-bridge is a cmeel distribution for `console-bridge`, a ROS-independent C++ logging package. It provides logging calls that mirror those found in `rosconsole` but for applications that do not necessarily use ROS. This package is currently at version 1.0.2.3 and receives regular updates.","status":"active","version":"1.0.2.3","language":"en","source_language":"en","source_url":"https://github.com/cmake-wheel/cmeel-console-bridge","tags":["logging","c++ bindings","cmake","ros-independent"],"install":[{"cmd":"pip install cmeel-console-bridge","lang":"bash","label":"Install latest version"}],"dependencies":[],"imports":[{"note":"cmeel-console-bridge exposes logging functions directly under the `console_bridge` module, not through Python's standard `logging` module. It mirrors `rosconsole`'s API (e.g., logDebug, logInform, logWarn, logError).","wrong":"import logging\nlogging.info(\"Hello from standard logging!\")","symbol":"logInform","correct":"import console_bridge\nconsole_bridge.logInform(\"Hello from console_bridge!\")"},{"note":"Similar to logInform, other log levels like debug, warn, and error are exposed as direct functions.","symbol":"logDebug","correct":"import console_bridge\nconsole_bridge.logDebug(\"Debugging info.\")"}],"quickstart":{"code":"import console_bridge\n\n# Set the logging level (optional, default might be INFO or higher)\n# console_bridge.setLogLevel(console_bridge.CONSOLE_BRIDGE_LOG_DEBUG)\n\nconsole_bridge.logDebug(\"This is a debug message.\")\nconsole_bridge.logInform(\"This is an informational message.\")\nconsole_bridge.logWarn(\"This is a warning message.\")\nconsole_bridge.logError(\"This is an error message.\")\n\n# Example of using format strings, similar to C-style printf\nname = \"World\"\nvalue = 42\nconsole_bridge.logInform(\"Hello, %s! The answer is %d.\", name, value)\n","lang":"python","description":"This quickstart demonstrates how to import `console_bridge` and use its primary logging functions (`logDebug`, `logInform`, `logWarn`, `logError`) to output messages. The logging levels mirror those found in `rosconsole`. Note the use of C-style format strings for message interpolation."},"warnings":[{"fix":"Use `console_bridge.logInform(...)`, `console_bridge.logDebug(...)` etc., instead of `logging.info(...)` or `logging.debug(...)`. Pass arguments for formatting directly, similar to C-style `printf`.","message":"Direct exposure of C++ logging functions: Unlike standard Python logging, `cmeel-console-bridge` exposes C++-style logging functions (e.g., `logInform`, `logDebug`) directly within the `console_bridge` module. It does not integrate with Python's built-in `logging` module.","severity":"gotcha","affected_versions":"All versions"},{"fix":"Ensure your environment uses Python 3.8 or newer. Upgrade Python if necessary (`python -m pip install --upgrade pip` is also recommended for optimal wheel handling).","message":"Python 3.8 is the minimum required version. Older Python environments will fail installation.","severity":"breaking","affected_versions":"<=1.0.2.3"},{"fix":"For common platforms, binary wheels are usually available. If building from source, ensure you have a C++ compiler (e.g., `build-essential` on Debian/Ubuntu, Xcode on macOS, Visual Studio on Windows) and CMake installed. Consult `cmeel` documentation for advanced build-time environment variables if issues persist.","message":"Source installation requires C++ compilers and CMake: If a pre-built wheel is not available for your specific platform and Python version, `pip` will attempt to build from source. This requires a C++ compiler (e.g., GCC, MSVC) and CMake to be installed and correctly configured in your environment.","severity":"gotcha","affected_versions":"All versions"}],"env_vars":null,"last_verified":"2026-04-16T00:00:00.000Z","next_check":"2026-07-15T00:00:00.000Z","problems":[{"fix":"Ensure the package is installed in the active environment: `pip install cmeel-console-bridge`. If you're using virtual environments, activate the correct one. If the issue persists, try reinstalling with `--no-cache-dir`.","cause":"The `cmeel-console-bridge` package was either not installed, or the Python environment where it was installed is not active. Sometimes, `pip` might report success but the installation is corrupted, or a `cmeel.pth` file issue.","error":"ModuleNotFoundError: No module named 'console_bridge'"},{"fix":"Install a C++ compiler for your operating system. For Debian/Ubuntu, run `sudo apt-get update && sudo apt-get install build-essential cmake`. For macOS, install Xcode Command Line Tools (`xcode-select --install`). For Windows, install Visual Studio with C++ build tools.","cause":"During installation, `pip` attempted to build `cmeel-console-bridge` from source because a pre-built wheel was not found for your system. This error indicates that a C++ compiler (like GCC or Clang) is missing or not detectable by CMake.","error":"CMake Error at CMakeLists.txt:2 (project): No CMAKE_C_COMPILER could be found."}]}