Giter VIP home page Giter VIP logo

plone.app.discussion's Introduction

Introduction

plone.app.discussion is the commenting system used since Plone 4.1. It was initially developed as part of the Google Summer of Code 2009 by Timo Stollenwerk (student) and Martin Aspeli (mentor).

Add-on Products

Note: not all of these may be compatible with the current version of plone.app.discussion and Plone itself.

Documentation

There is initial documentation but it is outdated. You will still get a feel for how the package is structured though.

Credits

  • Timo Stollenwerk
  • Martin Aspeli

Many thanks to:

  • Jon Stahl (for acting as "the customer" during GSoC)
  • David Glick (for technical expertise and advice during GSoC)
  • Lennart Regebro (for writing the portal_discussion tool and initial unit tests)
  • Carsten Senger (for fixing the comment z3c.form form and pizza)
  • Hanno Schlichting (for making p.a.d work with Zope 2.12)
  • Alan Hoey (for providing fixes)
  • Maik Roeder (for providing and setting up a buildbot)

plone.app.discussion's People

Contributors

avoinea avatar cekk avatar chaoflow avatar davisagli avatar eikichi18 avatar ericof avatar erral avatar esteele avatar gforcada avatar hannosch avatar ichim-david avatar instification avatar jensens avatar k-j-kleist avatar keul avatar ksuess avatar maartenkling avatar mauritsvanrees avatar naro avatar optilude avatar pbauer avatar pjstevns avatar pre-commit-ci[bot] avatar regebro avatar rpatterson avatar sneridagh avatar tdesvenain avatar tisto avatar vangheem avatar vincentfretin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

plone.app.discussion's Issues

Π‘lick Reply -> duplicate fields

Plone 5.0.3
plone.app.discussion = 2.4.10, 2.4.11

Steps

  1. Do not Log In.
  2. Create reply.
  3. Try to create a reply to a reply
  4. After clicking Reply, there are two fields for the answer instead of one:

dis 2016-03-15_17-31-05

Can not access `manage_access` as an admin

At work we recently upgraded from Plone 5.2.x to 6.0.7 and since then I noticed that I can not go to a comment's /manage_access ZMI view anymore (to check permissions and so on).

Testing it locally with a vanilla Plone instance seems to be the case as well:

Traceback (innermost last):

    Module ZPublisher.WSGIPublisher, line 181, in transaction_pubevents
    Module ZPublisher.WSGIPublisher, line 391, in publish_module
    Module ZPublisher.WSGIPublisher, line 285, in publish
    Module ZPublisher.mapply, line 98, in mapply
    Module ZPublisher.WSGIPublisher, line 68, in call_object
    Module OFS.role, line 112, in manage_access
    Module Shared.DC.Scripts.Bindings, line 333, in __call__
    Module Shared.DC.Scripts.Bindings, line 370, in _bindAndExec
    Module App.special_dtml, line 222, in _exec
    Module DocumentTemplate._DocumentTemplate, line 144, in render_blocks
    Module DocumentTemplate._DocumentTemplate, line 245, in render_blocks_
    Module DocumentTemplate.DT_With, line 86, in render
    Module DocumentTemplate._DocumentTemplate, line 144, in render_blocks
    Module DocumentTemplate._DocumentTemplate, line 222, in render_blocks_
    Module DocumentTemplate.DT_Util, line 215, in eval
    __traceback_info__: o
    Module <string>, line 1, in <module>
    Module AccessControl.ImplPython, line 766, in guarded_getattr
    Module AccessControl.ImplPython, line 708, in aq_validate
    Module AccessControl.ImplPython, line 596, in validate
    Module AccessControl.ImplPython, line 325, in validate
    Module AccessControl.ImplPython, line 845, in raiseVerbose

AccessControl.unauthorized.Unauthorized: The container has no security assertions.  Access to 'meta_type' of (plone.app.discussion.comment.Comment object at 0x7f2d1bb81f60 oid 0x4bf1 in (ZODB.Connection.Connection object at 0x7f2d25df8150)) denied.

It's the first time I see this security assertions problem together with this meta_type... any leads? πŸ€”

Posting comment without name breaks page for admin

When posting a comment without a name as anonymous, admin is no longer able to open the page:

AttributeError("'TTWViewletRenderer' object has no attribute 'name'",) (Also, the following error occurred while attempting to render the standard error message, please see the event log for full details: 'TTWViewletRenderer' object has no attribute 'name')

plone.app.discussion 2.2.18 on Plone 4.3.10

Button "Edit" not translated

"Edit" not translated (line 124 /browser/comments.pt)
2016-04-07_9-47-07

                          <!-- plone 5 will have auth_token available
                               so we'll use modal pattern -->
                          <a class="commentactionsform pat-plone-modal context"
                             tal:condition="auth_token"
                             tal:attributes="href string:${reply/absolute_url}/@@edit-comment?_authenticator=${auth_token}">Edit</a>

"form name="edit"" not used.
2016-04-07_9-55-01

