MediaWiki is getting a new programming language

classic Classic list List threaded Threaded
109 messages Options
123456
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Judson Dunn-2
On Thu, Jul 2, 2009 at 9:11 PM, Steve Bennett<[hidden email]> wrote:
> Anyone know if the people who work with these templates are
> experienced coders, or just wikipedians who have gotten into it as a
> pleasant sunday afternoon mindfuck?
>

I've done a few, not as complex as that one. It's not that
complicated, it's just that the logic is all nested bracket based
things so it looks terrible and is hard to read. I would say I'm an
amateur coder. :)

A simple statement starts out ok, it's just the nesting that makes
them crazy, and {} brackets are used for almost everything.

{{#ifeq: string 1 | string 2 | value if true | value if false }} .

Also, when you pass variables in, those are often numbered, and they
are frequently in the if statements so you get {{{1}}} things, and you
want to use templates in them, which also use {{brackets}} So
everything is using brackets and nesting. The parser is magic. :)

I didn't mean to make it seem like I didn't like parserfunctions and
templates. They are amazing, and I think one of the coolest and most
innovative parts about mediawiki honestly.

They basically allow general users to create content methods on the
fly that can do a ton of work. I think they are instrumental in the
fast development of a lot of features that would have taken much
longer had the user had to explain their vision to a developer.

Templates and parserfunctions are one of the best examples of
transparency and editor agency on wikipedia.

Judson
http://en.wikipedia.org/wiki/User:Cohesion

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/3/2009 1:45:59 AM Pacific Daylight Time,
[hidden email] writes:


> Do you really think any of these would be a higher barrier for entry
> than the current template and parser-functions system?  Possibly the
> current system is more egalitarian only in that it is painful for
> those who do know how to program as well as those who don't.>>

My point is and was that whatever is used to replace the current system,
should be a language that is as English-like as possible.

What point are you responding to?  Perhaps it's one I never made.

Will Johnson




**************
Make your summer sizzle with fast and easy recipes for the
grill. (http://food.aol.com/grilling?ncid=emlcntusfood00000005)
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/3/2009 9:45:32 AM Pacific Daylight Time,
[hidden email] writes:


> Happily, it's not necessary that the *average* user be able to
> contribute to programming.  >>

--------------

Let me just point out that I never stated the above in the first place.  
The average user hasn't even figured out how to use the <ref> system, and
probably less than ten percent understand {templates} at all even to include
them, let alone to edit them.

So I would never advocate a system where the average person can do it.
Rather I would advocate a system which is as easy to use as we can make it.
 Not as hard as we can imagine it.

Will




**************
Make your summer sizzle with fast and easy recipes for the
grill. (http://food.aol.com/grilling?ncid=emlcntusfood00000005)
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Carcharoth
In reply to this post by Judson Dunn-2
On Fri, Jul 3, 2009 at 6:21 PM, Judson Dunn<[hidden email]> wrote:

<snip>

> {{#ifeq: string 1 | string 2 | value if true | value if false }} .

The help pages for templates are not very helpful.

Instinctively, and by looking at examples, I sort of know the above,
but I've never seen a help page that clearly explains how to use
templates and parser functions, let alone how to construct tables
(more a WYSIWYG problem). Maybe I've been looking at the wrong pages,
but if there are pages that clearly teach people how to construct
templates and tables, I'd really like to be pointed at them.

Carcharoth

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Aryeh Gregor
In reply to this post by WJhonson
On Fri, Jul 3, 2009 at 2:15 PM, <[hidden email]> wrote:
> Rather I would advocate a system which is as easy to use as we can make it.
>  Not as hard as we can imagine it.

I would recommend that the criterion used be "as easy as possible for
the community to maintain".  Languages that are harder for beginners
are in many cases easier to use in the long run.  Compare VB or PHP to
. . . any language people actually like.  :)

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

geni
In reply to this post by Carcharoth
2009/7/3 Carcharoth <[hidden email]>:

> On Fri, Jul 3, 2009 at 6:21 PM, Judson Dunn<[hidden email]> wrote:
>
> <snip>
>
>> {{#ifeq: string 1 | string 2 | value if true | value if false }} .
>
> The help pages for templates are not very helpful.
>
> Instinctively, and by looking at examples, I sort of know the above,
> but I've never seen a help page that clearly explains how to use
> templates and parser functions, let alone how to construct tables
> (more a WYSIWYG problem). Maybe I've been looking at the wrong pages,
> but if there are pages that clearly teach people how to construct
> templates and tables, I'd really like to be pointed at them.
>
> Carcharoth
>

Tables are an issue yes. I don't do much with templates but when I've
wanted to use ParserFunctions I've either copied and pasted or worked
from

http://www.mediawiki.org/wiki/Help:ParserFunctions

On the other hand the formal help page is a complete mess:

http://en.wikipedia.org/wiki/Help:Template



--
geni

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Matthew Brown-5
In reply to this post by WJhonson
On Fri, Jul 3, 2009 at 11:08 AM, <[hidden email]> wrote:
> My point is and was that whatever is used to replace the current system,
> should be a language that is as English-like as possible.

I think there's a substantial body of knowledge that shows that a
surface English-like-ness doesn't actually make programming easier or
more accessible; in fact, because a programming language never does
support more than a tiny bit of English syntax, it actually makes it
harder to remember what English syntactic constructions are meaningful
in the language when other, equivalent syntaxes do not work.

What does make it easier to learn and comprehend include factors like
a simple and clean syntax and an ease of accessing the functionality
that's useful in the problem domain.

English-like syntax seems to be better as a /sales/ feature than a
learning one; it seems, before actually trying to learn it, that it
should be simpler.

I'd believed that you were implying that a general purpose scripting
language would be worse in terms of comprehensibility and
accessibility than the current templates+parser-functions language,
and boggling at that, but perhaps I misinterpreted you there.

In my opinion, ANY of the suggested alternates would be better in a
quite substantial and meaningful way than what we currently have, for
both programmers and non-programmers.

On the other hand, that doesn't mean that some solutions would not be
preferable to others, even if any of them is better than what we have
right now.

If I misunderstood you, which I think was quite likely, my apologies!

-Matt

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

David Gerard-2
In reply to this post by Steve Bennett-8
2009/7/3 Steve Bennett <[hidden email]>:

> The thing I find astonishing is that people are willing to work with
> these templates and actually maintain them. I've coded regexes, tcl,
> sh, prolog, haskell, C..., but I have absolutely no desire to get this
> crap on my hands.
> Anyone know if the people who work with these templates are
> experienced coders, or just wikipedians who have gotten into it as a
> pleasant sunday afternoon mindfuck?


You mean, of course, [[Brainfuck]].

I'm wondering if we could do our templates in BANCstar.


- d.

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Steve Bennett-8
In reply to this post by WJhonson
On Sat, Jul 4, 2009 at 4:08 AM, <[hidden email]> wrote:
> My point is and was that whatever is used to replace the current system,
> should be a language that is as English-like as possible.

Your point is made, understood, and soundly rebutted. An
"english-like" language is not desirable, feasible, or going to
happen.

Steve

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/6/2009 12:12:15 AM Pacific Daylight Time,
[hidden email] writes:


> Your point is made, understood, and soundly rebutted. An
> "english-like" language is not desirable, feasible, or going to
> happen.>>

----------------------

I propose that A) you are not the authority invested in deciding this
issue; and B) your approach is overly antagonistic and confrontational.

Will




**************
Looking for love this summer? Find it now on AOL Personals.
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

Neil Harris-2
[hidden email] wrote:

> In a message dated 7/6/2009 12:12:15 AM Pacific Daylight Time,
> [hidden email] writes:
>
>
>  
>> Your point is made, understood, and soundly rebutted. An
>> "english-like" language is not desirable, feasible, or going to
>> happen.>>
>>    
>
> ----------------------
>
> I propose that A) you are not the authority invested in deciding this
> issue; and B) your approach is overly antagonistic and confrontational.
>
> Will
>
>  
Will,

Although the point could have been put more tactfully, I think the
salient point here is that "English-like" programming languages have
been tried before many times, and have (with the possible exception of
COBOL) consistently been rejected in favour of compact equation-like
languages.

Consider the difference between the ease of writing, say, the Python-like

  print "%02x" % find(":", param[1])

or even the Lisp-like

  (print (fmt "%02x" (find ":" (param 1))))

compared to writing an "English-like" equivalent such as

  PRINT THE NUMBER OF CHARACTERS BEFORE THE FIRST OCCURRENCE OF THE
COLON CHARACTER IN THE FIRST POSITIONAL PARAMETER FORMATTED AS A
TWO-DIGIT ZERO-PADDED HEXADECIMAL NUMBER USING LOWERCASE LETTERS FOR THE
HEX DIGITS A TO F

If you think this an unfair example, please could you show how your
proposed English-like language would handle this example better than the
above?

-- Neil




_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/6/2009 3:54:38 AM Pacific Daylight Time,
[hidden email] writes:


> Although the point could have been put more tactfully, I think the
> salient point here is that "English-like" programming languages have
> been tried before many times, and have (with the possible exception of
> COBOL) consistently been rejected in favour of compact equation-like
> languages.>>

-------------------------

Neil let me just point out in counter-point that the two longest-living
third-generation langages, COBOL and BASIC are both still alive and well.

Both use a most English-like foundation.


 Is Python more represented in want-ads ?  Most businesses still use older
generation languages, regardless of what is being taught in university.

Will Johnson




**************
Looking for love this summer? Find it now on AOL Personals.
(http://personals.aol.com/?ncid=emlcntuslove00000003)
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/6/2009 3:54:38 AM Pacific Daylight Time,
[hidden email] writes:


> PRINT THE NUMBER OF CHARACTERS BEFORE THE FIRST OCCURRENCE OF THE
> COLON CHARACTER IN THE FIRST POSITIONAL PARAMETER FORMATTED AS A
> TWO-DIGIT ZERO-PADDED HEXADECIMAL NUMBER USING LOWERCASE LETTERS FOR THE
> HEX DIGITS A TO F>>

-------------------------------------

You're being silly.
You know quite well that no language exists like this.

Will




**************
Looking for love this summer? Find it now on AOL Personals.
(http://personals.aol.com/?ncid=emlcntuslove00000003)
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

stevertigo-2
In reply to this post by WJhonson
On Mon, Jul 6, 2009 at 11:21 AM, <[hidden email]> wrote:

> Neil let me just point out in counter-point that the two longest-living
> third-generation langages, COBOL and BASIC are both still alive and well.
> Both use a most English-like foundation.
>  Is Python more represented in want-ads ?  Most businesses still use older
> generation languages, regardless of what is being taught in university.

Ball-and-chain legacy issues substantiate your argument?

Note my usage of "parasitic" earlier may have been a bit mistated - no
programming
language is really "parasitic" to any natural language, it just
borrows certain concepts
and words from it.

In reality I don't think anyone disagrees with your basic point. But
if you dislike Lua, Python,
etc. because they aren't similar enough to English, then usenet.tonal.clara's

-Steve

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

stevertigo-2
In reply to this post by WJhonson
Continued...
..if you dislike Lua, Python, etc. because they aren't similar enough
to English, then Neil's offering:  "PRINT THE NUMBER OF CHARACTERS
BEFORE THE FIRST OCCURRENCE OF THE
COLON CHARACTER IN THE..." makes the substantial point, in addition to
being esoterically funny.

-Steve

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

WJhonson
In reply to this post by Brian J Mingus
In a message dated 7/6/2009 11:46:18 AM Pacific Daylight Time,
[hidden email] writes:


> ..if you dislike Lua, Python, etc. because they aren't similar enough
> to English, then Neil's offering:  "PRINT THE NUMBER OF CHARACTERS
> BEFORE THE FIRST OCCURRENCE OF THE
> COLON CHARACTER IN THE..." makes the substantial point, in addition to
> being esoterically funny.>>
>

--------------

The reason BASIC was and still enjoys wide popularity is because it's
easier to learn.

The example does not make the substantial point because it veers so
strongly to the opposite end of the spectrum as to be unrelated to the argument
whatsoever.  I never suggested that a language should *mimic* English (or a
bizarre type of hyper-English).

I welcome however, anyone who wants to actually conduct this argument, on
Earth.

Will Johnson




**************
Looking for love this summer? Find it now on AOL Personals.
(http://personals.aol.com/?ncid=emlcntuslove00000003)
_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

stevertigo-2
In reply to this post by Neil Harris-2
On Mon, Jul 6, 2009 at 3:54 AM, Neil Harris<[hidden email]> wrote:

> Consider the difference between the ease of writing, say, the Python-like
>  print "%02x" % find(":", param[1])
> or even the Lisp-like
>  (print (fmt "%02x" (find ":" (param 1))))
> compared to writing an "English-like" equivalent such as
>  PRINT THE NUMBER OF CHARACTERS BEFORE THE FIRST OCCURRENCE OF THE
> COLON CHARACTER IN THE FIRST POSITIONAL PARAMETER FORMATTED AS A
> TWO-DIGIT ZERO-PADDED HEXADECIMAL NUMBER USING LOWERCASE LETTERS FOR THE
> HEX DIGITS A TO F

Your example is a bit unfair though, Neil. For one, how would it be parsed?
Two, it only implies and does not explicitly state the "find/search"
functionality
you use in the examples.

Interestingly, this seems to follow the useful form for a teaching tool.
Compromising between efficiently terse syntax and efficiently expressive
natural language gets... ?

-Steve

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

geni
In reply to this post by stevertigo-2
2009/7/6 stevertigo <[hidden email]>:

> On Mon, Jul 6, 2009 at 11:21 AM, <[hidden email]> wrote:
>
>> Neil let me just point out in counter-point that the two longest-living
>> third-generation langages, COBOL and BASIC are both still alive and well.
>> Both use a most English-like foundation.
>>  Is Python more represented in want-ads ?  Most businesses still use older
>> generation languages, regardless of what is being taught in university.
>
> Ball-and-chain legacy issues substantiate your argument?
>

BASIC is around for more than legacy issues and is of interest to us
since it was meant to solve much the same problem (how to make
programing accessible to non programmers). While it's true program
languages have pretty much given up experimenting with natural
language and similar it's also true that programing has shifted from
something any computer user has to do to something rather more
specialised. We on the other hand want to do the opposite. We need to
have something that non programmers can use which was effectively the
problem that BASIC was looking to solve.

Most existing languages were not built to solve that problem so using
them would be unwise.

What we should do depends on a number of factors. If we think we have
worked out most of the things templates are likely to be used for (we
had better we are running out of space in articles to put them) then a
custom designed language which is setup to make those functions
accessible but with a full general purpose setup to allow for people
to do other things (incidentally that would be 1,2 and 3 of what
wikipedia thinks are the eight design principles of BASIC) would in
many ways be the best approach.

If we think there is a lot of stuff that people are going to want to
use templates for that has not yet been done then a generalised
language with simplification for existing common functions bolted on
would likely be a better approach.

Heh it would be quite possible to make construction of infoboxes
fairly easy in a basic like language. There are various reasons why
this is a bad idea (adding reasons for retaining capslock is never a
good idea). Still BASIC's handling of IF, THEN, ELSE is something of
an improvement on the current setup.



--
geni

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

stevertigo-2
On Mon, Jul 6, 2009 at 12:20 PM, geni<[hidden email]> wrote:

> While it's true program languages have pretty much given up experimenting with natural
> language and similar, it's also true that programing has shifted from
> something any computer user has to do to something rather more
> specialised. We on the other hand want to do the opposite. We need to
> have something that non programmers can use which was effectively the
> problem that BASIC was looking to solve.

Hm.

-Steven

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
Reply | Threaded
Open this post in threaded view
|

Re: MediaWiki is getting a new programming language

George William Herbert
In reply to this post by WJhonson
On Mon, Jul 6, 2009 at 12:01 PM, <[hidden email]> wrote:
> The reason BASIC was and still enjoys wide popularity is because it's
> easier to learn.

I don't know that BASIC in any of its flavors lines up well with the
functional requirements needed for easy (compact, easy to read, easy
to learn how to program) template structure and so forth.

If you'd like to propose a BASIC syntax for the tools we need, that
might make the argument more cogent and viable.  Of necessity you need
to base that on a BASIC which is freeware and portable.


--
-george william herbert
[hidden email]

_______________________________________________
WikiEN-l mailing list
[hidden email]
To unsubscribe from this mailing list, visit:
https://lists.wikimedia.org/mailman/listinfo/wikien-l
123456