Module talk:number list

From Wiktionary, the free dictionary
Latest comment: 8 months ago by RagingPichu in topic mysteriously not working for large numbers
Jump to navigation Jump to search

Display of non-Hindu–Arabic numerals

[edit]

Right now, {{number box}} / this module only accepts and only displays unformatted numbers written in Hindu–Arabic numerals (0, 1, 2, 3, 4, 5, 6, 7, 8, and 9). This is a problem in the case of Ancient Greek, which has its own numerals (see here for an explanation), which are currently displayed by transclusions of {{cardinalbox}} and {{ordinalbox}} in Ancient Greek entries (see, for example, εἷς, δύο, τρεῖς, et seqq. and πρῶτος, δεύτερος, τρίτος, et seqq.). Rather than create {{adverbialbox}} for ἑξηκοντάκις (hexēkontákis, sixty times) and the rest of the Ancient Greek adverbial number words, I thought I'd make use of {{number box}} instead, and therefore created Module:number list/data/grc. However, if it is not possible for this module/template combo to display the Greek numerals, I'll create {{adverbialbox}} instead. Can this module/template combo be made to display the Greek numerals? (Ideally, they'd be autogenerated, but I wouldn't mind having to add them manually to Module:number list/data/grc alongside the current cardinal =, ordinal =, and adverbial = fields.) Pinging CodeCat as the creator of this template. — I.S.M.E.T.A. 18:06, 30 June 2015 (UTC)Reply

Please don't create even more templates as a workaround, that just makes it even more of a mess. I think it should display English numbers, so that English speakers know what number it is. —CodeCat 18:13, 30 June 2015 (UTC)Reply
CodeCat, who are you to decide unilaterally to change editorial practice in Ancient Greek entries? I am happy to go along with your efforts to bring about infrastructural centralisation as long as the process is lossless. Now, can this module be made to display Greek numerals, or can't it? — I.S.M.E.T.A. 18:25, 30 June 2015 (UTC)Reply
Am I not allowed to voice my opinions on things? I think English numbers should be shown. —CodeCat 18:29, 30 June 2015 (UTC)Reply
@CodeCat: Of course you are, but what is your involvement with Ancient Greek? Non-existent? So why do you suppose that your opinion that "English[WTF?] numbers should be shown" should become de facto policy by making it impossible to show any other form once this module is rolled out? If you want only Hindu–Arabic numerals to be displayed by these number boxes, you'll need to persuade Ancient Greek editors to go along with that, because otherwise they are likely to oppose you, and certainly won't share the workload of making use of this module. In posting my question above, I was seeking to co-operate with you. If you don't reciprocate, then what can I do other than create {{adverbialbox}} and thereby "make it even more of a mess"? — I.S.M.E.T.A. 18:44, 30 June 2015 (UTC)Reply
Right now, you want Greek numbers, I want English numbers. That's a non-consensus stalemate. So you could bring it up with a larger number of editors so that a consensus can be formed on what to do. —CodeCat 18:48, 30 June 2015 (UTC)Reply
@JohnC5, ObsequiousNewt: Any thoughts on this? — I.S.M.E.T.A. 19:08, 30 June 2015 (UTC)Reply
I quite honestly don't understand what CodeCat is trying to say (and I don't understand why Acronym is taking offense when they asked CodeCat for their opinion.) Could you explain what you mean? —ObsequiousNewt (εἴρηκα|πεποίηκα) 18:10, 3 July 2015 (UTC)Reply
@ObsequiousNewt: Compare ἑξήκοντα (hexḗkonta, sixty), ἑξηκοστός (hexēkostós, sixtieth), and ἑξηκοντάκις (hexēkontákis, sixty times); notice that, whilst the number boxes in ἑξήκοντα and ἑξηκοστός show the Greek numeral ξʹ, the number box in ἑξηκοντάκις shows the Hindu–Arabic numeral 60. CodeCat wants the number boxes to show Hindu–Arabic numerals, rather than Greek numerals. I was annoyed by CodeCat's response because I asked "Can this module/template combo be made to display the Greek numerals?" not "Should this module/template combo be made to display the Greek numerals?" and my initial motivation for using this module/template combo was to co-operate with CodeCat's general efforts to bring about infrastructural centralisation, which co-operativity I felt was not being reciprocated. — I.S.M.E.T.A. 23:00, 4 July 2015 (UTC)Reply

