Did I find the right examples for you? yes no

All Samples(1)  |  Call(0)  |  Derive(0)  |  Import(1)

        def output_xml(govts, cabs):

   govts_out = []
   for g in govts:
      cab = cabs[g[0]]

      psts_out = []
      for pos in cab:

         msts_out = []
         for mst in cab[pos]:
            msts_out.append(tmpl_minister.strip() % mst)
         txt = concat(msts_out)

         psts_out.append(tmpl_position % (pos, txt))

      txt = concat(psts_out)

      g_begin = g[-5].strftime("%d.%m.%Y")
      g_end = "" if not g[-4] else g[-4].strftime("%d.%m.%Y")
      govts_out.append(tmpl_government % (g[0],g[-2],g[-3], g[1], g_begin, g_end, txt))

   txt = concat(govts_out)
   return tmpl_main.strip() % txt
        


src/v/a/valtioneuvosto_scraper-0.9/valtioneuvosto_scraper/__init__.py   valtioneuvosto_scraper(Download)
from scraping import parse_governments, parse_cabinet
from util import parse_date, output_xml