python fiscal year prior

import fiscalyear

fiscalyear.START_MONTH = 7

targetFiscalYear = fiscalyear.FiscalYear.current()  
# returns: FY2022 Type: FiscalYear
intTargetFiscalYear = fiscalyear.FiscalYear.current().fiscal_year 
# returns: 2022 Type: int
prevFiscalYear = fiscalyear.FiscalYear.current().prev_fiscal_year  
# returns: FY2021 Type: FiscalYear
intPrevFiscalYear = fiscalyear.FiscalYear.current().prev_fiscal_year.fiscal_year 
# returns: 2021 Type: int

Here is what the above code is Doing:
1. Setting the start month to July
2. Getting the current fiscal year
3. Getting the previous fiscal year
4. Getting the integer value of the current fiscal year
5. Getting the integer value of the previous fiscal year