Project

General

Profile

Actions

Bug #20280

closed

Error at invalid encoding symbols

Added by nobu (Nobuyoshi Nakada) 5 months ago. Updated 19 days ago.

Status:
Closed
Assignee:
-
Target version:
-
[ruby-core:116838]

Description

Parsing an invalid encoding symbol raises an EncodingError.
It must be a SyntaxError.

https://github.com/ruby/ruby/pull/10014

Actions #1

Updated by nobu (Nobuyoshi Nakada) 5 months ago

  • Description updated (diff)
Actions #2

Updated by nobu (Nobuyoshi Nakada) 5 months ago

  • Status changed from Open to Closed

Applied in changeset git|fcc55dc2261b4c61da711c10a5476d05d4391eca.


[Bug #20280] Raise SyntaxError on invalid encoding symbol

Updated by k0kubun (Takashi Kokubun) about 1 month ago

The diff seems to conflict with refactoring changes that are missing in ruby_3_3. Could you file a backport PR to ruby_3_3 branch?

Actions #4

Updated by k0kubun (Takashi Kokubun) about 1 month ago

  • Status changed from Closed to Open
Actions #5

Updated by k0kubun (Takashi Kokubun) 30 days ago

  • Status changed from Open to Closed

Updated by k0kubun (Takashi Kokubun) 23 days ago

  • Backport changed from 3.0: REQUIRED, 3.1: REQUIRED, 3.2: REQUIRED, 3.3: REQUIRED to 3.0: REQUIRED, 3.1: REQUIRED, 3.2: REQUIRED, 3.3: DONE

Updated by nagachika (Tomoyuki Chikanaga) 19 days ago

  • Backport changed from 3.0: REQUIRED, 3.1: REQUIRED, 3.2: REQUIRED, 3.3: DONE to 3.1: REQUIRED, 3.2: WONTFIX, 3.3: DONE

SyntaxErro isn't a descendant of StandardError and cannot be caught with rescue clause without explicit exception class specification. I won't backport this to 3.2 until any real world application suffered from this issue.

Actions

Also available in: Atom PDF

Like0
Like0Like0Like0Like0Like0Like0Like0Like0