Skip to content

Commit

Permalink
fix syntax errors lookup
Browse files Browse the repository at this point in the history
  • Loading branch information
tonybaloney committed Oct 25, 2024
1 parent 19040b7 commit e0882cc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 3 additions & 1 deletion Lib/site.py
Original file line number Diff line number Diff line change
Expand Up @@ -747,8 +747,10 @@ def exists(path):

# Localizations
sys.localized_exceptions = {}; sys.localized_exceptions['id'] = {}

sys.localized_exceptions['id']["'%.100s' object has no attribute '%U'"] = "Objek '%.100s' tidak memiliki atribut '%U'"
sys.localized_exceptions['id']['division by zero'] = "pembagian dengan nol"

sys.localized_exceptions['id']["unsupported operand type(s) for %.100s: '%.100s' and '%.100s'"] = "tipe operan tidak didukung untuk %.100s: '%.100s' dan '%.100s'"
sys.localized_exceptions['id']["unmatched '%c'"] = "'%c' tidak cocok"
if __name__ == '__main__':
_script()
1 change: 0 additions & 1 deletion Python/errors.c
Original file line number Diff line number Diff line change
Expand Up @@ -1177,7 +1177,6 @@ static const char* _PyErr_GetLocalizedException(PyThreadState *tstate, const cha
// Get entry for string
PyObject* entry = PyDict_GetItemString(lang_dict, message);
if (entry == NULL) {
Py_DECREF(lang_dict);
return message;
}

Expand Down

0 comments on commit e0882cc

Please sign in to comment.