Page MenuHomePhabricator

Clicking on images for lightbox won't load with Persistent Chat enabled
Closed, ResolvedPublic

Description

Steps:

  • Maniphest
  • Create Task
  • Drag/Drop an image to the task
  • Create New Task
  • Now try to click on the image you attached.

Result:
When you click on a media attachment the Media preview is not triggered. Nothing happens. And if you refresh the page, the url has changed to the url of the image.
The same result happens if you click on a media attachment in Phriction.

Version info:
phabricator 5efbf4d74aa72c5a7d7f161ea8c5aa33ac0e3189 (Sat, Oct 22)
arcanist e17fe43ca3fe6dc6dd0b5ce056f56310ea1d3d51 (Sat, Oct 22)
phutil 20841d2321275c87ff8718422868ef6b1beb16c4 (Sat, Oct 22)

Reproduced on Win 7 with
Chrome 54.0.2840.71 m
Firefox 49.0.2

Event Timeline

epriestley added a subscriber: epriestley.

I can't reproduce this by following the steps you describe. Here's a screenshot of this working properly for me:

We need to be able to reproduce this before we can resolve it.

Next steps:

  • provide additional information so we can reproduce the issue (see Providing Reproduction Steps); or
  • we'll close this report after a few days if we're still unable to reproduce the issue.

Hah, I found out what triggered the error on our installation.

If I enable "Persistent Chat", then media preview does not work.
If I disable "Persistent Chat", then media preview works as expected.

This coincides with our experience that media preview used to work some weeks ago.

chad added a subscriber: chad.Oct 25 2016, 3:14 PM

Can you reproduce that on this server? Offhand I cannot, but "Persistent Chat" is Quicksand based, so it make be dependent on a certain way you navigate. Quicksand is an ajax layer we use to build full pages.

chad added a comment.Oct 25 2016, 3:25 PM

@rphl @samr can you confirm if your users were using "Persistent Chat" when they encountered this? I'm trying to find a repro with that but haven't quite yet. It is plausible given the magical nature of Quicksand.

samr added a comment.Oct 25 2016, 3:28 PM

@chad
YES! Thank god

chad added a comment.Oct 25 2016, 3:31 PM

Are there errors in the javascript console? I have persistent chat always on, using Mac/Chrome - and haven't ran into this here on this server. Can you reproduce here? A specific task or diff?

samr added a comment.Oct 25 2016, 3:33 PM

@chad when persistent chat is open here the preview works fine. We also use Mac/Chrome.

@chad I cannot reproduce the issue on this server.

Added note, I just reproduced the issue on a Mac/Safari client of our instance. And the Javascript Console does not come up with any errors/warnings or anything.

chad added a comment.Oct 25 2016, 5:38 PM

I'm not finding anything magical that triggers the error at least against this server or my test server. Are you all running notification servers?

Yes we are. I can try to stop the notification server tomorrow, will see if that makes any difference.

I tried stopping aphlict notification server. Stopping it has no effect, the issue still reproduces if I have Persistent Chat enabled.

rphl added a comment.Oct 31 2016, 10:52 AM

Our users can confirm this behavior. With active persistent chat, the Lightbox is not working. If it is disabled, its working as expected.

chad added a comment.Oct 31 2016, 1:40 PM

Our users can confirm this behavior. With active persistent chat, the Lightbox is not working. If it is disabled, its working as expected.

Based on these steps, we cannot reproduce the issue and this bug still cannot move forward. Does anyone have any additional steps or environmental details we can use to build a reproduction case?

chad added a comment.Oct 31 2016, 1:48 PM
This comment was removed by chad.

Could phabricator.base-uri setting affect this? Our install is accessed via http://phab.domain.com:port/.

OCram added a comment.Nov 16 2016, 6:33 PM

Ran into this too.

OCram awarded a token.Nov 16 2016, 6:33 PM
chad renamed this task from Clicking on a media does not trigger preview, refreshing the page now loads url of media to Clicking on images for lightbox won't load with Persistent Chat enabled.Nov 16 2016, 6:33 PM
OCram added a comment.Nov 16 2016, 6:43 PM

@flippingtables: Do you access to your phabrictor intance through a loadbalancer?

chad added a comment.Nov 16 2016, 6:46 PM

I think it's a race condition with quicksand

chad added a comment.Nov 16 2016, 6:50 PM

I'll generate a best guess patch later today.

epriestley claimed this task.

This reproduces somewhat-reliably for me with Quicksand (Persistent Chat) on.

(This likely would not be reproducible on any instance which has security.alternate-file-domain configured, which is why it wouldn't reproduce here or in the Phacility cluster.)

I'm reasonably sure that fixes it; let us know if you're still seeing issues after updating.

chad awarded a token.Nov 17 2016, 3:02 AM
OCram added a comment.Nov 17 2016, 6:29 AM

Well, I do not have configured the security,alternate-file-domain.
But it works now for me with this fix :D
Macro parrot:

Oh, sorry, I meant: if security.alternate-file-domain was configured, that prevented this problem.

We recommend configuring this value, so both this install and Phacility instances have it configured. Thus, the problem did not reproduce here or on Phacility instances.