rouge
rouge copied to clipboard
Python Syntax highlight breaks in diffs .
Rouge Python Language
Rouge Gem Version 3.26.0
Code sample A sample of the code that produces the bug.
def get_realtime_status_safety_input_data(self, cpuc_cpu_id):
"""
Get data from realtime status safety input field.
Arguments:
| Name | Description | M/O |
| cpuc_cpu_id | Subdevice ID for CPU | M |
Returns:
| Description |
| Dict |
Example of returned dictionary:
{
"C1": "122222222", ...
"H2": "0", ...
"S1": "-1"
}
"""
return self.iot_portal_handler.get_realtime_status_safety_input_data(cpuc_cpu_id)
def get_realtime_status_safety_input_data(self, cpuc_cpu_id):
"""
Get data from realtime status safety input field.
Arguments:
| Name | Description | M/O |
| cpuc_cpu_id | Subdevice ID for CPU | M |
Returns:
| Description |
| Dict |
Example of returned dictionary:
{
"C1": "122222222", ...
"H2": "0", ...
"S1": "-1"
}
"""
return self.iot_portal_handler.get_realtime_status_safety_input_data(cpuc_cpu_id)
def get_realtime_status_safety_input_data(self, cpuc_cpu_id):
"""
Get data from realtime status safety input field.
Arguments:
| Name | Description | M/O |
| cpuc_cpu_id | Subdevice ID for CPU | M |
Returns:
| Description |
| Dict |
Example of returned dictionary:
{
"C1": "122222222", ...
"H2": "0", ...
"S1": "-1"
}
"""
return self.iot_portal_handler.get_realtime_status_safety_input_data(cpuc_cpu_id)
Additional context Syntax highlight work incorrectly in code review diffs if diff snippet in itself is not syntactically correct. Examples attached.
Code Browser Screenshot attached:
Check differences in both the screenshots, the highlighting does not quite match in the diff, see e.g. the method name and the comment content
Is this Gitlab? They do some manual magic to get diff highlighting that we don't do in this project IIRC.