Last modified: 2014-11-17 10:34:49 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T35355, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 33355 - Provide interface for gadget usage statistics
Provide interface for gadget usage statistics
Status: NEW
Product: MediaWiki
Classification: Unclassified
Special pages (Other open bugs)
unspecified
All All
: Normal enhancement with 1 vote (vote)
: ---
Assigned To: Nobody - You can work on this!
: javascript
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-12-23 20:22 UTC by Helder
Modified: 2014-11-17 10:34 UTC (History)
7 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Helder 2011-12-23 20:22:44 UTC
I'm opening this bug because I agree with what is requested at bug 32858: the JS and CSS pages should NOT be parsed as if they were normal "wiki pages" (at least NOT by default, i.e., only if the user opted in for such wiki-parsing). If someone fix that bug, though, the users who create user scripts will have no other hack to track the (crosswiki) usage of their code, and won't be able to notify users about possibly breaking changes in new versions of some JS code.

As you can check on [[commons:Special:WhatLinksHere/Template:GlobalJsUsage]], some people also use fake [[File:UserName UserScript.js]] pages to be able to get a list from [[Special:GlobalUsage]] for the associated scripts (see also Bug 1886)

MediaWiki needs a proper way to deal with tracking user scripts.
Comment 1 Sam Reed (reedy) 2011-12-24 16:36:05 UTC
RL2/the gadgets rewrite should fix a lot of this...
Comment 2 Phillip Patriakeas 2011-12-24 17:00:15 UTC
(In reply to comment #1)
> RL2/the gadgets rewrite should fix a lot of this...

Would that also work for JS/CSS files in userspace and the Project: namespace?
Comment 3 Krinkle 2011-12-27 02:23:24 UTC
 (In reply to comment #1)
> RL2/the gadgets rewrite should fix a lot of this...

Well, it makes it redundant to have to update import-calls as the gadget will be centrally stored. But we don't yet provide a way to see how many people have certain gadgets enabled. This info is available in the database, but not in an efficient way (major wikis make weekly dumps of this from the Toolserver on a wiki page like https://commons.wikimedia.org/wiki/Commons:Database_reports/User_preferences#Gadgets )

(In reply to comment #2)
> (In reply to comment #1)
> > RL2/the gadgets rewrite should fix a lot of this...
> 
> Would that also work for JS/CSS files in userspace and the Project: namespace?

No, and we don't have to in my opinion. Right now the habbit is for script to be copied and pasted or live-imported on load time from one user or wiki to another. That causes two needs:
* Being able to track usage so that in case of changes, they can be updated
* Statistics, how many people are using X

The goal is to remove that habbit, and instead have people write much more as gadgets, which allows re-use of code and asynchronous loading with other modules as well as much better internationalization and an easier for the users (no need to dive into code but just ticking checkboxes on Special:Preferences). 

Both of these needs are still valid though.
the first one is redundant by using Gadgets since then code is stored and loaded from 1 central location, removing the need for updates.

The statistics is something we should still think about. For now the Wikimedia wiki's can do with database report bots, but ideally we'd have something like this in core or in an extension.
Comment 4 Krinkle 2011-12-27 02:24:34 UTC
Renaming bug summary to aim for fixing the need for the way scripts are encourages to be written today and in the future, not the way they were being written up to last year.
Comment 5 Phillip Patriakeas 2011-12-27 04:16:43 UTC
Unless something has changed since my involvement decreased, at least on the English Wikipedia, there's a pretty big barrier (of inertia if nothing else) to getting new gadgets added - I really can't see gadgets becoming the preferred method of creating userscripts unless and until that is changed. Until that happens (and even after, for quite some time, given the extant body of non-gadget scripts), we still need some method of tracking script usage.
Comment 6 Krinkle 2011-12-27 21:50:55 UTC
(In reply to comment #5)
> Unless something has changed since my involvement decreased, at least on the
> English Wikipedia, there's a pretty big barrier (of inertia if nothing else) to
> getting new gadgets added - I really can't see gadgets becoming the preferred
> method of creating userscripts unless and until that is changed. Until that
> happens (and even after, for quite some time, given the extant body of
> non-gadget scripts), we still need some method of tracking script usage.

Well, if we're talking about a new feature. Then I don't think there's a need
to support user scripts (if that's possible in a good way at all).

If you're referring to /* [[links]] */ and Special:WhatLinksHere.. well, I'd say keep
using that until gadgets are the common way for creating scripts.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links