Making WordPress.org

Opened 8 years ago

Closed 6 years ago

#1401 closed defect (bug) (fixed)

Warnings: Improve regex for URLs

Reported by: ocean90's profile ocean90 Owned by: ocean90's profile ocean90
Milestone: Priority: normal
Component: Translate Site & Plugins Keywords: needs-patch
Cc:

Description

New translation warning for Meta - WordPress.org Plugin Directory in Italian #it:
​*Warning:*​ The translation appears to be missing the following URLs: http://wordpress.org/plugins/<strong>demo-plugin-name</strong>
The translation contains the following unexpected URLs: http://wordpress.org/plugins/<strong>nome-del-plugin-dimostrativo</strong>
    ​*Original:*​ For example: "Demo Plugin Name" will become http://wordpress.org/plugins/<strong>demo-plugin-name</strong>
    ​*Translation:*​ Per esempio: "Nome del plugin dimostrativo" diventerà http://wordpress.org/plugins/<strong>nome-del-plugin-dimostrativo</strong>

we can probably just whitelist [a-z0-9/] as the last character or something

https://wordpress.slack.com/archives/meta-i18n/p1447285320000081

Change History (5)

This ticket was mentioned in Slack in #glotpress by ocean90. View the logs.


7 years ago

This ticket was mentioned in Slack in #glotpress by ocean90. View the logs.


7 years ago

#3 @garrett-eclipse
7 years ago

I just wanted to update the ticket to log another case on this as it's slightly different, basically in my case the URL check took into account the carriage return at the end of the URL and flagged it as the URL was missing. See screen;
http://i.imgur.com/zixiYOG.png

I guess this string has a check to make sure the URL is present. And it's failing that check only because there's a carriage return at the end of the URL.
Permalink - https://translate.wordpress.org/projects/wp-plugins/ewww-image-optimizer/stable-readme/en-ca/default?filters%5Bstatus%5D=either&filters%5Boriginal_id%5D=1343816&filters%5Btranslation_id%5D=48536791

I see this as a Glotpress issue cause it's URL lookup is taking into account the carriage return.

Hope this is helpful.
Cheers

#4 @ocean90
7 years ago

#2949 was marked as a duplicate.

#5 @ocean90
6 years ago

  • Owner set to ocean90
  • Resolution set to fixed
  • Status changed from new to closed

In 7314:

Translate, Custom Warnings: Add a whitelist for the last URL character to reduce the number of false-positives for mismatching URLs.

Fixes #1401.

Note: See TracTickets for help on using tickets.