Error "TypeError: unorderable types: int() > str()" When Trying to Create Packing Slip

Greetings Everyone, I’m facing this issue where if i submit a packing slip with a value for fields “From Package No.” and “To Package No.” like the following:
From Package No.:1
To Package No.:2 (or any other number other than empty.
it gives me the following message

My understanding is that these values determine how many copies of the packing slip will be printed and it will indicate that for exmaple “Shipment 1 out of 2”. I might be doing something wrong due to my misunderstanding of the function or this might be a bug. Your help and assistance is highly appreciated.

Update: this is the error log from the server log files:

Traceback (most recent call last):
File “/home/frappe/frappe-bench/apps/frappe/frappe/desk/form/”, line 22, in savedocs
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 271, in save
return self._save(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 307, in _save
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 886, in run_before_save_methods
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 786, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 1055, in composer
return composed(self, method, *args, **kwargs)
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 1038, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/home/frappe/frappe-bench/apps/frappe/frappe/model/”, line 780, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/packing_slip/”, line 25, in validate
File “/home/frappe/frappe-bench/apps/erpnext/erpnext/stock/doctype/packing_slip/”, line 52, in validate_case_nos
elif self.from_case_no > self.to_case_no:
TypeError: unorderable types: int() > str()

Thanks for reporting this, a PR proposed fix is pending fix: Error "TypeError: unorderable types: int() > str()" When Trying … by clarkejj · Pull Request #18913 · frappe/erpnext · GitHub

1 Like

Excellent the system is working thanks for the like!

Brilliant. Great job guys.