[Wikitech-l] ERR_INVALID_REQ when trying upload a file with API
Hi, when I try to upload a file with the API (Request: http://toolserver.org/~jan/files/APIUploadREQError.txt), I get the following error: Request: [unknown method] [no URL], from via amssq35.esams.wikimedia.org (squid/2.7.STABLE7) to [unknown host] ([unknown]) Error: ERR_INVALID_REQ, errno [No Error] at Sun, 02 Jan 2011 09:43:01 GMT Can you help me? Best regards, Jan ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] Deprecating content_actions
On 11-01-01 09:10 PM, jida...@jidanni.org wrote: > Well OK, just hope none of what I wrote breaks. > > function JidanniLessRedContentActions($sktemplate,$content_actions){ >//Besides Monobook, (our target), this even also gets run by Vector skin > but doesn\'t affect it apparently 11/2010 >if(array_key_exists('talk', > $content_actions)&&'new'==$content_actions['talk']['class']&& > > !$sktemplate->mTitle->quickUserCan('createtalk')){unset($content_actions['talk'],$content_actions['watch']);} >if(array_key_exists('nstab-category',$content_actions)&&'selected > new'==$content_actions['nstab-category']['class']){ > $content_actions['nstab-category']['class']='selected';} >return true;} > $wgHooks['SkinTemplateTabs'][]='JidanniLessRedContentActions'; //Bug 17963 > function JidanniLessRedContentActionsVectorTypeSkins($sktemplate,$links){ >if(isset($links['namespaces'])&& > is_array($links['namespaces'])&& > !$sktemplate->mTitle->quickUserCan('createtalk')){ > foreach(array_keys($links['namespaces']) as $ns){ >if(strpos($ns,'talk')!==false){ > if(isset($links['namespaces'][$ns]['class'])&& > 'new'==$links['namespaces'][$ns]['class']){ >unset($links['namespaces'][$ns]);}}} > > if(isset($links['actions']['watch'])){unset($links['actions']['watch']);}} >if(isset($links['namespaces']['category']['class'])&& > 'selected new'==$links['namespaces']['category']['class']){ > $links['namespaces']['category']['class']='selected';} >return true;} > $wgHooks['SkinTemplateNavigation'][]='JidanniLessRedContentActionsVectorTypeSkins'; > > Maybe I can even remove the first function soon. That code is a mess... but as long as you have that second hook things will work. Monobook and other skins will use the first hook and Vector will use the second up to 1.17, in 1.18 all skins will use the second hook. I would suggest not depending on the exact order and equality of class strings, it's possible that future code changes may add new classes or change the order of those. My code changes might affect your 'watch' use in that code, don't know if that's a good thing or not. Previously Vector built the watch tab conditionally based on the use watch icon setting. If it was enabled watch ended up inside views instead of actions. Now the watch tab is 'always' put into actions... vector relocates it to views and turns the icon on afterwards if that feature is enabled. And yes, in 1.17 and before SkinTemplateTabs is run in vector but ignored... that's because it's SkinTemplate that runs it, so all of our normal skins run it whether they use it to build tabs or not. It's not really anything special if you look over SkinTemplate... SkinTemplate basically preloads whatever QuickTemplate based template you have with a bunch of skin keys with data and then executes the template... it doesn't build them on demand or anything. ~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://daniel.friesen.name] ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
[Wikitech-l] SpecialPages and Related users and titles
The way you completely lose your page tabs when switching to Special:MovePage has been a bother to me for awhile... it's bad interface design to have a set of tabs linking to other pages with the same set of tabs, but to have a single one of them strangely point to a page where those tabs completely disappear. 1.18 has a new feature now. From a special page you can call $skin->setRelatedTitle and $skin->setRelatedTitle. Calling setRelatedTitle will mark a title as relevant to the current page, doing so will cause some parts of the ui (namely the page tabs) to display things relevant to that page. Calling setRelatedUser likewise will cause some parts of the ui (namely the toolbox) to display things that they would display if you were on the user's userpage. These methods are currently used by Special:MovePage (title), Special:Undelete (title), Special:Contributions (user), and Special:BlockIp (user). If you have another special page you feel is relevant enough to use these methods feel free to tweak it's code. -- ~Daniel Friesen (Dantman, Nadir-Seen-Fire) [http://daniel.friesen.name] ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] WYSIWTF working demo
- Original Message - > From: "Mathias Schindler" > On Sat, Jan 1, 2011 at 4:49 PM, Jay Ashworth wrote: > > Some people -- you can include me in this -- *actively* hate WYSIWYG > > editing, > > my comment was in no way about the pros and cons of WYSIWYG editing > and the decision at Wikimedia to have its own turing complete language > for content. My comment was about this demonstrator which should have > a huge selection bias of non-haters :) > > I reject the WYSIWYG concept itself much less then I dislike the > effects it has on humans who start to "make things look nice". Oh: you were suggesting that *his demonstrator* not show the plaintext edit tabs. Well, remember that those looking at it to evaluate it will *also* note that they're missing; this will have an effect on people's perceptions one way or the other, even though it's not a production implementation. My apologies for misunderstanding you, and for sounding like Get Offa My Lawn Guy, something I have to guard against increasingly as I dive into my forties. :-) Cheers, -- jra ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] What would be a perfect wiki syntax? (Re: WYSIWYG)
- Original Message - > From: "lampak" > I've been following the discussion and as I can see it's already > become rather unproductive*. So I hope my cutting in will not be very much > out of place (even if I don't really know what I'm talking about). > > Many people here has stated the main reason why a WYSIWYG editor is > not feasible is the current wikitext syntax. > > What's actually wrong with it? Oh god! *Run*! :-) This has been done a dozen times in the last 5 years, lampak. The short version, as much as *I* am displeased with the fact that we'll never have *bold*, /italic/ and _underscore_, is that the installed base, both of articles and editors, means that Mediawikitext will never change. It *might* be possible to *extend* it, but that requires that at least one of the 94 projects to write a formally defined parser for it, in something resembling yacc, would have to complete -- and to my knowledge, none has done so. Cheers, -- jra ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
[Wikitech-l] en.wiki dump status
according to http://dumps.wikimedia.org/backup-index.html the last dump was 2010-11-10 04:30:28 is that page broken or are dumps still halted? ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] ERR_INVALID_REQ when trying upload a file with API
Jan Luca wrote: > when I try to upload a file with the API (Request: > http://toolserver.org/~jan/files/APIUploadREQError.txt), I get the following > error: > > Request: [unknown method] [no URL], from via > amssq35.esams.wikimedia.org (squid/2.7.STABLE7) to [unknown host] > ([unknown]) > Error: ERR_INVALID_REQ, errno [No Error] at Sun, 02 Jan 2011 09:43:01 GMT You should file a bug at https://bugzilla.wikimedia.org/ Be sure to include the exact file name if the problem occurs with only one specific file. I didn't see the file name in the text file you linked; I assume it comes from $url, which isn't defined in that text file. Or better, attach a copy of the problematic file to the bug report if you think it's appropriate to do so. More specificity about what program/script/tool you're using to try to upload the file might be helpful as well. MZMcBride ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] SpecialPages and Related users and titles
Daniel Friesen wrote: > 1.18 has a new feature now. From a special page you can call > $skin->setRelatedTitle and $skin->setRelatedTitle. Calling > setRelatedTitle will mark a title as relevant to the current page, doing > so will cause some parts of the ui (namely the page tabs) to display > things relevant to that page. Calling setRelatedUser likewise will cause > some parts of the ui (namely the toolbox) to display things that they > would display if you were on the user's userpage. These methods are > currently used by Special:MovePage (title), Special:Undelete (title), > Special:Contributions (user), and Special:BlockIp (user). If you have > another special page you feel is relevant enough to use these methods > feel free to tweak it's code. If you remember to in the future, please include links to the specific code revisions you're referring to. This helps people understand what you're talking about and comment on the revisions as appropriate without having to hunt. I assume you're referring to these revisions: * http://www.mediawiki.org/wiki/Special:Code/MediaWiki/79398 * http://www.mediawiki.org/wiki/Special:Code/MediaWiki/79399 It looks like a nice usability fix. :-) (Now to get Special:MovePage turned into ?action=move) MZMcBride ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l
Re: [Wikitech-l] ERR_INVALID_REQ when trying upload a file with API
This request is part of the CommonsHelper2 tool. The complete source code is available under https://svn.toolserver.org/svnroot/p_commonshelper2/truck/. This special request is the method upload() in the upload_class.php. Best regards, Jan -Ursprüngliche Nachricht- Von: wikitech-l-boun...@lists.wikimedia.org [mailto:wikitech-l-boun...@lists.wikimedia.org] Im Auftrag von MZMcBride Gesendet: Montag, 3. Januar 2011 06:17 An: Wikimedia developers Betreff: Re: [Wikitech-l] ERR_INVALID_REQ when trying upload a file with API Jan Luca wrote: > when I try to upload a file with the API (Request: > http://toolserver.org/~jan/files/APIUploadREQError.txt), I get the following > error: > > Request: [unknown method] [no URL], from via > amssq35.esams.wikimedia.org (squid/2.7.STABLE7) to [unknown host] > ([unknown]) > Error: ERR_INVALID_REQ, errno [No Error] at Sun, 02 Jan 2011 09:43:01 GMT You should file a bug at https://bugzilla.wikimedia.org/ Be sure to include the exact file name if the problem occurs with only one specific file. I didn't see the file name in the text file you linked; I assume it comes from $url, which isn't defined in that text file. Or better, attach a copy of the problematic file to the bug report if you think it's appropriate to do so. More specificity about what program/script/tool you're using to try to upload the file might be helpful as well. MZMcBride ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l ___ Wikitech-l mailing list Wikitech-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/wikitech-l