Python mode for Rosetta Code -- wiki and examples

Okay, so, two issues here.

  1. The Rosetta Code wiki, where should listings go.

I don’t have a definitive answer, but I think it should simply be separate.

=={{header|Processing}}==
<lang processing>
...
</lang>
=={{header|Processing.py}}==
<lang processing.py>
...
</lang>

…and there should be a Processing.py language page on the wiki that says something like “Processing.py is a Processing mode. It is a special Python 2 dialect that runs via Jython on JVM, with built-in direct access to the Processing (Java) API.”

The basic reason is that the purpose of the wiki is to compare the same task in different language / syntaxes / modes. For that purpose, it might make sense to make Processing.py a subheading under Python (python2, python3, processing.py) but it probably doesn’t make sense under Processing.

There has long been some ambiguity about whether to call it Python Mode for Processing, or Processing.py, or both (the website and reference material headers do). For the Rosetta Code wiki I would recommend listing it under Processing.py – because languages are listed alphabetically, and that way the two are next to each other.

Headers are also used for the generation of automatic indexes – if the mode doesn’t have its own language header then some things become very hard to track – like looking up what has already been done across the site.

I’m less certain about lang tags. I think that they should be specific – processing, not java, and maybe processing.py, not python – but I need to look that up.

1 Like