Skip to content

Commit

Permalink
Fixed bug with mixing data types.
Browse files Browse the repository at this point in the history
  • Loading branch information
MicahGale committed Nov 2, 2024
1 parent e542ac5 commit 6f04bc7
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions montepy/errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ def __init__(self, input, message, error_queue):
_print_input(
path,
start_line,
error,
error["message"],
line_no,
input,
token,
Expand All @@ -83,7 +83,7 @@ def __init__(self, input, message, error_queue):
def _print_input(
path,
start_line,
error,
error_msg,
line_no=0,
input=None,
token=None,
Expand All @@ -105,7 +105,7 @@ def _print_input(
buffer.append(f" {start_line + i:5g}| {line}")
if base_message:
buffer.append(base_message)
buffer.append(error.args[0])
buffer.append(error_msg)
return "\n".join(buffer)


Expand Down Expand Up @@ -243,7 +243,7 @@ def add_line_number_to_exception(error, broken_robot):
lineno = input_obj.line_number
file = str(input_obj.input_file)
lines = input_obj.input_lines
message = _print_input(file, lineno, error, input=input_obj)
message = _print_input(file, lineno, message, input=input_obj)
except Exception as e:
try:
message = (
Expand Down

0 comments on commit 6f04bc7

Please sign in to comment.