Incompatibility bug for 1.1

Matej Cepl <[email protected]>
Newsgroups gmane.comp.web.pyblosxom.user
Organization Northeastern University, Boston, MA
Message-ID <[email protected]>
Hi,

while trying to make weblogsping plugin working I found out that there is
IMHO a bug in Pyblosxom 1.1 Pyblosxom/entries/fileentry.py.

--- fileentry.py 2005/03/30 23:43:56 1.1
+++ fileentry.py 2005/03/30 23:43:16
@@ -103,7 +103,8 @@
         if absolute_path == '':
             file_path = fn
         else:
-            file_path = '/'.join((absolute_path.rstrip('/'), fn))
+            file_path = os.path.join(absolute_path,fn)
 
         tb_id = '%s/%s' % (absolute_path, fn)
         tb_id = re.sub(r'[^A-Za-z0-9]', '_', tb_id)

rstrip function in 2.1.3 doesn't support having _any_ parameters. Moreover,
this complicated construct is totally useless, because we have (since
forever) os.path.join function which does exactly the same in compatible
and stable manner.

Thanks,

 Matěj

-- 
Matej Cepl, http://www.ceplovi.cz/matej
GPG Finger: 89EF 4BC6 288A BF43 1BAB  25C3 E09F EF25 D964 84AC
138 Highland Ave. #10, Somerville, Ma 02143, (617) 623-1488
 
He inherited some good instincts from his Quaker forebears, but
by diligent hard work, he overcame them.
      -- James Reston
         (about Richard Nixon)



-------------------------------------------------------
This SF.net email is sponsored by Demarc:
A global provider of Threat Management Solutions.
Download our HomeAdmin security software for free today!
http://www.demarc.com/Info/Sentarus/hamr30
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.