Page MenuHomePhabricator

Landscape View in Edit Mode not possible: TypeError: can't redefine non-configurable property "SetCookie"
Closed, DuplicatePublicBUG REPORT

Description

List of steps to reproduce (step by step, including full links if applicable):

What happens?:

  • no "landscape" textare, right side blocked
  • JS Console:
Uncaught TypeError: can't redefine non-configurable property "SetCookie"
 deprecate jQuery
    <anonymous> https://wikisource.org/w/index.php?title=MediaWiki:Base.js&action=raw&ctype=text/javascript:62

What should have happened instead?:

  • landscape textare

Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc:

Event Timeline

Samwilson subscribed.

I think this might be a duplicate of T297339, but could you add a screenshot of what you're seeing just so we can be sure? Thanks!

screen_ws_verticalview.png (670×1 px, 580 KB)

screens_landscapeview.png (723×1 px, 368 KB)

vertical view is ok,
landscape view is broken (independent from browser)

Aklapper renamed this task from Wikisource DE: Landcape View in Edit Mode not possible to Landscape View in Edit Mode not possible: TypeError: can't redefine non-configurable property "SetCookie".Dec 10 2021, 9:31 AM

this was temporarily resolved, now it is faulty again .... does that depend on a certain cookie or a setting?

my stemporarily solution is $('.prp-page-image').css('display','none'); in {user}/global.js -> maybe it will help someone...

...

Based on that error message it smells like a namespace collision. deWS has a lot of site-local JS that uses (and defines) a "SetCookie" function. That's a pretty generic name for such a function, so it may well be clashing with a name from elsewhere (e.g. the recent OSD stuff).

@Paulis @THE_IT I think perhaps you'd be best placed to look into this.

I have seen (and I think commented on) the SetCookie error at deWS before. I do not think it's related, it's just log spam from some collision in some other gadgetry. I'm pretty sure this is just a dupe of T297338 which, though it was fixed in a matter of hours, is still pending merge.

I renamed all occurrences of SetCookie to a more narrow naming. So the error in the console is not there anymore. Nevertheless, the error is still there. I also checked on English Wikisource, there is the same error, so I also guess this is a duplicate of T297338.