Please note that spart is a user-oriented partition info command for slurm.
Slurm has a lot of tools they mainly administrator friendly. But, Slurm does not have a command showing partition info in a user-friendly way. So, please do not modify code to targetting administration purposes.
Also, Please Keep It Simple!
Thanks.