Closed (fixed)
Project:
Drupal core
Version:
x.y.z
Component:
comment.module
Priority:
Critical
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
30 Oct 2005 at 12:05 UTC
Updated:
25 Dec 2005 at 13:41 UTC
Jump to comment: Most recent file
Comments
Comment #1
asimmonds commentedI will place this on hold until my defines patch in http://drupal.org/node/34295 is committed (or rejected outright). IMO it's too confusing to work on comment without some defines() in there.
Comment #2
asimmonds commentedMore work in progress on this, I'd say it's nearly done (That's if i'm on the right track)
Comment #3
asimmonds commentedOK, I'm going to open this up for review...
Comment #4
asimmonds commentedRe-roll for current HEAD
Comment #5
webchickPatch applies cleanly. I've tried creating/editing/deleting comments, replying to other comments, and futzing around in the admin options screens and haven't run across any problems.
+1, especially as chx tells me this is critical to getting the RC out.
Comment #6
webchickChanging status.
Comment #7
chx commentedBumping priority (I already mailed Dries, but still).
Comment #8
dries commentedCommitted to HEAD. Thanks.
Comment #9
asimmonds commentedI used #post_process in my patch, which is now #after_build.
1 line patch to update comment.module.
Comment #10
dries commentedCommitted to HEAD. Thanks.
Comment #11
asimmonds commentedThird try...
I've made a number of screwups and incorrect assumptions with this issue, at the moment, comment is a little broken, patch attached to fix some bugs but I don't think I have all the bugs that are related to this conversion.
Patch attempts to fix:
http://drupal.org/node/38850
http://drupal.org/node/38852
http://drupal.org/node/38864
Comment #12
Wesley Tanaka commentedI dislike immensely the fact that editing a comment automatically updates its timestamp. In a flat display forum, this would cause the comments to be displayed out of order if one of them got edited (which would be extraordinarily confusing). I must say that I like the strategy (not necessarily the code) taken in http://drupal.org/node/38864 a lot better -- namely if a field doesn't need touching, don't try to touch it.
I see the advantages of modifying the update as follows:
For these reasons, I am reopening bug 38864, as I believe that patch should be applied in preference to the approach taken here.
Comment #13
Wesley Tanaka commentedThe code maintenance effect can be seen in the current proposed patch in this bug.
According to http://drupal.org/node/38864#comment-56558:
It seems that the current patch possibly hasn't addressed 'format' or 'name'. With the patch in http://drupal.org/node/38864
these would get handled automatically.
Comment #14
asimmonds commentedwtanaka:
You sound like you know what you want, and are more experienced with this than I am, so do you want to deal with these comment bugs? (Other project commitments are pending)
Comment #15
Stefan Nagtegaal commentedSome little nitpicking:
Looks nicer if we do:
Comment #16
chx commentedComment #17
dries commentedPlease adhere to the Drupal 4.6 behavior.
Comment #18
Wesley Tanaka commentedAt Dries's request, I am going to:
> attempt to fix the other outstanding issues that
> I've found with the comment module and submit a patch
> corresponding to the comment.module that's running on my live site.
I'm attaching the patch that I'm currently running with at the moment, in case anyone's interested.
There's some site-specific hacks in the first hunk of the patch (some things not being themeable in hook_block), but if you take those out, the things which have been fixed are:
1) blank subjects get replaced with the first part of the body of the comment when the comment is posted
2) updates to the comment don't touch fields that aren't set in the form. (fixes http://drupal.org/node/38864)
3) #comment-form anchor added back into the page.
The things that I still plan to add to the patch are:
1) I don't know if this patch does "blank subject replacement" for the preview, since I didn't think about it when I created the patch. I'm going to confirm one way or other and fix if necessary.
2) http://drupal.org/node/38944 -- if it turns out to be a problem in comment.module
It would also be nice if these other comment related issues get fixed:
1) http://drupal.org/node/38845 (comments disabled by default -- includes patch)
Comment #19
chx commentedplease do not include site specific stuff.
Comment #20
Wesley Tanaka commentedCurrent state of my site. Still need to check on the preview thing.
Comment #21
Wesley Tanaka commentedPreview gets subject properly added as well.
Comment #22
killes@www.drop.org commentedI don't think we want to put in another permission for the current release cycle. Can you please make a patch that only fixes the problem at hand?
Comment #23
chx commentedReally sorry, I do not like the sqlparts thing. It's hard to read. I think a switch statement would be more apt. I do not think there is another thing like that in Drupal core.
Comment #24
Wesley Tanaka commentedAs far as the extra permission, I'll advocate for something along those lines as being necessary for drupal's forums to be used on any forum where the site administrator is not acting as the forum moderator, or where there are several forum moderators.
As far as the switch statement, i don't see how a switch statement could get the same effect, without some kind of exponential combination explosion. As far as other examples in Drupal core, I seem to remember
user_load()doing something similar.Comment #25
Wesley Tanaka commentedA proposal:
1. immediately switch this task to "fixed," since the conversion mentioned in the title is actually complete (but has introduced some regression bugs)
2. split the patch (after upgrading it to apply cleanly against HEAD) into as many mini-patches as possible, such that each mini-patch is conceptually coherent.
3. post the url of each new mini-patch issue here for posterity
This allows the mini-patches that people like to get committed quickly, and the other mini-patches that people don't like to languish in the bug system unobtrusively.
Comment #26
Wesley Tanaka commentedImplementing step 1 of comment #25
Comment #27
Wesley Tanaka commentedhttp://drupal.org/node/40752
Comment #28
Wesley Tanaka commentedhttp://drupal.org/node/40753
Comment #29
Wesley Tanaka commentedhttp://drupal.org/node/40754
Comment #30
Wesley Tanaka commentedhttp://drupal.org/node/40755
Comment #31
Wesley Tanaka commentedhttp://drupal.org/node/40758
Comment #32
Wesley Tanaka commentedhttp://drupal.org/node/40760
Comment #33
Wesley Tanaka commentedhttp://drupal.org/node/40761
Comment #34
Wesley Tanaka commentedhttp://drupal.org/node/40762
Comment #35
Wesley Tanaka commentedThat's it. I also just confirmed that the split up patches, combined, get me all the fixes.
Comment #36
(not verified) commented