#NEWLINE# def strftime( dt , fmt ) : #NEWLINE# #INDENT# if ( dt . year >= 1900 ) : #NEWLINE# #INDENT# return super ( type ( dt ) , dt ) . strftime ( fmt ) #NEWLINE# #UNINDENT# illegal_formatting = _illegal_formatting . search ( fmt ) #NEWLINE# if illegal_formatting : #NEWLINE# #INDENT# raise TypeError ( ( 'strftime of dates before 1900 does not handle' + illegal_formatting . group ( 0 ) ) ) #NEWLINE# #UNINDENT# year = year . year #NEWLINE# delta = ( 2000 - year ) #NEWLINE# off = ( 6 * ( ( delta // 100 ) + ( delta // 400 ) ) ) #NEWLINE# year = ( year + off ) #NEWLINE# year = ( year + ( ( ( 2000 - year ) // 28 ) * 28 ) ) #NEWLINE# timetuple = dt . timetuple ( ) #NEWLINE# s1 = time . strftime ( fmt , ( ( year , ) + timetuple [ 1 : ] ) ) #NEWLINE# sites1 = _findall ( s1 , str ( year ) ) #NEWLINE# s2 = time . strftime ( fmt , ( ( ( year + 28 ) , ) + timetuple [ 1 : ] ) ) #NEWLINE# sites2 = _findall ( s2 , str ( ( year + 28 ) ) ) #NEWLINE# sites = [ ] #NEWLINE# for site in sites1 : #NEWLINE# #INDENT# if ( site in sites2 ) : #NEWLINE# #INDENT# sites . append ( site ) #NEWLINE# #UNINDENT# #UNINDENT# s = s1 #NEWLINE# syear = ( '%04d' % ( dt . year , ) ) #NEWLINE# for site in sites : #NEWLINE# #INDENT# s = ( ( s [ : site ] + syear ) + s [ ( site + 4 ) : ] ) #NEWLINE# #UNINDENT# return s