Make WordPress Core

Opened 4 years ago

Closed 8 months ago

Last modified 3 months ago

#57761 closed enhancement (fixed)

Prevent non-Latin characters from being used in filenames

Reported by: danielbachhuber Owned by:
Priority: normal Milestone: 6.2
Component: Build/Test Tools Version:
Severity: normal Keywords:
Cc: Focuses:

Description

In r55294, I committed a few files with non-Latin characters in the filenames:

  • tests/phpunit/data/themedir1/block-theme-non-latin/parts/small-header-τεστ.html
  • tests/phpunit/data/themedir1/block-theme-non-latin/parts/small-header-测试.html
  • tests/phpunit/data/themedir1/block-theme-non-latin/templates/page-τεστ.html
  • tests/phpunit/data/themedir1/block-theme-non-latin/templates/page-测试.html

These filenames caused SVN checkouts to break in some environments (example):

svn: E000022: Can't convert string from 'UTF-8' to native encoding:
svn: E000022: /tmp/wp-cli-test-run--63ef7647f35894.16389676/wordpress-tests-lib/data/themedir1/block-theme-non-latin/parts/small-header-{U+03C4}{U+03B5}{U+03C3}{U+03C4}.html
cwd: /tmp/wp-cli-test-run--63ef7647f35894.16389676/
run time: 6.1638081073761

It'd probably be best to have a pre-commit hook to prevent non-Latin filenames from being committed in the future.

Change History (3)

#1 @danielbachhuber
4 years ago

In 55362:

REST API: Only use Latin characters in test filenames.

Non-Latin characters can break SVN checkout in some environments.

Follow up from [55294].

See #57329, #57761.

#2 @dmsnell
8 months ago

  • Resolutionfixed
  • Status newclosed

#3 @sabernhardt
3 months ago

  • Milestone Awaiting Review6.2
Note: See TracTickets for help on using tickets.