--- On Fri, 7/10/09, Aryeh Gregor <Simetrical+wikilist(a)gmail.com> wrote:
> From: Aryeh Gregor <Simetrical+wikilist(a)gmail.com>
> Subject: Re: [Wikitech-l] How do you run the parserTests?
> To: "Wikimedia developers" <wikitech-l(a)lists.wikimedia.org>
> Date: Friday, July 10, 2009, 1:51 PM
> On Fri, Jul 10, 2009 at 3:59 PM, dan
> nessett<dnessett(a)yahoo.com>
> wrote:
> >
> > I have been struggling to figure out how to run the
> parser tests. From the very limited documentation in the
> code, it appears you are supposed to run them from a
> terminal. However, when I cd to the maintenance directory
> and type "php parserTests.php" I get the following error
> message.
> >
> > Parse error: parse error, expecting `T_OLD_FUNCTION'
> or `T_FUNCTION' or `T_VAR' or `'}'' in
> /Users/dnessett/Sites/Mediawiki/maintenance/parserTests.inc
> on line 43
> >
> > Either there is some setup necessary that I haven't
> done; parserTests.php is not the appropriate "top-level"
> target for the execution; you are not supposed to run these
> tests from the terminal; or there is something else I am
> doing wrong.
>
> You're running them correctly. It sounds like your
> installation is
> broken. Please say exactly what version of MediaWiki
> you're using
> (from Special:Version), and make sure that parserTests.inc
> was
> correctly copied from the download. Paste line 43 and
> the surrounding
> lines here.
MediaWiki 1.14.0
PHP 5.2.6 (apache2handler)
MySQL 5.0.41
I am running this on my Macintosh using MAMP (http://www.mamp.info/en/index.html). parserTests.inc looks OK to me (but I don't know what to look for). Lines 28-48 are:
=====
$options = array( 'quick', 'color', 'quiet', 'help', 'show-output', 'record' );
$optionsWithArgs = array( 'regex', 'seed' );
require_once( 'commandLine.inc' );
require_once( "$IP/maintenance/parserTestsParserHook.php" );
require_once( "$IP/maintenance/parserTestsStaticParserHook.php" );
require_once( "$IP/maintenance/parserTestsParserTime.php" );
/**
* @ingroup Maintenance
*/
class ParserTest {
/**
* boolean $color whereas output should be colorized
*/
private $color;
/**
* boolean $showOutput Show test output
*/
private $showOutput;
=====
Dan
It occurred to me that you perhaps meant line 43 of parserTests.php. Here are lines 28-53 of it (like the previous message the blank line between ===== and teh code doesn't count in line numbering):
if( isset( $options['help'] ) ) {
echo <<<ENDS
MediaWiki $wgVersion parser test suite
Usage: php parserTests.php [options...]
Options:
--quick Suppress diff output of failed tests
--quiet Suppress notification of passed tests (shows only failed tests)
--show-output Show expected and actual output
--color[=yes|no] Override terminal detection and force color output on or off
use wgCommandLineDarkBg = true; if your term is dark
--regex Only run tests whose descriptions which match given regex
--file=<testfile> Run test cases from a custom file instead of parserTests.txt
--record Record tests in database
--compare Compare with recorded results, without updating the database.
--setversion When using --record, set the version string to use (useful
with git-svn so that you can get the exact revision)
--keep-uploads Re-use the same upload directory for each test, don't delete it
--fuzz Do a fuzz test instead of a normal test
--seed <n> Start the fuzz test from the specified seed
--help Show this help message
ENDS;
exit( 0 );
}
I am trying to automate uploading images (or files). We are currently using mediaWiki version 1.13.2.
I am using the following code:
$data=array( 'wpIgnoreWarning'=>'1',
'wpDestFile'=>="$bulkImageDirectory/$fname",
'wpReUpload'=>'1',
'wpUpload'=>'1',
'wpUploadFile'=>$fname,
);
$webrequest=new FauxRequest( $data, true );
$uploader=new UploadForm( $webrequest );
$uploader->mUploadSize=$zipfile['size'];
$uploader->mUploadTempName="$bulkImageDirectory/$fname";
$uploader->mOname=$fname;
$uploader->mSessionKey='1';
$uploader->processUpload();
$fname is a relative file name, while ="$bulkImageDirectory/$fname" is the absolute file name. The file is located in wiki/images/tmp/bulkImages/.
I receive the error: "The file you uploaded seems to be empty. This might be due to a typo in the file name. Please check whether you really want to upload this file." And the upload form displays on the screen with wpDestFile filled in.
Three questions:
Do you know what the problem is?
Is there another way to automatically upload a file within an extension?
Is there documentation on this?
Thanks,
Mary Beebe
Hi,
the Wikipedia information team [info-en(a)wikimedia.org] pointed me to
this mailing list to report a problem I found with the new mobile
wikipedia:
After having enjoyed mobile.wikipedia.org for quite some time I noticed
there is a new m.wikipedia.org availaible. I just tested it on my Nokia
E71 with Symbian web browser and found that the [Show] buttons that
should display an article's section just don't work - the sections are
never shown.
Regardless oft he non-functionality I would prefer the previous method
used on mobile.wikipedia.org: It loads smaller junks (tends to be
faster), provides a content listing, and works on any browser - but this
is only a personal preference.
Just wanted to let you know there is a problem lurking around.
Thanx for all your effort on all versions of wikipedia!
Have fun, Nik
I asked whatwg for ideas on how to make this just work for iPhone
users. The answer is sort of horrible. Any iPhone devs in the house?
- d.
---------- Forwarded message ----------
From: Ralph Giles <giles(a)xiph.org>
Date: 2009/7/9
Subject: Re: [whatwg] Serving up Theora <video> in the real world
To: David Gerard <dgerard(a)gmail.com>
Cc: WHATWG Proposals <whatwg(a)lists.whatwg.org>
On Thu, Jul 9, 2009 at 3:34 PM, David Gerard<dgerard(a)gmail.com> wrote:
> Anyone got ideas on the iPhone problem?
I think this is off topic, and I am not an iPhone developer, but:
Assuming the app store terms allow video players, it should be
possible to distribute some sort of dedicated player application, free
or otherwise. I believe the fee for a cert to sign applications is
currently $100/year.
However, the iPhone doesn't have a shared filesystem, or
helper-applications in the normal sense, At least not as far as I can
tell. The work-around I'm aware of is for site authors to check if
you're running on the iPhone in javascript, and rewrite the video
elements to normal anchors with a custom schema, e.g.
<a href="oggplayer://example.com/file.ogv">Click here to watch in
Ogg Player</a>.
Then, if the user has installed the Ogg Player app, which registers
itself has handling the 'oggplayer' schama, Safari will pass the
custom uri to it, and it can download/stream/whathaveyou.
-r
In the spirit of supplying concrete examples, here are my proposed
changes to the syntax of the existing language:
* the existing {{{parm}}} or {{{parm|default}}} notation should be
changed to ${parm} or ${parm|default}
* all newlines and other multiple whitespace characters within template
source code should be regarded as reduced to single spaces, with
explicit calls to {{newline}} and {{whitespace}} operators to generate
explicit whitespace on output
These two changes alone would greatly increase the readability of
templates, both by massively reducing the number of curly brackets
within templates, and by allowing them to be formatted in a clearly
nested and indented form.
If I could add one more change, it would be an {{apply}} function, to
allow explicit calls to other templates whose names have themselves been
generated by template substitution, as used extensively in templates
such as {{coord}}; this would help clean up the semantics of the
underlying language a bit more, allowing further changes to be made more
easily both to the syntax and implementation, and also possibly allowing
a faster implementation that does not require SNOBOL-like re-parsing of
generated text.
-- Neil
Thought this might be of interest to some of our folks in and around
Germany:
http://phpugmunich.org/dokuwiki/php_release_party
Wouldn't hurt to have a MediaWikian or two there to represent. :) It's
at a biergarten so you know I'd be there if I were local! ;)
-- brion vibber (brion @ wikimedia.org)
Меня мучает одна проблема, никак не получается создать копию википедии.
Прочел эту статью http://ru.wikipedia.org/wiki/Википедия:Как сделать копию
Википедии<http://ru.wikipedia.org/wiki/%D0%92%D0%B8%D0%BA%D0%B8%D0%BF%D0%B5%D0%B4%D0%…>
Скачал все выложенные файлы (ну не все, а для того языка, который мне нужен.
в данном случаи это узбекский uz.wikipedia.org) отсюда
http://download.wikimedia.org/uzwiki/20090708/
Сделал все по инструкции, но не получилось.
Что было:
1. Я залил все дампы базы и xml файлы так, как показано в выше приведенной
статье. И при выполнение команды T:\usr\local\Php\php.exe rebuildall.php
выдается ошибка (точно не помню какая).
2. Заново начал все, и залил только два файла: wikipedia-interwiki.sql и
ruwiki-20060202-pages-meta-current.xml
Уже при выполнение команды T:\usr\local\Php\php.exe rebuildall.php ошибки
нет как и контента. Разве что главная страница слегка стала похоже на
оригинал, есть фрагменты стилей и заголовки (подобное наблюдалось и в первом
варианте).
Можете ли мне помочь? Может я что то делаю не так? Или же есть другие более
надежные варианты создания копии вики?
Я еще читал, что можно создать бот. Можете и об этом рассказать?
Буду благодарень
--
Hurshid Soatqulov
s.hurshid(a)gmail.com
Another answer - it'd be "custom app" time.
So the question is: what do we tell iPhone users?
- d.
---------- Forwarded message ----------
From: Maciej Stachowiak <mjs(a)apple.com>
Date: 2009/7/10
Subject: Re: [whatwg] Serving up Theora <video> in the real world
To: David Gerard <dgerard(a)gmail.com>
Cc: WHATWG Proposals <whatwg(a)lists.whatwg.org>
On Jul 9, 2009, at 2:59 PM, David Gerard wrote:
> The question is what to do for platforms such as the iPhone, which
> doesn't even run Java.
>
> Is there any way to install an additional codec in the iPhone browser?
> Is it (even theoretically) possible to put a free app on the AppStore
> just to play Ogg Theora video for our users? (There are many AppStore
> apps that support Ogg Vorbis, don't know if any support Theora - so
> presumably AppStore stuff doesn't give Apple the feared submarine
> patent exposure.)
Just by way of factual information:
There's no Java in the iPhone version of Safari. There are no browser
plugins. There is no facility for systemwide codec plugins. There is
no way to get an App Store app to launch automatically from Web
content. I don't think there is any obstacle to posting an App Store
app that does nothing but play videos from WikiPedia, the way the
YouTube app plays YouTube videos. But I don't think there is a way to
integrate it with browsing.
Regards,
Maciej
I'm not an iPhone dev, but I've played around with
Android a bit and the situation is similar. We dont
have a shared filesystem between apps (Android
supports SD, I assume the iPhone does too), we can't
have helper applications either, and there's no real
plugin interface for the browser.
The proposed solution would probably work well on
Android too and tbh I don't think it's *that* terrible of
a workaround, given the platform restrictions and lack
of native support; I haven't looked heavily into Android
on this subject.
The only other option (which isn't available on the
iPhone due to Apple's stance on competing browsers)
would be to basically fork the browser app and add
Ogg support. Certainly doable in Android, although I'm
pretty sure that's a direction we want to go in (nor do
I want to maintain a fork of the Android browser :)
-Chad
On Jul 9, 2009 6:54 PM, "David Gerard" <dgerard(a)gmail.com> wrote:
I asked whatwg for ideas on how to make this just work for iPhone
users. The answer is sort of horrible. Any iPhone devs in the house?
- d.
---------- Forwarded message ----------
From: Ralph Giles <giles(a)xiph.org>
Date: 2009/7/9
Subject: Re: [whatwg] Serving up Theora <video> in the real world
To: David Gerard <dgerard(a)gmail.com>
Cc: WHATWG Proposals <whatwg(a)lists.whatwg.org>
On Thu, Jul 9, 2009 at 3:34 PM, David Gerard<dgerard(a)gmail.com> wrote:
> Anyone got ideas on the iPhone problem?
I think this is off topic, and I am not an iPhone developer, but:
Assuming the app store terms allow video players, it should be
possible to distribute some sort of dedicated player application, free
or otherwise. I believe the fee for a cert to sign applications is
currently $100/year.
However, the iPhone doesn't have a shared filesystem, or
helper-applications in the normal sense, At least not as far as I can
tell. The work-around I'm aware of is for site authors to check if
you're running on the iPhone in javascript, and rewrite the video
elements to normal anchors with a custom schema, e.g.
<a href="oggplayer://example.com/file.ogv">Click here to watch in
Ogg Player</a>.
Then, if the user has installed the Ogg Player app, which registers
itself has handling the 'oggplayer' schama, Safari will pass the
custom uri to it, and it can download/stream/whathaveyou.
-r
_______________________________________________
Wikitech-l mailing list
Wikitech-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l