Plone 5.0.3 , plone.app.discussion 2.4.11

Ajaxify comments viewlet?

what are the thoughts on ajaxifying the loading of comments within the viewlet?

pros:

  • better cacheability of pages

cons:

  • ?

It doesn't have to be the default, just a checkbox in the discussions control panel, that would enable it.

Any reason to not derive from CMFCatalogAware?

plone.app.discussion.comment.Comment derives from Products.CMFCore.CMFCatalogAware.CatalogAware and not from Products.CMFCore.CMFCatalogAware.CMFCatalogAware (note the CMF on the class).

Actually this CMF class is just a mixin of CatalogAware itself, WorkflowAware (which Comment derives from as well) and OpaqueItemManager (which Comment does not derive from).

This small difference is one of the problems that prevents collective.solr to index comments.

OTOH collective.solr could be updated to also allow objects that not only are instances of CMFCatalogAware but also from CatalogAware.

Migrating old Discussion Items failed in fact of a missing workflow state

While in-place migration using the @@comment-migration view to migrate from plone v4.1.5 to v4.2.5 the process of migrating discussion items fails, because there is no workflow state for the old items and None is given

p.a.discussion 2.1.9 is installed

The instance was installed by the UnifiedInstaller.

Traceback (innermost last):

Module ZPublisher.Publish, line 126, in publish
Module ZPublisher.mapply, line 77, in mapply
Module ZPublisher.Publish, line 46, in call_object
Module plone.app.discussion.browser.migration, line 205, in __call__
Module plone.app.discussion.browser.migration, line 124, in migrate_replies
AttributeError: 'NoneType' object has no attribute 'get'

Test failures with fresh Products.MailHost 4.11

Fixes for line endings were done in Products.MailHost 4.11. While a PR for that was being made, I tested its branch with a PR in coredev. All tests were green. It now looks as if I did not add Products.MailHost to the auto-checkouts, but I am pretty sure I did. Anyway, too late for that.

Since I updated coredev 5.2 to Products.MailHost 4.11, two tests in plone.app.discussion fail on Python 3

Errors for example on 3.6:

False is not true

  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 59, in testPartExecutor
    yield
  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 605, in run
    testMethod()
  File "/home/jenkins/.buildout/eggs/cp36m/plone.app.discussion-3.4.3-py3.6.egg/plone/app/discussion/tests/test_notifications.py", line 217, in test_notify_moderator
    in msg)
  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 682, in assertTrue
    raise self.failureException(msg)

and

False is not true

  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 59, in testPartExecutor
    yield
  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 605, in run
    testMethod()
  File "/home/jenkins/.buildout/eggs/cp36m/plone.app.discussion-3.4.3-py3.6.egg/plone/app/discussion/tests/test_notifications.py", line 75, in test_notify_user
    in msg)
  File "/srv/python3.6/lib/python3.6/unittest/case.py", line 682, in assertTrue
    raise self.failureException(msg)

I am looking into fixing it in the tests.

(re)move translations?

@erral you might know better than me πŸ€

While running codespell in this repository, oh surprise, the translations in i18n folder produce false positives.

While codespell does not ignore .po files by default, we have to find a solution.

But back to the point, are those translations there actually being used? πŸ€”

The only MessageFactory that is created is for plone:

plone/app/discussion/__init__.py:1:from zope.i18nmessageid import MessageFactory
plone/app/discussion/__init__.py:4:_ = MessageFactory("plone")

So the translations in the i18n could be removed or merged/migrated to plone.app.locales? πŸ€”

TIA! πŸ™‡πŸΎ

Update markup of templates to Bootstrap 5

Due to #2967 we have to update the markup of the templates listed below.

  • plone.app.discussion.browser.comments.pt
  • plone.app.discussion.browser.controlpanel.pt
  • plone.app.discussion.browser.moderation.pt

Feel free to add missing templates here. See also #3061 for further details. Check overrides in plonetheme.tokyo for already existing updated templates.

A view with already approved comments

A view with already approved comments would be nice. I'm interested to implement this. Any suggestion on this?

Additional Info: 'approved by'

Commenter | Date | In Response To | Comment | Approved by

Reply button missing in comments

I have installed Plone 5 with the unified installer 5.0.3 which comes with
plone.app.discussion-2.4.10-py2.7.egg

When I add a comment i am missing the Reply button. (this is a very usefult feature) Is there a way to enable it or is this a bug or has the Reply been removed?
Thanks for any help

Additional workflow state for spam comments

It would be nice for the moderator not being forced to approve or delete a comment but also being able to mark it as spam. With this additional workflow state a comment stays for reporting / documentation issues.
The moderation view needs to be extended by these spam comments. A filter for optional viewing all comments, only to be moderated comments, approved comments or spam comments would help moderating.

Incompatible with plone.app.iterate: all comments are gone after check-in

