Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add note about mpdecimal requirement on some Unix platforms #108

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions src/rp2/rp2_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,13 @@ def _rp2_main_internal(country: AbstractCountry) -> None: # pylint: disable=too

_setup_paths(parser=parser, configuration_file=args.configuration_file, input_file=args.input_file, output_dir=args.output_dir)

# On certain platforms the mpdecimal system library is missing (see details at: https://github.com/eprbell/rp2/issues/25).
try:
eprbell marked this conversation as resolved.
Show resolved Hide resolved
import _decimal as _ # pylint: disable=import-outside-toplevel
except ImportError:
LOGGER.error("The `mpdecimal` library is a required system dependency for RP2, but Python was not able to locate it.")
sys.exit(1)

try:
LOGGER.info("Country: %s", country.country_iso_code)
LOGGER.info("Generation Language: %s", args.generation_language)
Expand Down
Loading