urvanov-ru / crayon-syntax-highlighter

Syntax Highlighter supporting multiple languages, themes, fonts, highlighting from a URL, local file or post text.
https://wordpress.org/plugins/urvanov-syntax-highlighter/
GNU General Public License v3.0
60 stars 11 forks source link

[BUG] Languages parsed with errors #6

Closed worldsdream closed 4 years ago

worldsdream commented 4 years ago

Parsed with errors

firefox_ieuBkeBNfR

worldsdream commented 4 years ago

@urvanov-ru did you had a chance to check this out? The log is filling up with these logs.

`[Crayon Syntax Highlighter Log Entry - 7:18:11 PM - 03 May 2020]

[SYSTEM LOG] 'The regex for the element \'VARIABLE\' in \'/langs/default/default.txt\' is not valid.' [SYSTEM LOG] 'The regex for the element \'OPERATOR\' in \'/langs/default/default.txt\' is not valid.' [SYSTEM LOG] 'The language at \'/langs/apache/apache.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/applescript/applescript.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/arduino/arduino.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/arduino/arduino.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/as/as.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/as/as.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/asm/asm.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/asp/asp.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/asp/asp.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/autoit/autoit.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/batch/batch.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c/c.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c/c.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c#/c#.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c#/c#.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c++/c++.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/c++/c++.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/clojure/clojure.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/coffee/coffee.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/delphi/delphi.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/dws/dws.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/go/go.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/go/go.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/haskell/haskell.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ilogic/ilogic.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ilogic/ilogic.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ini/ini.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/java/java.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/java/java.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/js/js.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/js/js.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/kl/kl.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/lisp/lisp.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/lua/lua.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/lua/lua.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/matlab/matlab.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/mel/mel.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/miva/miva.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/miva/miva.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/monkey/monkey.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/monkey/monkey.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/objc/objc.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/objc/objc.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/papyrus/papyrus.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/papyrus/papyrus.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/perl/perl.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/php/php.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ps/ps.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/python/python.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/python/python.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/r/r.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/r/r.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ruby/ruby.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/ruby/ruby.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/rust/rust.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/rust/rust.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/scala/scala.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/scala/scala.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/scheme/scheme.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/sh/sh.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/sh/sh.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/swift/swift.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/swift/swift.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/tsql/tsql.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/vb/vb.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/vb/vb.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/verilog/verilog.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/verilog/verilog.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/vim/vim.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/xhtml/xhtml.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.' [SYSTEM LOG] 'The regex for the element \'LIST_KEY\' in \'/langs/yaml/yaml.txt\' is not valid.' [SYSTEM LOG] 'The language at \'/langs/zsh/zsh.txt\' referred to the Default Language regex for element \'VARIABLE\', which did not exist.' [SYSTEM LOG] 'The language at \'/langs/zsh/zsh.txt\' referred to the Default Language regex for element \'OPERATOR\', which did not exist.'`

urvanov-ru commented 4 years ago

It is strange, but I can see it only in PHP 7.4. PHP 7.0 parses them without errors. I think, something was changed in regular expression functions in PHP. Don't worry. I will investigate and fix it.

worldsdream commented 4 years ago

Thank you. Waiting for the fix.

urvanov-ru commented 4 years ago

It's just link for me: https://wiki.php.net/rfc/pcre2-migration#backward_incompatible_changes

I should fix it carefully

urvanov-ru commented 4 years ago

Fixed in 2.8.11.

worldsdream commented 4 years ago

Working perfect. Great Job. I am closing the bug.