I am running Plone 4.3.7, with plone.app.discussion 2.2.15, and plone.app.iterate 2.1.13 pinned by Plone. If a content (my own custom Dexterity content type) has iterate (staging) enabled and it has comments, I got an error when I try to check-in the working copy, or try to cancel the checkout:
ERROR Zope.ZCatalog uncatalogObject unsuccessfully attempted to uncatalog an object with a uid of /Plone/stories/story-1/copy_of_chapter-one/++conversation++default/1459989773220166.

If I was just canceling the checkout, nothing bad happens apparently. But if I check-in the working copy, the updated original content will lose all the comments. The comments are still listed in portal_catalog, but no longer on the content page.

It looks like when check-in tries to delete the working copy, it tries to unindex the comment and gives above error. Any suggestion how to fix this? Thanks!

W3C CSS Validator error

The W3C CSS Validation Service found validation error relating to this product, in ++resource++plone.app.discussion.stylesheets/discussion.css

Error:
.template-discussion-settings .unclickable, Parse Error = 50

Publishing an already published comment via link of notification mail fails without helping message

A message like "this comment is published" would be helpful to moderator.
The error message is missleading.

Traceback (innermost last):
  Module ZPublisher.WSGIPublisher, line 155, in transaction_pubevents
  Module ZPublisher.WSGIPublisher, line 337, in publish_module
  Module ZPublisher.WSGIPublisher, line 255, in publish
  Module ZPublisher.mapply, line 85, in mapply
  Module ZPublisher.WSGIPublisher, line 61, in call_object
  Module plone.app.discussion.browser.moderation, line 215, in __call__
  Module Products.CMFCore.WorkflowTool, line 245, in doActionFor
WorkflowException: No workflow provides the '${action_id}' action.

delete_own_comment_enabled doesn't work

The option delete_own_comment_enabled doesn't work because the delete button is not showed.

The error is in the file comments.pt (line:113)
The condition canDelete is not necessary because there are the same conditions in the forms below.
Deleting this condition works fine to me.

Versions:
Plone: 6.0a1.dev0
plone.app.discussion: 4.0.0a1

Hope this helps

Initial Update

The bot created this issue to inform you that pyup.io has been set up on this repo.
Once you have closed it, the bot will open pull requests for updates as soon as they are available.

Issue installing plone.app.discussion = 2.4.20 on Plone 4

Hello,

I am trying to install plone.app.discussion on Plone 4 with Python 2.7 and pinning the add-on's version to 2.4.20

Updated my buildout as below.
eggs =
plone.app.discussion

[versions]
plone.app.discussion = 2.4.20

Now trying to run a new buildout
sudo -u plone_buildout bin/buildout

I am getting below error messages:

Updating zeoserver.
Updating client1.
Download error on https://download.zope.org/ppix/: hostname 'download.zope.org' doesn't match 'vm06.plyp.com' -- Some packages may not be found!
Download error on https://download.zope.org/distribution/: hostname 'download.zope.org' doesn't match 'vm06.plyp.com' -- Some packages may not be found!
Getting distribution for 'plone.app.discussion==2.4.20'.
While:
Updating client1.
Getting distribution for 'plone.app.discussion==2.4.20'.
Error: Couldn't find a distribution for 'plone.app.discussion==2.4.20'.

Please help me I want install this version on Plone.app.discussion.
Thanks in advance

Replace plone.api code

plone.app.discussion is using plone.api. This should not be done in core Plone code, to avoid circular dependencies.
This is only in browser/moderation.py.

In Plone 6, with only Products.CMFPlone and not Plone, the instance actually fails to start:

  File "/Users/maurits/shared-eggs/cp39/plone.app.discussion-4.0.0a2-py3.9.egg/plone/app/discussion/browser/moderation.py", line 6, in <module>
    from plone import api
  File "/Users/maurits/shared-eggs/cp39/plone.api-2.0.0a1-py3.9.egg/plone/api/__init__.py", line 7, in <module>
    from plone.api import relation
  File "/Users/maurits/shared-eggs/cp39/plone.api-2.0.0a1-py3.9.egg/plone/api/relation.py", line 10, in <module>
    from plone.app.iterate.dexterity import ITERATE_RELATION_NAME
zope.configuration.xmlconfig.ZopeXMLConfigurationError: File "/Users/maurits/shared-eggs/cp39/plone.app.discussion-4.0.0a2-py3.9.egg/plone/app/discussion/browser/configure.zcml", line 16.4-22.10
    File "/Users/maurits/tmp/test/parts/instance/etc/site.zcml", line 16.2-16.23
    File "/Users/maurits/shared-eggs/cp39/Products.CMFPlone-6.0.0a1.dev0-py3.9.egg/Products/CMFPlone/configure.zcml", line 16.2-16.44
    File "/Users/maurits/shared-eggs/cp39/plone.app.discussion-4.0.0a2-py3.9.egg/plone/app/discussion/configure.zcml", line 33.4-33.34
    ModuleNotFoundError: No module named 'plone.app.iterate'

That is also an issue in plone.api, which I will raise there.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.