FrenchFryZine / sitemap-generators

Automatically exported from code.google.com/p/sitemap-generators
0 stars 0 forks source link

Error writing sitemap_index file for WEB type sitemap #18

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Version of script: 1.5
OS: windows xp

I tried to generate a sitemap using the urllist method. 
When the script writes the sitemap_index file the following error occurs:

The Sitemap type is WEB Sitemap.
...
Writing index file "C:\tools\sitemapGenerator\sitemap\sitemap_index.xml"
with 2 Sitemaps
Traceback (most recent call last):
  File "sitemap_gen.py", line 2092, in ?
    sitemap.Generate()
  File "sitemap_gen.py", line 1665, in Generate
    self.WriteIndex()
  File "sitemap_gen.py", line 1810, in WriteIndex
    fd.write(sitemap_index_header)
UnboundLocalError: local variable 'sitemap_index_header' referenced before
assignment

There's an extra underscore when referencing the sitemap_index_header
variable in the WriteIndex method, line 1802. The line reads

sitemap__index_header = GENERAL_SITEMAP_HEADER
versus
sitemap_index_header = GENERAL_SITEMAP_HEADER

Thanks,
Leah

Original issue reported on code.google.com by leah.pod...@gmail.com on 11 Apr 2008 at 8:24

GoogleCodeExporter commented 8 years ago
I am having the same issue.

Original comment by advertis...@wholesalerscatalog.com on 17 Mar 2009 at 3:13

GoogleCodeExporter commented 8 years ago
Here is small patch for this or you can go to line 1802
and change sitemap__index_header to sitemap_index_header (remove one underscore)

Original comment by strufkin on 15 May 2009 at 9:45

Attachments: