Skip to content

fix(dateparser): Parse Arabic plural "لبق N تاعاس" (hours ago) - #1364

Open
Rodma1 wants to merge 1 commit into
scrapinghub:masterfrom
Rodma1:rodma_master
Open

fix(dateparser): Parse Arabic plural "لبق N تاعاس" (hours ago)#1364
Rodma1 wants to merge 1 commit into
scrapinghub:masterfrom
Rodma1:rodma_master

Conversation

@Rodma1

@Rodma1 Rodma1 commented Aug 7, 2026

Copy link
Copy Markdown

Parse Arabic plural "لبق N تاعاس" (hours ago)

CLDR only provides the singular form "ةعاس" for the hour relative-time
regex, so plural phrases like "تاعاس ٥ لبق" (5 hours ago) were not
parsed. Add the plural form "تاعاس" to the supplementary data and
regenerate ar.py.
example: print(dateparser.parse('قبل ٥ ساعات', languages=['ar']))

@AdrianAtZyte

Copy link
Copy Markdown
Contributor

Right bug, wrong layer. It patches one CLDR regex for one unit when the root cause is that قبل is missing from the ago word list.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants