GeshiNode and revisions

Scott Reynolds - January 25, 2009 - 01:32
Project:GeSHi Filter for syntax highlighting
Version:6.x-1.1
Component:Code
Category:bug report
Priority:critical
Assigned:Unassigned
Status:closed
Description

You had the right idea only your schema definition didn't allow for this to work. Instead of having the table with a primary key of NID it should have been vid. Furthermore, your NID shouldn't be serial, it is a foreign key with the node table, thus that one is serial and it should just be an int.

Here is the patch for D6

AttachmentSizeStatusTest resultOperations
geshinode.patch882 bytesIgnoredNoneNone

#1

soxofaan - May 29, 2009 - 15:26
Priority:normal» critical
Status:needs review» needs work

Thanks for pointing this out

I think #476606: GeSHi node bombed when editing a source code node with a new node revision is a sign of this error
I will look into this when I have more time

About the patch: I think there is also need for a geshi_node_update _N() function to update existing tables.

#2

Scott Reynolds - May 29, 2009 - 16:31

sure the update function is drop primary key add primary key.

edit: and change the db column type by removing autoincrement, whatchma call it on postgres

#3

emjayess - May 29, 2009 - 21:28

just attaching the screenshot I took for the duplicate ticket I created in #476606 mentioned above.

AttachmentSizeStatusTest resultOperations
geshinode_node-revision_errors.png79.85 KBIgnoredNoneNone

#4

soxofaan - July 6, 2009 - 22:47
Status:needs work» fixed

should be fixed by
http://drupal.org/cvs?commit=234318
(also includes upgrade path)

#5

System Message - July 20, 2009 - 22:50
Status:fixed» closed

Automatically closed -- issue fixed for 2 weeks with no activity.

#6

drecute - January 31, 2010 - 10:31

I noticed that whenever I edit a node that contains a Geshifilter source code node and hit save, the formatting of the Geshifilter source code node goes off(I mean breaks and returns just normal HTML). This means to me that the Geshifilter source code node does not remember the state it was before the node edit. So it tries to rewrite what has already been saved which tends to break the code.

I believe this problem has to do with revisions, that's why I am reporting it here.

 
 

Drupal is a registered trademark of Dries Buytaert.