The full messages are:

Notice: Trying to get property of non-object in views_handler_field_comment_link->render_link() (line 53 of /srv/bindings/0862171661d147198205074c99c1e38e/code/profiles/panopoly/modules/contrib/views/modules/comment/views_handler_field_comment_link.inc).
Notice: Trying to get property of non-object in views_handler_field_comment_link->render_link() (line 52 of /srv/bindings/0862171661d147198205074c99c1e38e/code/profiles/panopoly/modules/contrib/views/modules/comment/views_handler_field_comment_link.inc).

This looks like it's erroring for every field that is being pulled from a comment.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

esmerel’s picture

Quick transcription of what merlinofchaos said.

This is trying to read the NID and the CID out of the comment unconditionally so it notices out if there's no comments, and it's trying to get some values twice and ignoring one, etc.

marcel.jtf’s picture

I got exactly the same problem when doing the following

  • enabling the view "Recent comment" and editing the block
  • add the relationship "Comment: Author" so I can display the user picture
  • removed the title
  • add user picture
  • add some body tekst
  • add a read more link

I removed the "read more" link to solve the problem

xbrianx’s picture

I am getting this issue. I don't have a read more link in my view so not sure how to fix it. The relationship set up is a little complicated so it sounds like something that #1 is mentioning.

xbrianx’s picture

I seemed to have fixed this issue by checking of the box that says 'require this relationship'

brad.bulger’s picture

Issue summary: View changes
Status: Active » Needs review
FileSize
1.47 KB

the handler files for the comment view link weren't allowing for the absence of a comment.

Chris Matthews’s picture

Status: Needs review » Needs work
Issue tags: +Needs reroll

The 4 year old patch in #5 to views_handler_field_comment_link.inc and views_handler_field_comment_link_edit.inc does not apply to the latest views 7.x-3.x-dev and if still relevant needs to be rerolled.

Checking patch modules/comment/views_handler_field_comment_link.inc...
error: while searching for:

  function render_link($data, $values) {
    $text = !empty($this->options['text']) ? $this->options['text'] : t('view');
    $comment = $this->get_value($values);
    $nid = $comment->nid;
    $cid = $comment->cid;

    $this->options['alter']['make_link'] = TRUE;
    $this->options['alter']['html'] = TRUE;

error: patch failed: modules/comment/views_handler_field_comment_link.inc:48
error: modules/comment/views_handler_field_comment_link.inc: patch does not apply
Checking patch modules/comment/views_handler_field_comment_link_edit.inc...
error: while searching for:
    parent::render_link($data, $values);
    // ensure user has access to edit this comment.
    $comment = $this->get_value($values);
    if (!comment_access('edit', $comment)) {
      return;
    }

error: patch failed: modules/comment/views_handler_field_comment_link_edit.inc:34
error: modules/comment/views_handler_field_comment_link_edit.inc: patch does not apply
drupal_josh’s picture

Not sure what happened. Patch is shown above.
https://www.drupal.org/files/issues/2019-02-01/1816960-add-safety-checks...

Just adds some safety checks. Admin comments view was throwing quite a bit of errors.

drupal_josh’s picture

Added some safety checks. Was getting a lot of php notices on the admin comment view.

brad.bulger’s picture

The patch file from 7 applied to current 3.x code line.

brad.bulger’s picture

Status: Needs work » Needs review
rpayanm’s picture

Issue tags: -Needs reroll