──────────────────────────────────────────────────────────────────────────────────────────────────── Well, if there's a way we can display both, that'd be good (if we're at a loss for how, I'd suggest the Arabic numerals below the Greek, and in a smaller font.) —ObsequiousNewt (εἴρηκα|πεποίηκα) 23:10, 4 July 2015 (UTC)Reply

@CodeCat: How ‛bout it? — I.S.M.E.T.A. 23:21, 4 July 2015 (UTC)Reply
Showing both should be ok. But only for the current number; showing it also for the previous/next number might crowd the box too much. —CodeCat 01:01, 5 July 2015 (UTC)Reply
@CodeCat: Can this module/template combo be made to do that? — I.S.M.E.T.A. 18:04, 5 July 2015 (UTC)Reply
Yes, but you'll need to add the Greek numbers to the list manually. —CodeCat 18:07, 5 July 2015 (UTC)Reply
@CodeCat: Like this? — I.S.M.E.T.A. 18:14, 5 July 2015 (UTC)Reply
Yes, pretty much. —CodeCat 18:28, 5 July 2015 (UTC)Reply
@CodeCat: Would you mind making the necessary changes to {{number box}} and/or Module:number list, then? — I.S.M.E.T.A. 20:25, 5 July 2015 (UTC)Reply
Done now. —CodeCat 22:16, 5 July 2015 (UTC)Reply
@CodeCat: Thanks, but this is what ObsequiousNewt proposed, and what I agree with. — I.S.M.E.T.A. 23:15, 5 July 2015 (UTC)Reply

Reconstructed languages

[edit]

@CodeCat, i guess this module doesn't support reconstructed languages, right? At least on page *vъtorъ with {{number box|sla-pro|2}} it says that page name doesn't match. I added "Reconstruction:Proto-Slavic/" but now it says that name lacks "*". —Игорь Тълкачь (talk) 19:19, 16 October 2016 (UTC)Reply

Fixed. —Игорь Тълкачь (talk) 06:41, 26 June 2018 (UTC)Reply

རབ་བཀྲམ་ཆེན་པོ

[edit]

This is not working for large numbers - it changes the number to the scientific notation which is not interpreted correctly by the module. Wyang (talk) 21:10, 16 November 2016 (UTC)Reply

@Wyang: Finally fixed. I guess Lua uses the C "%.14g" format specifier (source code) when concatenating numbers with strings, and therefore outputs scientific notation under certain circumstances (maybe if there would be 14 digits or more). — Eru·tuon 21:17, 27 February 2018 (UTC)Reply

दोन्ही

[edit]

@Erutuon I think your recent changes to this module have caused a Lua error on दोन्ही. Can you please take a look? —Internoob 04:52, 27 February 2018 (UTC)Reply

@Internoob: Fixed. — Eru·tuon 22:49, 27 February 2018 (UTC)Reply

ḏbꜥ

[edit]

@Erutuon Hello. I think something’s broken here since the addition of commas; see also ཁྲག་ཁྲིག་ཆེན་པོ and རབ་བཀྲམ, where the same problem seems to be manifesting (leading digits behind the first comma are omitted). — Vorziblix (talk · contribs) 04:22, 3 March 2018 (UTC)Reply

@Vorziblix: Thanks for bringing my attention to this. Fixed. — Eru·tuon 08:50, 3 March 2018 (UTC)Reply
[edit]

E. g. 200 should link to both 100 and 300, but it doesn't, see an example (let me also notify @J3133, who added the template in this case, about the issue). Ain92 (talk) 21:50, 26 March 2020 (UTC)Reply

00

[edit]

When the template is used to display 0 in any language, a self-link with display text 00 is rendered on top (see zero#English or cero#Spanish), apparently serving no purpose. I looked it up but I found no discussion about this. Is this intentional? If it is, what purpose does it serve? Cheers, sware🗣🏲 12:05, 21 August 2023 (UTC)Reply

PS: It seems to be caused by the function make_greater_power_of_ten, which doesn't check if the current number is a 0, so adding another after it doesn't make sense. Adding a condition to line 888 should fix it.

if upper_num == next_num or cur_num == "0" then

sware🗣🏲 12:25, 21 August 2023 (UTC)Reply

mysteriously not working for large numbers

[edit]

hello, i decided to make use of this to update the armenian number entries. i ran into a problem in high numbers: the template seems to break, as is visible in [1] (i cannot find how to link old revisions), even though all the parameters it throws in the error do exist... RagingPichu (talk) 20:55, 22 February 2024 (UTC)Reply