Warning

Most of the documentation was written prior to version 0.5 and needs to be updated. This work has now started for version 0.7 and we aim to have it completed before version 0.8 is available.

Friendly SyntaxError tracebacks - בעברית

Friendly שואפת לספק משוב ידידותי יותר כאשר מדובר בחריג מוגדל ממה שנעשה על ידי Python. (sentence translated by Google Translate).

This file contains only examples of SyntaxError and its sub-classes. Some tests may appear to be repetitive to a human reader but they are may be included to ensure more complete test coverage.

Note

The content of this page is generated by running trb_syntax_hebrew.py located in the tests/ directory. This needs to be done explicitly, independently of updating the documentation using Sphinx. On Windows, if Sphinx is installed on your computer, it is suggested instead to run make_trb.bat in the root directory as it will create similar files for all languages and update the documentation.

Friendly-traceback version: 0.7.53 Python version: 3.10.6

(1) Using ‘and’ in import statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\and_in_import_statement.py", line 1
    from math import sin and cos
                         ^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\and_in_import_statement.py'
במקום המצוין.

   1| from math import sin and cos
                           ^^^

The Python keyword `and` can only be used for boolean expressions.
Perhaps you meant to write

`from math import sin , cos`

(2) Using ‘and’ after comma in import statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\and_in_import_statement_2.py", line 1
    from math import sin, tan, and cos
                               ^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\and_in_import_statement_2.py'
במקום המצוין.

   1| from math import sin, tan, and cos
                                 ^^^

The Python keyword `and` can only be used for boolean expressions.
Perhaps you meant to write

`from math import sin, tan,  cos`

(3) Annotated name cannot be global

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\annotated_name_global.py", line 4
    var:int = 1
    ^^^^^^^^^^^
SyntaxError: annotated name 'var' can't be global

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\annotated_name_global.py'
במקום המצוין.

   4|     var:int = 1
          ^^^

האובייקט בשם 'var' מוגדר עם ביאור סוג
כמשתנה מקומי. לא ניתן להכריז עליו כמשתנה עולמי.

(4) Incorrect use of ‘from module import … as …

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\as_instead_of_comma_in_import.py", line 2
    from math import (sin, cos) as funcs
                                ^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\as_instead_of_comma_in_import.py'
במקום המצוין.

   2| from math import (sin, cos) as funcs
                                  ^^

אני מנחש שאתה מנסה לייבא לפחות אובייקט אחד
מהמודול `math` ושנה את שמו באמצעות מילת המפתח Python `as`;
ניתן להשתמש במילת מפתח זו רק כדי לשנות שם אובייקט אחד בכל פעם
תוך שימוש בתחביר מוגדר היטב.
אני מציע שתחלק כל משפט ייבוא כזה עם כל אובייקט
שונה שם בשורה נפרדת באופן הבא:

    מ-math import object_1 בשם name_1
    מ-math import object_2 בשם name_2 # במידת הצורך

(5) Assign instead of equal (or walrus).

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_instead_of_equal.py", line 1
    a = (b = 2)  # issue #65
         ^^^^^
SyntaxError: invalid syntax. Maybe you meant '==' or ':=' instead of '='?

    אולי היית צריך '==' או ': =' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_instead_of_equal.py'
במקום המצוין.

   1| a = (b = 2)  # issue #65
           ^^^^^

השתמשת באופרטור מקוצר  `=`; אולי התכוונת להשתמש
במפעיל שוויון, `==`, או במפעיל ישיר `: =`.

(6) Name assigned prior to global declaration

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_name_before_global_1.py", line 7
    global aa, bb, cc, dd
    ^^^^^^^^^^^^^^^^^^^^^
SyntaxError: name 'cc' is assigned to before global declaration

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_name_before_global_1.py'
במקום המצוין.

   7|     global aa, bb, cc, dd
          ^^^^^^         ^^

הקצית ערך למשתנה 'cc'
לפני הכרזתו כמשתנה גלובלי.

(7) Name used prior to global declaration

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_name_before_global_2.py", line 7
    global var
    ^^^^^^^^^^
SyntaxError: name 'var' is used prior to global declaration

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_name_before_global_2.py'
במקום המצוין.

   7|     global var
          ^^^^^^ ^^^

השתמשת במשתנה 'var'
לפני הכרזתו כמשתנה גלובלי.

(8) Name used prior to nonlocal declaration

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_name_before_nonlocal_1.py", line 11
    nonlocal pp, qq
    ^^^^^^^^^^^^^^^
SyntaxError: name 'qq' is used prior to nonlocal declaration

    האם שכחת לכתוב 'nonlocal' קודם?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_name_before_nonlocal_1.py'
במקום המצוין.

   11|         nonlocal pp, qq
               ^^^^^^^^     ^^

השתמשת במשתנה 'qq'
לפני הכרזתו כמשתנה לא -מקומי. (nonlocal )

(9) Name assigned prior to nonlocal declaration

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_name_before_nonlocal_2.py", line 9
    nonlocal s
    ^^^^^^^^^^
SyntaxError: name 's' is assigned to before nonlocal declaration

    שכחת להוסיף `nonlocal`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_name_before_nonlocal_2.py'
במקום המצוין.

   9|         nonlocal s
              ^^^^^^^^ ^

הקצית ערך למשתנה 's'
לפני הכרזתו כמשתנה לא -מקומי (nonlocal).

(10) Assign to conditional expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_conditional.py", line 3
    a if 1 else b = 1
    ^^^^^^^^^^^^^
SyntaxError: cannot assign to conditional expression

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_conditional.py'
במקום המצוין.

   3| a if 1 else b = 1
      ^^^^^^^^^^^^^

בצד שמאל של סימן שוויון, יש לך א
ביטוי מותנה במקום שם של משתנה.
    a if 1 else b = ...
    ^^^^^^^^^^^^^
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(11) Assignment to keyword (__debug__)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_debug.py", line 4
    __debug__ = 1
    ^^^^^^^^^
SyntaxError: cannot assign to __debug__

    You cannot assign a value to `__debug__`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_debug.py'
במקום המצוין.

   4| __debug__ = 1
      ^^^^^^^^^

`__debug__` הוא קבוע בפיתון; אינך יכול להקצות לו ערך אחר.

(12) Assignment to keyword (__debug__)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_debug2.py", line 4
    a.__debug__ = 1
    ^^^^^^^^^^^
SyntaxError: cannot assign to __debug__

    You cannot assign a value to `__debug__`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_debug2.py'
במקום המצוין.

   4| a.__debug__ = 1
        ^^^^^^^^^

`__debug__` הוא קבוע בפיתון; אינך יכול להקצות לו ערך אחר.

(13) Assignment to Ellipsis symbol

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_ellipsis.py", line 4
    ... = 1
    ^^^
SyntaxError: cannot assign to ellipsis here. Maybe you meant '==' instead of '='?

    לא ניתן להקצות ערך לסמל האליפסיס (ellipsis) ['...'].

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_ellipsis.py'
במקום המצוין.

   4| ... = 1
      ^^^

סמל האליפסיס (ellipsis ) '...' הוא קבוע בפייתון; אינך יכול\ה להקצות לו ערך אחר.

(14) Cannot assign to f-string

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_f_string.py", line 6
    f'{x}' = 42
    ^^^^^^
SyntaxError: cannot assign to f-string expression here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_f_string.py'
במקום המצוין.

   6| f'{x}' = 42
      ^^^^^^

כתבת ביטוי המכיל את מחרוזת f 'f'{x}''
בצד שמאל של סימן השוויון.
מחרוזת f צריכה להופיע רק בצד ימין של סימן שווה.
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(15) Cannot assign to function call: single = sign

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_function_call_1.py", line 6
    len('a') = 3
    ^^^^^^^^
SyntaxError: cannot assign to function call here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_function_call_1.py'
במקום המצוין.

   6| len('a') = 3
      ^^^^^^^^

אתה כתבת את הביטוי

    len('a') = ...
    ^^^^^^^^
כאשר `len('a')`, בצד שמאל של סימן השוויון, אחד מהם
או כולל קריאה לפונקציה ואינו רק שם של משתנה.
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(16) Cannot assign to function call: two = signs

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_function_call_2.py", line 6
    func(a, b=3) = 4
    ^^^^^^^^^^^^
SyntaxError: cannot assign to function call here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_function_call_2.py'
במקום המצוין.

   6| func(a, b=3) = 4
      ^^^^^^^^^^^^

אתה כתבת את הביטוי

    func(a, b=3) = ...
    ^^^^^^^^^^^^
כאשר `func(a, b=3)`, בצד שמאל של סימן השוויון, אחד מהם
או כולל קריאה לפונקציה ואינו רק שם של משתנה.
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(17) Cannot assign to function call: continues on second line

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_function_call_3.py", line 6
    a = f(1, 2,  # this is a comment
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^-->
SyntaxError: cannot assign to function call

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_function_call_3.py'
במקום המצוין.

-->6| a = f(1, 2,  # this is a comment
          ^^^^^^^-->
   7|       3, 4) = 5

אתה כתבת את הביטוי

    f(1, 2,...) = ...
    ^^^^^^^-->
כאשר `f(1, 2,...)`, בצד שמאל של סימן השוויון, אחד מהם
או כולל קריאה לפונקציה ואינו רק שם של משתנה.
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(18) Assign to generator expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_generator.py", line 3
    (x for x in x) = 1
    ^^^^^^^^^^^^^^
SyntaxError: cannot assign to generator expression

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_generator.py'
במקום המצוין.

   3| (x for x in x) = 1
      ^^^^^^^^^^^^^^

בצד שמאל של סימן שוויון, יש לך
ביטוי גנרטור במקום שם של משתנה.
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(19) Cannot assign to literal - 4

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_literal_dict.py", line 7
    {1 : 2, 2 : 4} = 5
    ^^^^^^^^^^^^^^
SyntaxError: cannot assign to dict literal here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_literal_dict.py'
במקום המצוין.

   7| {1 : 2, 2 : 4} = 5
      ^^^^^^^^^^^^^^

כתבת ביטוי כמו

     {1 : 2, 2 : 4} = 5
כאשר '{1 : 2, 2 : 4}', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג dict (מילון)
וזה לא רק שמו של משתנה.

ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(20) Cannot assign to literal int

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_literal_int.py", line 3
    1 = a
    ^
SyntaxError: cannot assign to literal here. Maybe you meant '==' instead of '='?

    אולי התכוונת לכתוב 'a = 1'
'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_literal_int.py'
במקום המצוין.

   3| 1 = a
      ^

כתבת ביטוי כמו

     1 = a
כאשר '1', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג int (שלם)
וזה לא רק שמו של משתנה.
אולי התכוונת לכתוב:

     a = 1

(21) Cannot assign to literal int - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_literal_int_2.py", line 3
    1 = 2
    ^
SyntaxError: cannot assign to literal here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_literal_int_2.py'
במקום המצוין.

   3| 1 = 2
      ^

כתבת ביטוי כמו

     1 = 2
כאשר '1', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג int (שלם)
וזה לא רק שמו של משתנה.

ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(22) Cannot assign to literal - 5

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_literal_int_3.py", line 4
    1 = a = b
    ^
SyntaxError: cannot assign to literal

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_literal_int_3.py'
במקום המצוין.

   4| 1 = a = b
      ^

כתבת ביטוי כמו

     1 = שם_משתנה
כאשר '1', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג int (שלם)
וזה לא רק שמו של משתנה.

ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(23) Cannot assign to literal - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_literal_set.py", line 7
    {1, 2, 3} = 4
    ^^^^^^^^^
SyntaxError: cannot assign to set display here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_literal_set.py'
במקום המצוין.

   7| {1, 2, 3} = 4
      ^^^^^^^^^

כתבת ביטוי כמו

     {1, 2, 3} = 4
כאשר '{1, 2, 3}', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג set (סט)
וזה לא רק שמו של משתנה.

ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(24) Assign to keyword def

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_keyword_def.py", line 3
    def = 2
        ^
SyntaxError: invalid syntax

    לא ניתן להשתמש במילות מפתח של פייתון כמזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_keyword_def.py'
במקום המצוין.

   3| def = 2
      ^^^

ניסית להקצות ערך למילת המפתח של פייתון "def".
זה אסור.

(25) Assign to keyword else

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_keyword_else.py", line 3
    else = 1
    ^^^^
SyntaxError: invalid syntax

    לא ניתן להשתמש במילות מפתח של פייתון כמזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_keyword_else.py'
במקום המצוין.

   3| else = 1
      ^^^^

ניסית להקצות ערך למילת המפתח של פייתון "else".
זה אסור.

(26) Assignment to keyword (None)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_keyword_none.py", line 4
    None = 1
    ^^^^
SyntaxError: cannot assign to None

    You cannot assign a value to `None`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_keyword_none.py'
במקום המצוין.

   4| None = 1
      ^^^^

`None` הוא קבוע בפיתון; אינך יכול להקצות לו ערך אחר.

(27) Assign to math operation

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_operation.py", line 4
    a + 1 = 2
    ^^^^^
SyntaxError: cannot assign to expression here. Maybe you meant '==' instead of '='?

    אולי היית צריך\ה '==' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_operation.py'
במקום המצוין.

   4| a + 1 = 2
      ^^^^^

כתבת ביטוי הכולל כמה פעולות מתמטיות
בצד שמאל של סימן השוויון שאמור להיות
משמש רק להקצאת ערך למשתנה.

(28) Assign to yield expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assign_to_yield_expression.py", line 1
    (yield i) = 3
     ^^^^^^^
SyntaxError: cannot assign to yield expression here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assign_to_yield_expression.py'
במקום המצוין.

   1| (yield i) = 3
       ^^^^^

You wrote an expression that includes the `yield` keyword
on the left-hand side of the equal sign.
You cannot assign a value to such an expression.
Note that, like the keyword `return`,
`yield` can only be used inside a function.

(29) Augmented assignment inside comprehension

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assignment_expression_cannot_rebind.py", line 1
    a = [(i := 1) for i in [1]]
          ^
SyntaxError: assignment expression cannot rebind comprehension iteration variable 'i'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assignment_expression_cannot_rebind.py'
במקום המצוין.

   1| a = [(i := 1) for i in [1]]
            ^

You are using the augmented assignment operator `:=` inside
a comprehension to assign a value to the iteration variable `i`.
This variable is meant to be used only inside the comprehension.
The augmented assignment operator is normally used to assign a value
to a variable so that the variable can be reused later.
This is not possible for variable `i`.

(30) Augmented assignment inside comprehension - inner loop

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\assignment_expression_cannot_rebind_2.py", line 1
    [i for i in range(5) if (j := 0) for k[j + 1] in range(5)]
                                           ^
SyntaxError: comprehension inner loop cannot rebind assignment expression target 'j'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\assignment_expression_cannot_rebind_2.py'
במקום המצוין.

   1| [i for i in range(5) if (j := 0) for k[j + 1] in range(5)]
                                             ^

You are using the augmented assignment operator `:=` inside
a comprehension to assign a value to the iteration variable `j`.
This variable is meant to be used only inside the comprehension.
The augmented assignment operator is normally used to assign a value
to a variable so that the variable can be reused later.
This is not possible for variable `j`.

(31) def: missing parentheses

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\async_def_missing_parens.py", line 1
    async def name:
                  ^
SyntaxError: invalid syntax

    שכחת סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\async_def_missing_parens.py'
במקום המצוין.

   1| async def name:
                    ^

אולי שכחת לכלול סוגריים.
אולי התכוונת לכתוב

     async def name():

(32) Augmented assignment to literal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\augmented_assignment_to_literal.py", line 1
    if "word" := True:
       ^^^^^^
SyntaxError: cannot use assignment expressions with literal

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\augmented_assignment_to_literal.py'
במקום המצוין.

   1| if "word" := True:
         ^^^^^^

אינך יכול להשתמש באופרטור ההקצאה המוגבר `: =`,
לפעמים נקרא מפעיל הזן, עם מילת מילים כמו ""word"".
ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

(33) Walrus/Named assignment depending on Python version

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\augmented_assigment_with_true.py", line 4
    (True := 1)
     ^^^^
SyntaxError: cannot use assignment expressions with True

    You cannot assign a value to `True`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\augmented_assigment_with_true.py'
במקום המצוין.

   4| (True := 1)
       ^^^^

`True` הוא קבוע בפיתון; אינך יכול להקצות לו ערך אחר.

(34) Backslash instead of slash

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\backslash_instead_of_slash.py", line 1
    a = 3 \ 4.0
           ^
SyntaxError: unexpected character after line continuation character

    האם התכוונת לחלק ב 4.0?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\backslash_instead_of_slash.py'
במקום המצוין.

   1| a = 3 \ 4.0
              ^^^

את\ה משתמש\ת בתו '\' מחוץ למחרוזת,
ואחריו כמה דמויות אחרות.
אני מניח שרצית לחלק במספר 4.0
וכתבת "\" במקום "/".

(35) Brackets instead of parentheses

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\bracket_instead_of_paren.py", line 1
    print(sum[i for i in [1, 2, 3] if i%2==0])
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    שכחת משהו בין 'sum' ל- '['?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\bracket_instead_of_paren.py'
במקום המצוין.

   1| print(sum[i for i in [1, 2, 3] if i%2==0])
            ^^^^

פייתון מציין כי השגיאה נגרמת על ידי "[" שקרה מיד לאחר "sum".
יתכן ששכחת פסיק בין פריטים בטופל,
או בין ארגומנטים של פונקציה,
במיקום המצוין על ידי ^.
אולי התכוונת להכניס אופרטור כמו '+, -, *'
בין `sum` ו- `[`.
שורות הקוד הבאות לא יגרמו לשום 'SyntaxError':
    print(sum, [i for i in [1, 2, 3] if i%2==0])
    print(sum + [i for i in [1, 2, 3] if i%2==0])
    print(sum - [i for i in [1, 2, 3] if i%2==0])
    print(sum * [i for i in [1, 2, 3] if i%2==0])
הערה: אלה רק חלק מהאפשרויות האפשריות וזה
חלקם עשויים להעלות סוגים אחרים של חריגים.

There is an additional possibility.
You used square brackets, `[...]` instead of parentheses.
Write the following instead:

    print(sum(i for i in [1, 2, 3] if i%2==0))

(36) break outside loop

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\break_outside_loop.py", line 4
    break
    ^^^^^
SyntaxError: 'break' outside loop

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\break_outside_loop.py'
במקום המצוין.

   4|     break
          ^^^^^

ניתן להשתמש במילת המפתח Python 'break' רק בתוך לולאת 'for' (פור) או בתוך לולאה של 'while' (בעוד).

(37) Cannot assign to attribute here.

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\cannot_assign_to_attribute_here.py", line 1
    if x.a = 1:
       ^^^
SyntaxError: cannot assign to attribute here. Maybe you meant '==' instead of '='?

    אולי היית צריך\ה '==' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\cannot_assign_to_attribute_here.py'
במקום המצוין.

   1| if x.a = 1:
         ^^^

סביר להניח שהשתמשת באופרטור הגדרה  `=` במקום מפעיל שוויון `==`.
The following statement would not contain a syntax error:

    if x.a == 1:

(38) Cannot guess the cause

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\cannot_guess_the_cause.py", line 1
    SyntaxErrors can be annoying!
                 ^^^
SyntaxError: invalid syntax

    מקור השגיאה לא ידוע.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\cannot_guess_the_cause.py'
במקום המצוין.

   1| SyntaxErrors can be annoying!
                   ^^^

נכון לעכשיו, אינני יכול לנחש את הסיבה הסבירה לשגיאה זו.
נסה\י לבחון מקרוב את הקו המצוין כמו גם את הקו
מיד למעלה כדי לראות אם אפשר לזהות כמה שגיאות כתיב
מילה או סמלים חסרים, כמו (,), [,],:, וכו '.

אלא אם כן הקוד שלך משתמש ברמזי סוג, שהם מעבר להיקף שלנו,
אם את\ה חושב\ת שזה משהו שצריך לטפל בו
על ידי ידידותי, אנא דווח על מקרה זה
https://github.com/friendly-traceback/friendly-traceback/issues

(39) Cannot use star operator

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\cannot_use_star.py", line 3
    *a
    ^^
SyntaxError: can't use starred expression here

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\cannot_use_star.py'
במקום המצוין.

   3| *a
      ^^

אופרטור הכוכב "*" מתפרש כמשמעותו
יש להשתמש בפירוק חוזר כדי להקצות שם
לכל פריט של חוזר, וזה לא הגיוני כאן.

(40) Cannot use double star operator

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\cannot_use_double_star.py", line 4
    (**k)
     ^^
SyntaxError: f-string: cannot use double starred expression here

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\cannot_use_double_star.py'
במקום המצוין.

   4|     print(f"{**k}")
                        ^

אופרטור הכוכב הכפול `**` מתפרש כנראה כך
יש להשתמש ב-dict פירוק מה שאסור או לא הגיוני כאן.

(41) Missing class name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\class_missing_name.py", line 1
    class:
         ^
SyntaxError: invalid syntax

    כיתה(class) צריכה שם.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\class_missing_name.py'
במקום המצוין.

   1| class:
           ^

הצהרת 'כיתה' דורשת שם:

    class SomeName:
        ...

(42) Missing () for tuples in comprehension

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\comprehension_missing_tuple_paren.py", line 1
    x = [i, i**2 for i in range(10)]
         ^^^^^^^
SyntaxError: did you forget parentheses around the comprehension target?

    שכחת סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\comprehension_missing_tuple_paren.py'
במקום המצוין.

   1| x = [i, i**2 for i in range(10)]
           ^^^^^^^

אני מנחש שכתבת הבנה או ביטוי מחולל
ושכח לכלול סוגריים סביב צמדים.
כדוגמה, במקום לכתוב

    [i, i**2 for i in range(10)]
תצטרך לכתוב

      [(i, i**2) for i in range(10)]

(43) Comprehension with condition (no else)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\comprehension_with_condition_no_else.py", line 1
    a = [f(x) if condition for x in sequence]
         ^^^^^^^^^^^^^^^^^
SyntaxError: expected 'else' after 'if' expression

    Did you forget to add `else`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\comprehension_with_condition_no_else.py'
במקום המצוין.

   1| a = [f(x) if condition for x in sequence]
           ^^^^^^^^^^^^^^^^^

An `else some_value` clause was expected after the `if` expression.

(44) Comprehension with condition (with else)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\comprehension_with_condition_with_else.py", line 1
    a = [f(x) for x in sequence if condition else other]
                                             ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\comprehension_with_condition_with_else.py'
במקום המצוין.

   1| a = [f(x) for x in sequence if condition else other]
                                               ^^^^

אני מנחש שכתבת הבנה או ביטוי מחולל (comprehension or a generator expression)
והשתמשת בסדר הלא נכון.
הסדר הנכון תלוי אם יש סעיף אחר (else) או לא
לדוגמא,לדוגמה, הסדר הנכון לגנרטור הוא
[f(x) if condition else other for x in sequence]  # 'if' before 'for'
אם אין "אחר"
ו-  [f(x) for x in sequence if condition]  # 'if' after 'for' אם יש אחר

(45) continue outside loop

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\continue_outside_loop.py", line 4
    continue
    ^^^^^^^^
SyntaxError: 'continue' not properly in loop

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\continue_outside_loop.py'
במקום המצוין.

   4|     continue
          ^^^^^^^^

ניתן להשתמש במילת המפתח של פייתון 'המשך' רק בתוך לולאת 'for'(פור) או בתוך לולאה של 'while' (בעוד).

(46) Copy/paste from interpreter

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\copy_pasted_code.py", line 2
    >>> print("Hello World!")
    ^^
SyntaxError: invalid syntax

    האם השתמשת בהעתק-הדבק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\copy_pasted_code.py'
במקום המצוין.

   2| >>> print("Hello World!")
      ^^^

נראה שאתה מעתיק קוד שהודבק ממתורגמן אינטראקטיבי.
שורת הפייתון, '>>> `, לא צריכה להיכלל בקוד שלך.

(47) Copy/paste from interpreter - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\copy_pasted_code_2.py", line 2
    ... print("Hello World!")
        ^^^^^
SyntaxError: invalid syntax

    האם השתמשת בהעתק-הדבק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\copy_pasted_code_2.py'
במקום המצוין.

   2| ... print("Hello World!")
      ^^^

נראה שאתה מעתיק קוד שהודבק ממתורגמן אינטראקטיבי.
שורת הפייתון, '...', לא צריכה להיכלל בקוד שלך.

(48) def: positional arg after kwargs

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_arg_after_kwarg.py", line 1
    def test(a, **kwargs, b):
                          ^
SyntaxError: invalid syntax

    ארגומנטים עמדתיים חייבים לבוא לפני ארגומנטים של מילות מפתח.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_arg_after_kwarg.py'
במקום המצוין.

   1| def test(a, **kwargs, b):
                            ^

ארגומנטים עמדתיים חייבים לבוא לפני ארגומנטים של מילות מפתח.
'b' הוא ארגומנט עמדתי שמופיע לאחר אחד או יותר
ארגומנטים של מילות מפתח בהגדרת הפונקציה שלך.

(49) def: named arguments must follow bare *

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_bare_star_arg.py", line 4
    def f(*):
          ^
SyntaxError: named arguments must follow bare *

    שכחת משהו אחרי '*'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_bare_star_arg.py'
במקום המצוין.

   4| def f(*):
            ^

בהנחה שאתה מגדיר פונקציה, אתה צריך
להחליף את "*" ב"*args "או
על ידי `*, named_argument = value`.

(50) def: misused as code block

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_code_block.py", line 3
    def :
        ^
SyntaxError: invalid syntax

    פונקציה צריכה שם.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_code_block.py'
במקום המצוין.

   3| def :
          ^

ניסית להגדיר פונקציה ולא השתמשת בתחביר הנכון.
התחביר הנכון הוא:
 def name ( ... ):

(51) def: misused as code block - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_code_block_2.py", line 2
    def :
        ^
SyntaxError: invalid syntax

    פונקציות ושיטות צריכות שם.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_code_block_2.py'
במקום המצוין.

   2|     def :
              ^

ניסית להגדיר פונקציה או שיטה ולא השתמשת בתחביר הנכון.
התחביר הנכון הוא:
 def name ( ... ):

(52) Dotted name as function argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_dotted_argument.py", line 3
    def test(x.y):
              ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_dotted_argument.py'
במקום המצוין.

   3| def test(x.y):
                ^

אינך יכול להשתמש בשמות מנוקדים כארגומנטים של פונקציות.
אולי התכוונת לכתוב פסיק.

(53) Dotted name as function argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_dotted_argument_2.py", line 2
    def test(x., y):
              ^
SyntaxError: invalid syntax

    אינך יכול להשתמש בשמות מנוקדים כארגומנטים של פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_dotted_argument_2.py'
במקום המצוין.

   2| def test(x., y):
                ^

אינך יכול להשתמש בשמות מנוקדים כארגומנטים של פונקציות.

(54) Dotted function name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_dotted_function_name.py", line 3
    def test.x():
            ^
SyntaxError: invalid syntax

    לא ניתן להשתמש בנקודות בשמות פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_dotted_function_name.py'
במקום המצוין.

   3| def test.x():
              ^

לא ניתן להשתמש בנקודות בשמות פונקציות.

(55) def: dict as argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_dict_as_arg.py", line 1
    def test({'a': 1}, y):  # dict as first argument
             ^
SyntaxError: invalid syntax

    אינך יכול\ה לקבל שום מילון (dict) מפורש או סט (set) כטיעוני פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_dict_as_arg.py'
במקום המצוין.

   1| def test({'a': 1}, y):  # dict as first argument
               ^

אינך יכול\ה לקבל שום מילון (dict) מפורש או סט (set) כטיעוני פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(56) def: arguments must be unique in function definition

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_duplicate_arg.py", line 4
    def f(aa=1, aa=2):
                ^^
SyntaxError: duplicate argument 'aa' in function definition

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_duplicate_arg.py'
במקום המצוין.

   4| def f(aa=1, aa=2):
            ^^    ^^

You have defined a function repeating the argument

    aa
Each argument should appear only once in a function definition.

(57) def: semicolon after colon

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_extra_semi_colon.py", line 1
    def test():;
               ^
SyntaxError: invalid syntax

    כתבת משהו בטעות אחרי הנקודותיים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_extra_semi_colon.py'
במקום המצוין.

   1| def test():;
                 ^

הצהרת הגדרת פונקציה חייב להסתיים בנקודותיים.
בלוק קוד חייב לבוא אחרי הנקודותיים.
הסרת ';' עשויה לפתור את הבעיה.

(58) def: extra comma

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_extra_comma.py", line 1
    def test(a,,b):
               ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב ','?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_extra_comma.py'
במקום המצוין.

   1| def test(a,,b):
                 ^

אני חושד שעשית שגיאת כתיב והוספת ',' בטעות.
המשפט הבא אינו מכיל שגיאת תחביר:

     def test(a,b):

(59) def: unspecified keywords before /

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_forward_slash_1.py", line 1
    def test(a, **kwargs, /):
                          ^
SyntaxError: invalid syntax

    ארגומנטים של מילות מפתח חייבים להופיע אחרי הסמל `/`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_forward_slash_1.py'
במקום המצוין.

   1| def test(a, **kwargs, /):
                            ^

`/` מציין כי הטיעונים הקודמים בהגדרת פונקציה
הם טיעונים עמדתיים.
יש לך ארגומנטים לא מפורטים של מילות מפתח המופיעים לפני
הסמל `/`.

(60) def: / before star

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_forward_slash_2.py", line 1
    def test(a, *, b, /):
                      ^
SyntaxError: invalid syntax

    '*' חייב להופיע אחרי '/' בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_forward_slash_2.py'
במקום המצוין.

   1| def test(a, *, b, /):
                        ^

`/` מציין כי הטיעונים הקודמים בהגדרת פונקציה
הם טיעונים עמדתיים.
עם זאת, '*' מציין כי הטיעונים
הבאים חייבים להיות טיעוני מילות מפתח.
כאשר הם משמשים יחד, '/' חייב להופיע לפני '*'.

(61) def: / before star arg

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_forward_slash_3.py", line 1
    def test(a, *arg, /):
                      ^
SyntaxError: invalid syntax

    '*arg' חייב להופיע אחרי '/' בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_forward_slash_3.py'
במקום המצוין.

   1| def test(a, *arg, /):
                        ^

`/` מציין כי הטיעונים הקודמים בהגדרת פונקציה
הם טיעונים עמדתיים.
'*arg' חייב להופיע אחרי '/' בהגדרת פונקציה.

(62) def: / used twice

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_forward_slash_4.py", line 1
    def test(a, /, b, /):
                      ^
SyntaxError: invalid syntax

    אפשר להשתמש ב- / רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_forward_slash_4.py'
במקום המצוין.

   1| def test(a, /, b, /):
                        ^

אפשר להשתמש ב- / רק פעם אחת בהגדרת פונקציה.

(63) def: non-identifier as a function name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_function_name_invalid.py", line 3
    def 2be():
        ^
SyntaxError: invalid decimal literal

    כתבת שם פונקציה לא חוקית.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_function_name_invalid.py'
במקום המצוין.

   3| def 2be():
          ^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

שם הפונקציה חייב להיות מזהה פייתון חוקי,
זהו שם שמתחיל באות או בתו קו, "_",
ואשר מכיל רק אותיות, ספרות וקו תחתון "_" .

(64) def: using a string as a function name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_function_name_string.py", line 3
    def "function"():
        ^^^^^^^^^^
SyntaxError: invalid syntax

    שם הפונקציה חייב להיות מזהה פייתון חוקי,
    זהו שם שמתחיל באות או בתו קו, "_",
    ואשר מכיל רק אותיות, ספרות וקו תחתון "_" .
    ניסית להשתמש במחרוזת בשם פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_function_name_string.py'
במקום המצוין.

   3| def "function"():
          ^^^^^^^^^^

שם הפונקציה חייב להיות מזהה פייתון חוקי,
זהו שם שמתחיל באות או בתו קו, "_",
ואשר מכיל רק אותיות, ספרות וקו תחתון "_" .
ניסית להשתמש במחרוזת בשם פונקציה.

(65) def: keyword cannot be argument in def - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_keyword_as_arg_1.py", line 5
    def f(None=1):
          ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_keyword_as_arg_1.py'
במקום המצוין.

   5| def f(None=1):
            ^^^^

אני מנחש שניסית להשתמש במילת המפתח של פייתון
`None` כארגומנט בהגדרת פונקציה
היכן היה צפוי מזהה (שם משתנה).

(66) def: keyword cannot be argument in def - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_keyword_as_arg_2.py", line 5
    def f(x, True):
             ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_keyword_as_arg_2.py'
במקום המצוין.

   5| def f(x, True):
               ^^^^

אני מנחש שניסית להשתמש במילת המפתח של פייתון
`True` כארגומנט בהגדרת פונקציה
היכן היה צפוי מזהה (שם משתנה).

(67) def: keyword cannot be argument in def - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_keyword_as_arg_3.py", line 5
    def f(*None):
           ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_keyword_as_arg_3.py'
במקום המצוין.

   5| def f(*None):
             ^^^^

אני מנחש שניסית להשתמש במילת המפתח של פייתון
`None` כארגומנט בהגדרת פונקציה
היכן היה צפוי מזהה (שם משתנה).

(68) def: keyword cannot be argument in def - 4

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_keyword_as_arg_4.py", line 5
    def f(**None):
            ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_keyword_as_arg_4.py'
במקום המצוין.

   5| def f(**None):
              ^^^^

אני מנחש שניסית להשתמש במילת המפתח של פייתון
`None` כארגומנט בהגדרת פונקציה
היכן היה צפוי מזהה (שם משתנה).

(69) def: Python keyword as function name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_keyword_as_name.py", line 3
    def pass():
        ^^^^
SyntaxError: invalid syntax

    אינך יכול\ה להשתמש במילת מפתח של פייתון כשם פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_keyword_as_name.py'
במקום המצוין.

   3| def pass():
          ^^^^

ניסית להשתמש במילת המפתח של פייתון 'pass' כשם פונקציה.

בהמשך הקוד שלך יש שגיאות תחביר נוספות.

(70) def: list as argument - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_list_as_arg_1.py", line 1
    def test([x], y):  # list as first argument
             ^
SyntaxError: invalid syntax

    אינך יכול\ה להכיל רשימות מפורשות כארגומנטים של פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_list_as_arg_1.py'
במקום המצוין.

   1| def test([x], y):  # list as first argument
               ^

אינך יכול\ה להכיל רשימות מפורשות כארגומנטים של פונקציות.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(71) def: list as argument - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_list_as_arg_2.py", line 1
    def test(x, [y]):  # list as second argument, after comma
                ^
SyntaxError: invalid syntax

    אינך יכול\ה להכיל רשימות מפורשות כארגומנטים של פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_list_as_arg_2.py'
במקום המצוין.

   1| def test(x, [y]):  # list as second argument, after comma
                  ^

אינך יכול\ה להכיל רשימות מפורשות כארגומנטים של פונקציות.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(72) def: missing colon

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_missing_colon.py", line 1
    def test()
              ^
SyntaxError: expected ':'

    שכחת נקודתיים ':' ?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_missing_colon.py'
במקום המצוין.

   1| def test()
                ^

כתבת הצהרה שמתחילה ב
`def` אבל שכחת להוסיף נקודתיים `:` בסוף.

(73) def: missing comma between function args

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_missing_comma.py", line 4
    def a(b, c d):
               ^
SyntaxError: invalid syntax

    שכחת פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_missing_comma.py'
במקום המצוין.

   4| def a(b, c d):
               ^^^

פייתון מציין כי השגיאה נגרמת על ידי "d" שקרה מיד לאחר "c".
יתכן ששכחת פסיק בין פריטים בטופל,
או בין ארגומנטים של פונקציה,
במיקום המצוין על ידי ^.
אולי התכוונת ל

    def a(b, c, d):
              ^

(74) def: missing parentheses

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_missing_parens.py", line 3
    def name:
            ^
SyntaxError: invalid syntax

    שכחת סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_missing_parens.py'
במקום המצוין.

   3| def name:
              ^

אולי שכחת לכלול סוגריים.
אולי התכוונת לכתוב

     def name():

(75) def: missing parentheses around arguments

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_missing_parens_2.py", line 2
    def name a, b:
             ^
SyntaxError: invalid syntax

    שכחת סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_missing_parens_2.py'
במקום המצוין.

   2| def name a, b:
               ^

אולי שכחת לכלול סוגריים.
אולי התכוונת לכתוב

     def name (a, b):

(76) def: missing function name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_missing_name.py", line 3
    def ( arg )  :
        ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_missing_name.py'
במקום המצוין.

   3| def ( arg )  :
          ^

שכחת לציין את שם הפונקציה שלך.
התחביר הנכון הוא:
 def name ( ... ):

(77) def: name is parameter and global

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_name_is_parameter_and_global.py", line 6
    global x
    ^^^^^^^^
SyntaxError: name 'x' is parameter and global

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_name_is_parameter_and_global.py'
במקום המצוין.

   6|     global x
          ^^^^^^^^

אתה כולל את ההצהרה

         global x


המציין כי "x" הוא משתנה המוגדר מחוץ לפונקציה.
אתה משתמש גם באותו 'x' כארגומנט לפונקציה הזו
ובכך מציין כי היא צריכה להיות משתנה הידוע רק
בתוך הפונקציה, שהיא ההפך ממה שמשתמע מה"global ".

(78) def: non-default argument follows default argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_non_default_after_default.py", line 5
    def test(a=1, b):
                  ^
SyntaxError: non-default argument follows default argument

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_non_default_after_default.py'
במקום המצוין.

   5| def test(a=1, b):
                    ^

ב- Python, אתה יכול להגדיר פונקציות עם ארגומנטים מיקומיים בלבד

def f(a, b, c)

או רק ארגומנטים של מילות מפתח

def f(a = 1, b = 2, c = 3)

או שילוב של השניים

def f(1, 2, c = 3)

אבל עם טיעוני מילת המפתח שמופיעים אחרי כל אלה המיקומיים.
על פי פייתון, השתמשת בטיעונים מיקומיים אחרי מילות מפתח.

(79) Single number used as arg in function def

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_number_as_arg.py", line 1
    def f(1):
          ^
SyntaxError: invalid syntax

    אי אפשר  להשתמש במספרים כארגומנטים של פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_number_as_arg.py'
במקום המצוין.

   1| def f(1):
            ^

השתמשת במספר כארגומנט בעת הגדרת פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(80) Operator after **

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_operator_after_2star.py", line 1
    def test(**):
               ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_operator_after_2star.py'
במקום המצוין.

   1| def test(**):
                 ^

אחרי האופרטור '**' צריך להיות מזהה (שם משתנה).

(81) def: operator instead of comma

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_operator_instead_of_comma.py", line 1
    def test(a + b):
               ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_operator_instead_of_comma.py'
במקום המצוין.

   1| def test(a + b):
                 ^

לא יכולים להיות לך אופרטורים כארגומנטים של פונקציות.
אני חושד שעשית שגיאת כתיב וכתבת '+' במקום פסיק.
המשפט הבא אינו מכיל שגיאת תחביר:

     def test(a , b):

(82) def: operator instead of equal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_operator_instead_of_equal.py", line 1
    def test(a, b=3, c+None):
                      ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב סימן שווה?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_operator_instead_of_equal.py'
במקום המצוין.

   1| def test(a, b=3, c+None):
                        ^

לא יכולים להיות לך אופרטורים כארגומנטים של פונקציות.
אני חושד שעשית שגיאת כתיב וכתבת '+' במקום סימן שוויון.
המשפט הבא אינו מכיל שגיאת תחביר:

     def test(a, b=3, c=None):

(83) def: operator instead of name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_operator_instead_of_name.py", line 1
    def test(a, +, b):
                ^
SyntaxError: invalid syntax

    אינך יכול להשתמש ב- '+' כטיעון.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_operator_instead_of_name.py'
במקום המצוין.

   1| def test(a, +, b):
                  ^

אני חושד שעשית שגיאת כתיב וכתבת בטעות '+'.
אם תחליף אותו בשם משתנה ייחודי, התוצאה
לא יכיל שגיאת תחביר.

(84) def: positional argument follows keyword argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_positional_after_keyword_arg.py", line 5
    test(a=1, b)
               ^
SyntaxError: positional argument follows keyword argument

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_positional_after_keyword_arg.py'
במקום המצוין.

   5| test(a=1, b)
                 ^

ב- Python, אתה יכול לקרוא פונקציות עם ארגומנטים מיקוםיים בלבד

     f(1, 2, 3)

או רק ארגומנטים של מילות מפתח

     f(a = 1, b = 2, c = 3)

או שילוב של השניים

     f(1, 2, c = 3)

אבל עם טיעוני מילת המפתח שמופיעים אחרי כל אלה המיקומיים.
על פי פייתון, השתמשת בטיעונים מיקומיים אחרי מילות מפתח.

(85) def: semicolon instead of colon

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_semi_colon_instead_of_colon.py", line 1
    def test();
              ^
SyntaxError: expected ':'

    שכחת נקודתיים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_semi_colon_instead_of_colon.py'
במקום המצוין.

   1| def test();
                ^

פייתון ציפה לנקודתיים במיקום שצוין.
כתבת ';' במקום נקודתיים.

(86) def: set as argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_set_as_arg.py", line 1
    def test(y, {'a', 'b'}):  # set as second argument, after comma
                ^
SyntaxError: invalid syntax

    אינך יכול\ה לקבל שום מילון (dict) מפורש או סט (set) כטיעוני פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_set_as_arg.py'
במקום המצוין.

   1| def test(y, {'a', 'b'}):  # set as second argument, after comma
                  ^

אינך יכול\ה לקבל שום מילון (dict) מפורש או סט (set) כטיעוני פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(87) def: *arg before /

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_arg_before_slash.py", line 1
    def test(a, *arg, /):
                      ^
SyntaxError: invalid syntax

    '*arg' חייב להופיע אחרי '/' בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_arg_before_slash.py'
במקום המצוין.

   1| def test(a, *arg, /):
                        ^

`/` מציין כי הטיעונים הקודמים בהגדרת פונקציה
הם טיעונים עמדתיים.
'*arg' חייב להופיע אחרי '/' בהגדרת פונקציה.

(88) def: * used twice

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_used_only_once.py", line 1
    def test(a, *arg, *, b=1):
                      ^
SyntaxError: invalid syntax

    אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_used_only_once.py'
במקום המצוין.

   1| def test(a, *arg, *, b=1):
                        ^

אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.
יש להשתמש בו בעצמו, "*",
או בצורה '*arg', אך לא שניהם.

(89) def: * used twice

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_used_only_once_1.py", line 1
    def test(a, *, *):
                   ^
SyntaxError: invalid syntax

    אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_used_only_once_1.py'
במקום המצוין.

   1| def test(a, *, *):
                     ^

אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

(90) def: * used twice

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_used_only_once_2.py", line 1
    def test(a, *arg, *other):
                      ^
SyntaxError: invalid syntax

    אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_used_only_once_2.py'
במקום המצוין.

   1| def test(a, *arg, *other):
                        ^

אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.
השתמשת בו פעמיים, עם '*arg' ו- '*other'.

(91) def: * after **

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_after_2star.py", line 1
    def test(**kw, *arg):
                   ^
SyntaxError: invalid syntax

    אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_after_2star.py'
במקום המצוין.

   1| def test(**kw, *arg):
                     ^

`*arg` חייב להופיע לפני `** kw`.

(92) def: * after **

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_star_after_2star_2.py", line 1
    def test(**kw, *):
                   ^
SyntaxError: invalid syntax

    אפשר  להשתמש רק פעם אחת בהגדרת פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_star_after_2star_2.py'
במקום המצוין.

   1| def test(**kw, *):
                     ^

"** kw" חייב להופיע אחרי אופרטור "*".

(93) Single string used as arg in function def

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_string_as_arg.py", line 1
    def f("1"):
          ^^^
SyntaxError: invalid syntax

    אינך יכול להשתמש במחרוזות כארגומנטים של פונקציות.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_string_as_arg.py'
במקום המצוין.

   1| def f("1"):
            ^^^

השתמשת במחרוזת כארגומנט בעת הגדרת פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.

(94) def: tuple as function argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_tuple_as_arg_1.py", line 1
    def test((a, b), c):
             ^
SyntaxError: invalid syntax

    אתה לא יכול לקבל tuples מפורשים כארגומנטים של פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_tuple_as_arg_1.py'
במקום המצוין.

   1| def test((a, b), c):
               ^

אתה לא יכול לקבל tuples מפורשים כארגומנטים של פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.
צריך להקצות כל צמד לפרמטר ולפרק אותו
בתוך גוף הפונקציה.

(95) def: tuple as function argument - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\def_tuple_as_arg_2.py", line 1
    def test(a, (b, c)):
                ^
SyntaxError: invalid syntax

    אתה לא יכול לקבל tuples מפורשים כארגומנטים של פונקציה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\def_tuple_as_arg_2.py'
במקום המצוין.

   1| def test(a, (b, c)):
                  ^

אתה לא יכול לקבל tuples מפורשים כארגומנטים של פונקציה.
אפשר להשתמש רק במזהים (שמות משתנים) כארגומנטים של פונקציות.
צריך להקצות כל צמד לפרמטר ולפרק אותו
בתוך גוף הפונקציה.

(96) Deleting star expression - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\del_paren_star_1.py", line 1
    del (*x)
         ^^
SyntaxError: cannot use starred expression here

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\del_paren_star_1.py'
במקום המצוין.

   1| del (*x)
           ^^

אופרטור הכוכב "*" מתפרש כמשמעותו
יש להשתמש בפירוק חוזר כדי להקצות שם
לכל פריט של חוזר, וזה לא הגיוני כאן.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(97) Deleting star expression - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\del_paren_star_2.py", line 1
    del (*x,)
         ^^
SyntaxError: cannot delete starred

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\del_paren_star_2.py'
במקום המצוין.

   1| del (*x,)
           ^^

אופרטור הכוכב "*" מתפרש כמשמעותו
יש להשתמש בפירוק חוזר כדי להקצות שם
לכל פריט של חוזר, וזה לא הגיוני כאן.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(98) Cannot delete a constant

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_constant_keyword.py", line 1
    del True
        ^^^^
SyntaxError: cannot delete True

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_constant_keyword.py'
במקום המצוין.

   1| del True
          ^^^^

אינך יכול למחוק את הקבוע (constant ) 'True'.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(99) Cannot delete expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_expression.py", line 1
    del a.b.c[0] + 2
        ^^^^^^^^^^^^
SyntaxError: cannot delete expression

    You can only delete names of objects, or items in mutable containers
    such as `list`, `set`, or `dict`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_expression.py'
במקום המצוין.

   1| del a.b.c[0] + 2
          ^^^^^^^^^^^^

You cannot delete the expression `a.b.c[0] + 2`.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(100) Cannot delete function call

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_function_call.py", line 5
    del f(a)
        ^^^^
SyntaxError: cannot delete function call

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_function_call.py'
במקום המצוין.

   5| del f(a)
          ^^^^

ניסית למחוק שיחת פונקציה

     del f(a)
במקום למחוק את שם הפונקציה

     del f

(101) Cannot delete named expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_named_expression.py", line 1
    del (a := 5)
         ^^^^^^
SyntaxError: cannot delete named expression

    You can only delete names of objects, or items in mutable containers
    such as `list`, `set`, or `dict`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_named_expression.py'
במקום המצוין.

   1| del (a := 5)
           ^^^^^^

You cannot delete the named expression `(a := 5)`.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(102) Delete only names or items

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_names_or_items.py", line 1
    del a += b
          ^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_names_or_items.py'
במקום המצוין.

   1| del a += b
            ^^

You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(103) Deleting string literal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\delete_string_literal.py", line 1
    del "Hello world!"
        ^^^^^^^^^^^^^^
SyntaxError: cannot delete literal

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\delete_string_literal.py'
במקום המצוין.

   1| del "Hello world!"
          ^^^^^^^^^^^^^^

You cannot delete the literal `"Hello world!"`.
You can only delete names of objects, or items in mutable containers
such as `list`, `set`, or `dict`.

(104) Value missing in dict - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\dict_value_missing_1.py", line 1
    a = {1:2, 3}
              ^
SyntaxError: ':' expected after dictionary key

    Did you forget to write a dict value?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\dict_value_missing_1.py'
במקום המצוין.

   1| a = {1:2, 3}
                ^

It looks like the error occurred as you were writing a Python dict.
Perhaps you wrote a dict key without writing the corresponding value.

(105) Value missing in dict - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\dict_value_missing_2.py", line 2
    a = {1:2, 3:}
               ^
SyntaxError: expression expected after dictionary key and ':'

    Did you forget to write a dict value?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\dict_value_missing_2.py'
במקום המצוין.

   2| a = {1:2, 3:}
                 ^

It looks like the error occurred as you were writing a Python dict.
Perhaps you forgot to write a value after a colon.

(106) Value missing in dict - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\dict_value_missing_3.py", line 3
    a = {1:2, 3, 4:5}
              ^
SyntaxError: ':' expected after dictionary key

    Did you forget to write a dict value?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\dict_value_missing_3.py'
במקום המצוין.

   3| a = {1:2, 3, 4:5}
                ^

It looks like the error occurred as you were writing a Python dict.
Perhaps you wrote a dict key without writing the corresponding value.

(107) Value missing in dict - 4

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\dict_value_missing_4.py", line 4
    a = {1:2, 3:, 4:5}
               ^
SyntaxError: expression expected after dictionary key and ':'

    Did you forget to write a dict value?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\dict_value_missing_4.py'
במקום המצוין.

   4| a = {1:2, 3:, 4:5}
                 ^

It looks like the error occurred as you were writing a Python dict.
Perhaps you forgot to write a value after a colon.

(108) Different operators in a row

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\different_operators_in_a_row.py", line 1
    3 */ 4
       ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\different_operators_in_a_row.py'
במקום המצוין.

   1| 3 */ 4
        ^^

אי אפשר לכתוב שני אופרטורים אלה, "*" ו- "/",
עוקבים אחד אחרי השני. אולי כתבת אחד מהם בטעות
או ששכחת לכתוב משהו ביניהם.

(109) Dot followed by parenthesis

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\dot_before_paren.py", line 3
    print(len.('hello'))
              ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\dot_before_paren.py'
במקום המצוין.

   3| print(len.('hello'))
                ^

לא יכולה להיות לך נקודה `.` ואחריה "(".
אולי אתה צריך להחליף את הנקודה בפסיק.

(110) Extra token

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\duplicate_token.py", line 1
    print(1 , , 2)
              ^
SyntaxError: invalid syntax

    האם כתבת `,` פעמיים בטעות?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\duplicate_token.py'
במקום המצוין.

   1| print(1 , , 2)
                ^

אני מנחש שכתבת `,` פעמיים ברציפות בטעות.
אם זה המצב, עליך להסיר את השני.

(111) elif with no matching if

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\elif_not_matching_if.py", line 3
    elif True:
    ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\elif_not_matching_if.py'
במקום המצוין.

   3|    elif True:
         ^^^^

The `elif` keyword does not begin a code block that matches
an `if` block, possibly because `elif` is not indented correctly.

(112) Ellipsis written with extra dot

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\ellipsis_extra_dot.py", line 2
    ....
        ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב '...'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\ellipsis_extra_dot.py'
במקום המצוין.

   2|     ....
             ^

It looks like you meant to write `...` but added an extra `.` by mistake.

(113) else with no matching statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\else_no_matching_statement.py", line 3
    else:
    ^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\else_no_matching_statement.py'
במקום המצוין.

   3|    else:
         ^^^^

The `else` keyword does not begin a code block that matches
a valid code block, possibly because `else` is not indented correctly.

(114) Write elif, not else if

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\else_if_instead_of_elif.py", line 5
    else if True:
         ^^
SyntaxError: expected ':'

    אולי התכוונת לכתוב elseif.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\else_if_instead_of_elif.py'
במקום המצוין.

   5| else if True:
      ^^^^^^^

פייתון אמר לנו שהוא מצפה לנקודותיים במיקום המצוין.
עם זאת, הוספת נקודתיים או החלפת משהו אחר בנקודותיים
לא יתקן את הבעיה.
סביר שהתכוונת להשתמש במילת המפתח 'elif' של פייתון
אבל כתוב 'else if' במקום זאת.

(115) Write elif, not elseif

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\elseif_instead_of_elif.py", line 5
    elseif True:
           ^^^^
SyntaxError: invalid syntax

    אולי התכוונת לכתוב elseif.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\elseif_instead_of_elif.py'
במקום המצוין.

   5| elseif True:
      ^^^^^^

סביר שהתכוונת להשתמש במילת המפתח 'elif' של פייתון
אבל כתוב 'elseif' במקום זאת.

(116) EOL while scanning string literal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\eol_string_literal.py", line 3
    alphabet = 'abc
               ^
SyntaxError: unterminated string literal (detected at line 3)

    שכחת גרשיים לסיום?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\eol_string_literal.py'
במקום המצוין.

   3| alphabet = 'abc
                 ^

התחלת לכתוב מחרוזת עם גרש או מרכאות
אך מעולם לא סיימת את המחרוזת בציטוט\מרכאות נוסף בשורה זו.

(117) Used equal sign instead of colon

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\equal_sign_instead_of_colon.py", line 4
    ages = {'Alice'=22, 'Bob'=24}
            ^^^^^^^
SyntaxError: cannot assign to literal here. Maybe you meant '==' instead of '='?

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\equal_sign_instead_of_colon.py'
במקום המצוין.

   4| ages = {'Alice'=22, 'Bob'=24}
              ^^^^^^^

כתבת ביטוי כמו

     'Alice' = שם_משתנה
כאשר ''Alice'', בצד שמאל של סימן השווה,
הוא או כולל אובייקט בפועל מסוג str (מחרוזת)
וזה לא רק שמו של משתנה.

ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

It is possible that you used an equal sign `=` instead of a colon `:`
to assign values to keys in a dict.

(118) Parens around multiple exceptions

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\except_multiple_exceptions.py", line 3
    except NameError, ValueError as err:
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: multiple exception types must be parenthesized

    שכחת סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\except_multiple_exceptions.py'
במקום המצוין.

   3| except NameError, ValueError as err:
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^

אני מניח שרצית להשתמש באמירה של 'except'
 (תפוס)
עם מספר סוגי חריגים. אם זה המצב, אתה חייב
להקיף אותם בסוגריים.

(119) except with no matching try

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\except_no_try.py", line 1
    except Exception:
    ^^^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\except_no_try.py'
במקום המצוין.

   1| except Exception:
      ^^^^^^

The `except` keyword does not begin a code block that matches
a `try` block, possibly because `except` is not indented correctly.

(120) except or finally missing

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\except_or_finally.py", line 3
    something:
    ^^^^^^^^^
SyntaxError: expected 'except' or 'finally' block

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\except_or_finally.py'
במקום המצוין.

   3| something:
      ^^^^^^^^^

You wrote a `try` block which did not include an `except` nor a `finally` block.
Perhaps you meant to write either

    except:

or

    finally:

(121) Extra token

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\extra_token.py", line 1
    print(1 / 2) ==
                   ^
SyntaxError: invalid syntax

    האם כתבת את `==` בטעות?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\extra_token.py'
במקום המצוין.

   1| print(1 / 2) ==
                   ^^

אני מנחש שכתבת את `==` בטעות.
נראה כי הסרתו וכתיבת 'print(1 / 2)' פותרים את השגיאה.

(122) Binary f-string not allowed

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\f_string_binary.py", line 1
    greet = bf"Hello {name}"
              ^^^^^^^^^^^^^^
SyntaxError: invalid syntax

    'bf' היא קידומת מחרוזת לא חוקית.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\f_string_binary.py'
במקום המצוין.

   1| greet = bf"Hello {name}"
                ^^^^^^^^^^^^^^

אני מנחש שרצית מחרוזת f בינארית;
זה אסור.

(123) f-string: closing } not allowed

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\f_string_curly_not_allowed.py", line 1
    f"ab}"
          ^
SyntaxError: f-string: single '}' is not allowed

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\f_string_curly_not_allowed.py'
במקום המצוין.

   1| f"ab}"
      ^^^^^^

You have written an f-string which has an unmatched `}`.
If you want to print a single `}`, you need to write `}}` in the f-string;
otherwise, you need to add an opening `{`.

(124) f-string: missing closing }

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\f_string_expected_curly.py", line 1
    f"{ab"
          ^
SyntaxError: f-string: expecting '}'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\f_string_expected_curly.py'
במקום המצוין.

   1| f"{ab"
      ^^^^^^

You have written an f-string which has an unmatched `{`.
If you want to print a single `{`, you need to write `{{` in the f-string;
otherwise, you need to add a closing `}`.

(125) f-string: unterminated string

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\f_string_unterminated.py", line 4
    print(f"Bob is {age['Bob]} years old.")
                                          ^
SyntaxError: f-string: unterminated string

    אולי שכחת גרשי או גרשיים  לסיום.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\f_string_unterminated.py'
במקום המצוין.

   4| print(f"Bob is {age['Bob]} years old.")
                                            ^

בתוך מחרוזת f f"Bob is {age['Bob]} years old." `,
יש לך מחרוזת נוספת, שמתחילה ב
גרש (') או גרשיים ("), ללא סיום תואם.

(126) f-string with backslash

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\f_string_with_backslash.py", line 2
    print(f"{'\n'.join(names)}")
                               ^
SyntaxError: f-string expression part cannot include a backslash

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\f_string_with_backslash.py'
במקום המצוין.

   2| print(f"{'\n'.join(names)}")
                                 ^

כתבת מחרוזת f שהתוכן שלה `{...}`
כולל קו נטוי לאחור; זה אסור.
אולי אתה יכול להחליף את החלק שמכיל קו נטוי אחורי ב
משתנה כלשהו. לדוגמה, נניח שיש לך מחרוזת f כמו:

    f"{... 'hello\n' ...}"

אתה יכול לכתוב את זה בתור

    hello = 'שלום\n'
    f"{... שלום ...}"

(127) finally with no matching try

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\finally_no_try.py", line 1
    finally:
    ^^^^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\finally_no_try.py'
במקום המצוין.

   1| finally:
      ^^^^^^^

The `finally` keyword does not begin a code block that matches
a `try` block, possibly because `finally` is not indented correctly.

(128) Missing terms in for statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\for_missing_terms.py", line 1
    for:
       ^
SyntaxError: invalid syntax

    לולאת `for`(פור) דורשת לפחות 3 מונחים נוספים.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\for_missing_terms.py'
במקום המצוין.

   1| for:
         ^

לולאת `for` היא איטרציה על רצף:

    עבור אלמנט ברצף:
        ...

(129) Not a chance!

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\future_braces.py", line 1
    from __future__ import braces
    ^
SyntaxError: not a chance

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\future_braces.py'
במקום המצוין.

   1| from __future__ import braces
      ^^^^

אני חושד שכתבת 'מ-__עתיד__ ייבוא פלטה' בהמשך
הצעה של מישהו אחר. זה לעולם לא יעבוד.

בניגוד לשפות תכנות אחרות, בלוק הקוד של Python מוגדרים על ידי
רמת ההזחה שלהם, ולא על ידי שימוש בסוגריים מסולסלים, כמו `{...}`.

(130) Do not import * from __future__

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\future_import_star.py", line 1
    from __future__ import *
    ^
SyntaxError: future feature * is not defined

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\future_import_star.py'
במקום המצוין.

   1| from __future__ import *
      ^^^^

בעת שימוש בהצהרה 'from __future__ import',
עליך לייבא תכונות ספציפיות בשם.

התכונות הזמינות הן 'nested_scopes,
 generators,
 division,
 absolute_import,
 with_statement,
 print_function,
 unicode_literals,
 barry_as_FLUFL,
 generator_stop,
 annotations'.

(131) __future__ at beginning

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\future_must_be_first.py", line 3
    from __future__ import generators
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
SyntaxError: from __future__ imports must occur at the beginning of the file

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\future_must_be_first.py'
במקום המצוין.

   3|     from __future__ import generators
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

הצהרת `from __future__ import` משנה את הדרך שבה Python
מפרש את הקוד בקובץ.
זה חייב להופיע בתחילת הקובץ.

(132) Typo in __future__

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\future_typo.py", line 1
    from __future__ import divisio
    ^
SyntaxError: future feature divisio is not defined

    האם התכוונת ל 'division'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\future_typo.py'
במקום המצוין.

   1| from __future__ import divisio
      ^^^^

במקום 'divisio', אולי התכוונת לייבא 'division'.

(133) Unknown feature in __future__

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\future_unknown.py", line 1
    from __future__ import something
    ^
SyntaxError: future feature something is not defined

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\future_unknown.py'
במקום המצוין.

   1| from __future__ import something
      ^^^^

`something` אינה תכונה תקפה של המודול ` __future__`.

התכונות הזמינות הן 'nested_scopes,
 generators,
 division,
 absolute_import,
 with_statement,
 print_function,
 unicode_literals,
 barry_as_FLUFL,
 generator_stop,
 annotations'.

(134) Parenthesis around generator expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\generator_expression_parens.py", line 6
    f(x for x in L, 1)
      ^^^^^^^^^^^^
SyntaxError: Generator expression must be parenthesized

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\generator_expression_parens.py'
במקום המצוין.

   6| f(x for x in L, 1)
        ^^^^^^^^^^^^

אתה משתמש בביטוי מחולל, משהו מהצורה

     x עבור x בדבר

עליך להוסיף סוגריים המקיפים את הביטוי הזה.

(135) Space between names

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\hyphen_instead_of_underscore.py", line 4
    a-b = 2
    ^^^
SyntaxError: cannot assign to expression here. Maybe you meant '==' instead of '='?

    האם התכוונת ל 'a_b'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\hyphen_instead_of_underscore.py'
במקום המצוין.

   4| a-b = 2
      ^^^

כתבת ביטוי הכולל כמה פעולות מתמטיות
בצד שמאל של סימן השוויון שאמור להיות
משמש רק להקצאת ערך למשתנה.
אולי התכוונת לכתוב 'a_b' במקום 'a-b'

(136) Missing condition in if statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\if_missing_condition.py", line 1
    if:
      ^
SyntaxError: invalid syntax

    שכחת להוסיף תנאי.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\if_missing_condition.py'
במקום המצוין.

   1| if:
        ^

הצהרת 'if'(אם) דורשת תנאי:

     if (אם) מצב:
         ...

(137) use j instead of i

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\imaginary_i.py", line 3
    a = 3.0i
          ^
SyntaxError: invalid decimal literal

    האם התכוונת ל '3.0j'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\imaginary_i.py'
במקום המצוין.

   3| a = 3.0i
          ^^^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

אולי חשבת שאפשר להשתמש ב'אני' כדי לייצג
השורש הריבועי של `-1`. ב-Python, הסמל המשמש לכך הוא `j`
והחלק המורכב נכתב כ'מספר_כמה' מיד
ואחריו 'j', ללא רווחים ביניהם.
אולי התכוונת לכתוב `3.0j`.

(138) Import inversion: import X from Y

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\import_from.py", line 3
    import pen from turtle
               ^^^^
SyntaxError: invalid syntax

    האם התכוונת לfrom turtle import pen ( 'מ- turtle יבוא pen `) ?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\import_from.py'
במקום המצוין.

   3| import pen from turtle
      ^^^^^^     ^^^^

כתבת משהו כמו

    יבוא pen מ-turtle

במקום

    מ-turtle ייבוא pen

(139) IndentationError: expected an indented block

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\indentation_error_1.py", line 4
    pass
    ^^^^
IndentationError: expected an indented block after 'if' statement on line 3

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\indentation_error_1.py'
במקום המצוין.

   4| pass
      ^^^^

Line `4` identified above was expected to begin a new indented block.

(140) IndentationError: unexpected indent

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\indentation_error_2.py", line 4
    pass
    ^
IndentationError: unexpected indent

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\indentation_error_2.py'
במקום המצוין.

   4|       pass
            ^^^^

Line `4` identified above is more indented than expected.

(141) IndentationError: unindent does not match …

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\indentation_error_3.py", line 5
    pass
        ^
IndentationError: unindent does not match any outer indentation level

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\indentation_error_3.py'
במקום המצוין.

   5|     pass
          ^^^^

Line `5` identified above is less indented than expected.

(142) IndentationError: missing continuation line

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\indentation_error_4.py", line 6
    "c"
    ^
IndentationError: unexpected indent

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\indentation_error_4.py'
במקום המצוין.

   6|          "c"
               ^^^

Line `6` identified above is more indented than expected.

עם זאת, שורה 6, המזוהה כבעיה,
מורכב ממחרוזת אחת, וזה גם המקרה
עבור השורה הקודמת.
אולי התכוונת לכלול דמות המשך, '\',
בסוף השורה 5.

(143) Forgot ‘o’ for octal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\integer_with_leading_zero_1.py", line 1
    x = 01
        ^
SyntaxError: leading zeros in decimal integer literals are not permitted; use an 0o prefix for octal integers

    האם התכוונת ל '0o1'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\integer_with_leading_zero_1.py'
במקום המצוין.

   1| x = 01
          ^

אולי התכוונת לכתוב את המספר האוקטלי '0o1'
ושכחת את האות 'או', או שאולי התכוונת לכתוב
מספר שלם עשרוני ולא ידעת שהוא לא יכול להתחיל באפס.

(144) Integer with leading zeros

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\integer_with_leading_zero_2.py", line 1
    x = 000_123_456
        ^^^^
SyntaxError: leading zeros in decimal integer literals are not permitted; use an 0o prefix for octal integers

    האם התכוונת ל '123_456'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\integer_with_leading_zero_2.py'
במקום המצוין.

   1| x = 000_123_456
          ^^^

אולי התכוונת לכתוב את המספר השלם '123_456'
ולא ידעת שזה לא יכול להתחיל באפס.

(145) Invalid character in identifier

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_character_in_identifier.py", line 6
    🤖 = 'Reeborg'
    ^
SyntaxError: invalid character '🤖' (U+1F916)

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_character_in_identifier.py'
במקום המצוין.

   6| 🤖 = 'Reeborg'
      ^

Python מציין שהשתמשת בתו unicode '🤖'
מה שאסור.

(146) Invalid decimal literal - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_decimal_literal1.py", line 1
    a = 1f
        ^
SyntaxError: invalid decimal literal

    [הערה: '1 * f' יהיה תקף גם
    מאחר ש '1' הוא מספר מורכב.]

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_decimal_literal1.py'
במקום המצוין.

   1| a = 1f
          ^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

שמות חוקיים אינם יכולים להתחיל במספר.
[הערה: '1 * f' יהיה תקף גם
מאחר ש '1' הוא מספר מורכב.]

(147) Invalid encoding

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_encoding.py", line 2, in <module>
    compile(source, filename="example.py", mode="exec")
  File "TESTS:\example.py", line 0
SyntaxError: encoding problem: utf8 with BOM

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\example.py'


קידוד הקובץ לא היה חוקי.

(148) Invalid hexadecimal number

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_hexadecimal.py", line 3
    a = 0x123g4
            ^
SyntaxError: invalid hexadecimal literal

    האם טעית בכתיבת מספר שלם הקסדצימלי?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_hexadecimal.py'
במקום המצוין.

   3| a = 0x123g4
          ^^^^^^^

נראה שהשתמשת בתו לא חוקי (`g`) במספר הקסדצימלי.

מספרים הקסדצימליים הם בסיס 16 מספרים שלמים המשתמשים בסמלים '0' עד '9'
לייצג את הערכים 0 עד 9, ואת האותיות 'a' עד 'f' (או 'A' עד 'F')
לייצג ערכים 10 עד 15.
ב-Python, מספרים הקסדצימליים מתחילים ב-'0x' או ב-'0X',
ואחריו התווים המשמשים לייצג את הערך של אותו מספר שלם.

(149) Valid names cannot begin with a number

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_identifier.py", line 3
    36abc = 3
     ^
SyntaxError: invalid decimal literal

    שמות חוקיים אינם יכולים להתחיל במספר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_identifier.py'
במקום המצוין.

   3| 36abc = 3
      ^^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

שמות חוקיים אינם יכולים להתחיל במספר.

(150) Valid names cannot begin with a number - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_identifier_2.py", line 3
    tau = 2pi
          ^
SyntaxError: invalid decimal literal

    [הערה: '2 * pi' יהיה תקף גם
    מאחר ש '2' הוא מספר מורכב.]

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_identifier_2.py'
במקום המצוין.

   3| tau = 2pi
            ^^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

שמות חוקיים אינם יכולים להתחיל במספר.
[הערה: '2 * pi' יהיה תקף גם
מאחר ש '2' הוא מספר מורכב.]

(151) Valid names cannot begin with a number - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_identifier_3.py", line 1
    3job  # could be entered in a repl
     ^
SyntaxError: invalid imaginary literal

    [הערה: '3 * job' יהיה תקף גם
    מאחר ש '3' הוא מספר מורכב.]

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_identifier_3.py'
במקום המצוין.

   1| 3job  # could be entered in a repl
      ^^^^

שמות חוקיים אינם יכולים להתחיל במספר.
[הערה: '3 * job' יהיה תקף גם
מאחר ש '3' הוא מספר מורכב.]

[הערה: `3j * ob` יהיה גם חוקי
מכיוון ש-'3j' הוא מספר מרוכב.]

(152) Valid names cannot begin with a number - 4

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_identifier_4.py", line 1
    3job = 1
     ^
SyntaxError: invalid imaginary literal

    שמות חוקיים אינם יכולים להתחיל במספר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_identifier_4.py'
במקום המצוין.

   1| 3job = 1
      ^^^

שמות חוקיים אינם יכולים להתחיל במספר.

(153) Valid names cannot begin with a number - 5

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_identifier_5.py", line 1
    print(42java)
            ^
SyntaxError: invalid imaginary literal

    [הערה: '42 * java' יהיה תקף גם
    מאחר ש '42' הוא מספר מורכב.]

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_identifier_5.py'
במקום המצוין.

   1| print(42java)
            ^^^^

שמות חוקיים אינם יכולים להתחיל במספר.
[הערה: '42 * java' יהיה תקף גם
מאחר ש '42' הוא מספר מורכב.]

[הערה: `42j * ava` יהיה גם חוקי
מכיוון ש-'42j' הוא מספר מרוכב.]

(154) Keyword can’t be an expression

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_keyword_argument.py", line 7
    a = dict('key'=1)
             ^^^^^^
SyntaxError: expression cannot contain assignment, perhaps you meant "=="?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_keyword_argument.py'
במקום המצוין.

   7| a = dict('key'=1)
               ^^^^^^

You likely called a function with a named argument:

    a_function(invalid=something)

where `invalid` is not a valid variable name in Python
either because it starts with a number, or is a string,
or contains a period, etc.

(155) Named argument can’t be a Python keyword

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_keyword_argument_2.py", line 7
    a = dict(True=1)
             ^^^^^
SyntaxError: cannot assign to True

    You cannot assign a value to `True`.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_keyword_argument_2.py'
במקום המצוין.

   7| a = dict(True=1)
               ^^^^^

`True` הוא קבוע בפיתון; אינך יכול להקצות לו ערך אחר.

(156) Invalid non printable character

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_non_printable_char.py", line 2, in <module>
    eval(s)
  File "<string>", line 1
    print("Hello")
         ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 '<string>'
במקום המצוין.

   1| print("Hello")
           ^

Your code contains the invalid non-printable character '\x17'.

(157) Invalid octal number

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\invalid_octal.py", line 3
    b = 0O1876
           ^
SyntaxError: invalid digit '8' in octal literal

    האם טעית בכתיבת מספר שלם אוקטלי?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\invalid_octal.py'
במקום המצוין.

   3| b = 0O1876
             ^^^

It looks like you used an invalid character (`8`) in an octal number.

Octal numbers are base 8 integers that only use the symbols `0` to `7`
to represent values.
In Python, octal numbers start with either `0o` or `0O`,
(the digit zero followed by the letter `o`)
followed by the characters used to represent the value of that integer.

(158) Inverted operators 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\inverted_operators.py", line 1
    a =< 3
       ^
SyntaxError: invalid syntax

    כתבת אופרטורים בסדר לא נכון?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\inverted_operators.py'
במקום המצוין.

   1| a =< 3
        ^^

נראה שכתבת שני אופרטורים ('=' ו- '<')
בסדר הלא נכון: '=<' במקום '<='.

(159) Inverted operators 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\inverted_operators_2.py", line 1
    a =<* 3
       ^
SyntaxError: invalid syntax

    כתבת אופרטורים בסדר לא נכון?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\inverted_operators_2.py'
במקום המצוין.

   1| a =<* 3
        ^^

נראה שכתבת שני אופרטורים ('=' ו- '<')
בסדר הלא נכון: '=<' במקום '<='.

עם זאת, שינוי כזה עדיין לא היה נכון
כל שגיאות התחביר בקוד שכתבת.

(160) Iteration variable unpacking in comprehension

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\iteration_unpacking_in_comprehension.py", line 1
    [*x for x in xs]
     ^^
SyntaxError: iterable unpacking cannot be used in comprehension

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\iteration_unpacking_in_comprehension.py'
במקום המצוין.

   1| [*x for x in xs]
       ^^

You cannot use the `*` operator to unpack the iteration variable
in a comprehension.

The following statement has no syntax error:

    [x for x in xs]

(161) Keyword arg only once in function call

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\keyword_arg_repeated.py", line 4
    f(ad=1, ad=2)
            ^^^^
SyntaxError: keyword argument repeated: ad

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\keyword_arg_repeated.py'
במקום המצוין.

   4| f(ad=1, ad=2)
              ^^^^

קראת לפונקציה שחוזרת על אותו ארגומנט של מילת מפתח ('ad').
כל ארגומנט של מילת מפתח צריך להופיע רק פעם אחת בשיחת פונקציה.

(162) Keyword as attribute

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\keyword_as_attribute.py", line 12
    a.pass = 2
      ^^^^
SyntaxError: invalid syntax

    לא ניתן להשתמש ב- 'pass' כתכונה.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\keyword_as_attribute.py'
במקום המצוין.

   12| a.pass = 2
         ^^^^

אינך יכול להשתמש במילת המפתח של פייתון 'pass' כתכונה.

(163) lambda with parentheses around arguments

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\lambda_with_parens.py", line 2
    x = lambda (a, b): a + b
               ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\lambda_with_parens.py'
במקום המצוין.

   2| x = lambda (a, b): a + b
                 ^

`lambda` אינו מאפשר סוגריים סביב טיעוניו.
זה מותר ב- Python 2 אך זה לא מותר ב- Python 3.

(164) lambda with tuple as argument

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\lambda_with_tuple_argument.py", line 2
    x = lambda a, (b, c): a + b + b
                  ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\lambda_with_tuple_argument.py'
במקום המצוין.

   2| x = lambda a, (b, c): a + b + b
                    ^

אתה לא יכול לקבל tuples מפורשים כטיעונים.
הקצה כל tuple לפרמטר ופרק אותו
בתוך גוף הפונקציה.

(165) Assign to literal in for loop

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\literal_in_for_loop.py", line 1
    for "char" in "word":
        ^^^^^^
SyntaxError: cannot assign to literal

    ניתן להקצות אובייקטים רק למזהים (שמות משתנים).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\literal_in_for_loop.py'
במקום המצוין.

   1| for "char" in "word":
          ^^^^^^

לולאת פור (for) חייבת להיות בתבנית:

     עבור XXX ברצף:

כאשר 'XXX' חייב להכיל רק מזהים (שמות משתנים)
ולא מילוליות כמו '"char"'.

(166) IndentationError/SyntaxError depending on version

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_code_block.py", line 4
IndentationError: expected an indented block after 'for' statement on line 3

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_code_block.py'
במקום המצוין.

   3| for i in range(10):
-->4|
                        ^

Line `4` identified above was expected to begin a new indented block.

(167) IndentationError/SyntaxError depending on version - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_code_block_2.py", line 6
IndentationError: expected an indented block after 'for' statement on line 3

'IndentationError' מתרחשת כאשר שורת קוד היא
לא מיושר אנכית עם קווים אחרים כצפוי.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_code_block_2.py'


   3| for i in "test":
   4|

Line `6` identified above was expected to begin a new indented block.

(168) Missing colon - if

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_colon_if.py", line 3
    if True
           ^
SyntaxError: expected ':'

    שכחת נקודתיים ':' ?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_colon_if.py'
במקום המצוין.

   3| if True
             ^

כתבת הצהרה שמתחילה ב
`if` אבל שכחת להוסיף נקודתיים `:` בסוף.

(169) Missing colon - while

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_colon_while.py", line 3
    while True  # a comment
                ^^^^^^^^^^^
SyntaxError: expected ':'

    שכחת נקודתיים ':' ?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_colon_while.py'
במקום המצוין.

   3| while True  # a comment
                ^

כתבת לולאה של `while `אבל
שכחת להוסיף נקודתיים `:` בסוף

(170) Missing comma in a dict

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_comma_in_dict.py", line 4
    'b': 2
         ^-->
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    שכחת פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_comma_in_dict.py'
במקום המצוין.

   3| a = {'a': 1,
-->4|      'b': 2
                ^-->
-->5|      'c': 3,
           ^^^
   6| }

פייתון מציין כי השגיאה נגרמת על ידי "'c'" שקרה מיד לאחר "2".
ייתכן ששכחת פסיק בין פריטים בסט או dict
במיקום המצוין על ידי ^.
אולי התכוונת ל

    a = {'a': 1,
         'b': 2,
               ^
         'c': 3,
    }

(171) Missing comma between strings in a dict

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_comma_in_dict_2.py", line 4
    'c': '3',
       ^
SyntaxError: invalid syntax

    שכחת פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_comma_in_dict_2.py'
במקום המצוין.

   2| a = {'a': '1',
   3|      'b': '2'
-->4|      'c': '3',
              ^
   5| }

אני מנחש ששכחת פסיק בין שני מחרוזות
בעת הגדרת מילון (dict).
```
a = {'a': '1',
     'b': '2',
             ^
     'c': '3',
}
```

(172) Missing comma in a list

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_comma_in_list.py", line 3
    a = [1, 2  3]
            ^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    שכחת משהו בין '2' ל- '3'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_comma_in_list.py'
במקום המצוין.

   3| a = [1, 2  3]
              ^^^^

פייתון מציין כי השגיאה נגרמת על ידי "3" שקרה מיד לאחר "2".
ייתכן ששכחת פסיק בין פריטים ברשימה
במיקום המצוין על ידי ^.
אולי התכוונת להכניס אופרטור כמו '+, -, *'
בין `2` ו- `3`.
שורות הקוד הבאות לא יגרמו לשום 'SyntaxError':
    a = [1, 2,   3]
    a = [1, 2 +   3]
    a = [1, 2 -   3]
    a = [1, 2 *   3]
הערה: אלה רק חלק מהאפשרויות האפשריות וזה
חלקם עשויים להעלות סוגים אחרים של חריגים.

(173) Missing comma in a set

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_comma_in_set.py", line 3
    a = {1, 2  3}
            ^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    שכחת משהו בין '2' ל- '3'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_comma_in_set.py'
במקום המצוין.

   3| a = {1, 2  3}
              ^^^^

פייתון מציין כי השגיאה נגרמת על ידי "3" שקרה מיד לאחר "2".
ייתכן ששכחת פסיק בין פריטים בסט או dict
במיקום המצוין על ידי ^.
אולי התכוונת להכניס אופרטור כמו '+, -, *'
בין `2` ו- `3`.
שורות הקוד הבאות לא יגרמו לשום 'SyntaxError':
    a = {1, 2,   3}
    a = {1, 2 +   3}
    a = {1, 2 -   3}
    a = {1, 2 *   3}
הערה: אלה רק חלק מהאפשרויות האפשריות וזה
חלקם עשויים להעלות סוגים אחרים של חריגים.

(174) Missing comma in a tuple

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_comma_in_tuple.py", line 3
    a = (1, 2  3)
            ^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    שכחת משהו בין '2' ל- '3'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_comma_in_tuple.py'
במקום המצוין.

   3| a = (1, 2  3)
              ^^^^

פייתון מציין כי השגיאה נגרמת על ידי "3" שקרה מיד לאחר "2".
יתכן ששכחת פסיק בין פריטים בטופל,
או בין ארגומנטים של פונקציה,
במיקום המצוין על ידי ^.
אולי התכוונת להכניס אופרטור כמו '+, -, *'
בין `2` ו- `3`.
שורות הקוד הבאות לא יגרמו לשום 'SyntaxError':
    a = (1, 2,   3)
    a = (1, 2 +   3)
    a = (1, 2 -   3)
    a = (1, 2 *   3)
הערה: אלה רק חלק מהאפשרויות האפשריות וזה
חלקם עשויים להעלות סוגים אחרים של חריגים.

(175) For loop missing ‘in’ operator

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_in_with_for.py", line 1
    for x range(4):
          ^^^^^
SyntaxError: invalid syntax

    שכחת לכתוב 'in'(בתוך)?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_in_with_for.py'
במקום המצוין.

   1| for x range(4):
            ^^^^^

נראה ששכחת להשתמש במילת המפתח 'in'
 (בתוך)
כחלק מהצהרת `for ' (פור). אולי התכוונת ל:

     for x in range(4):

(176) Missing parenthesis for range

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\missing_parens_for_range.py", line 1
    for i in range 3:
                   ^
SyntaxError: invalid syntax

    שכחת לכתוב סוגריים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\missing_parens_for_range.py'
במקום המצוין.

   1| for i in range 3:
                     ^

נראה ששכחת להשתמש בסוגריים עם 'range'('טווח').

אולי התכוונת ל: for i in range( 3):

(177) Misspelled Python keyword

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\misspelled_keyword.py", line 2
    is i in range(3):
    ^^
SyntaxError: invalid syntax

    האם התכוונת ל "if i in range(3):"?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\misspelled_keyword.py'
במקום המצוין.

   2| is i in range(3):
      ^^

אולי התכוונת לכתוב 'if' וביצעת שגיאת כתיב.
השורה הנכונה עשויה להיות 'if i in range(3):'

(178) Name is global and nonlocal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\name_is_global_and_nonlocal.py", line 7
    global xy
    ^^^^^^^^^
SyntaxError: name 'xy' is nonlocal and global

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\name_is_global_and_nonlocal.py'
במקום המצוין.

   7|     global xy
          ^^^^^^^^^

הצהרת על 'xy' כמשתנה גלובלי וגם לא מיקומי (global & nonlocal).
משתנה יכול להיות גלובלי או לא מקומי, אך לא שניהם בו זמנית.

(179) Name is parameter and nonlocal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\name_is_param_and_nonlocal.py", line 5
    nonlocal x
    ^^^^^^^^^^
SyntaxError: name 'x' is parameter and nonlocal

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\name_is_param_and_nonlocal.py'
במקום המצוין.

   5|     nonlocal x
          ^^^^^^^^^^

השתמשת ב- 'x' כפרמטר לפונקציה
לפני שמכריזים עליו גם כמשתנה לא -מקומי (nonlocal):
'x' לא יכול להיות שניהם בו זמנית.

(180) nonlocal variable not found

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\no_binding_for_nonlocal.py", line 5
    nonlocal ab
    ^^^^^^^^^^^
SyntaxError: no binding for nonlocal 'ab' found

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\no_binding_for_nonlocal.py'
במקום המצוין.

   5|     nonlocal ab
          ^^^^^^^^^^^

הכרזת על המשתנה 'ab' כ-
משתנה לא-מקומי (nonlocal) אך לא ניתן למצוא אותו.

(181) nonlocal variable not found at module level

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\nonlocal_at_module.py", line 4
    nonlocal cd
    ^^^^^^^^^^^
SyntaxError: nonlocal declaration not allowed at module level

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\nonlocal_at_module.py'
במקום המצוין.

   4| nonlocal cd
      ^^^^^^^^^^^

השתמשת במילת המפתח הלא-מקומית (nonlocal) ברמת מודול.
מילת המפתח הלא-מקומית (nonlocal) מתייחסת למשתנה בתוך פונקציה
ונותנת ערך מחוץ לפונקציה זו.

(182) Same operator twice in a row

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\operator_twice_in_a_row.py", line 1
    4****5
       ^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\operator_twice_in_a_row.py'
במקום המצוין.

   1| 4****5
       ^^^^

אי אפשר לכתוב את אותו אופרטור, '**', פעמיים ברציפות.
אולי כתבת אחד מהם בטעות
או ששכחת לכתוב משהו ביניהם.

(183) Using pip from interpreter

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\pip_install_1.py", line 2
    pip install friendly
        ^^^^^^^
SyntaxError: invalid syntax

    לא ניתן להשתמש ב- Pip במתורגמן של פייתון.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\pip_install_1.py'
במקום המצוין.

   2| pip install friendly
          ^^^^^^^

נראה כאילו אתה מנסה להשתמש ב- pip להתקנת מודול.
`pip` היא פקודה שצריכה לפעול במסוף,
לא מהמתורגמן של פייתון.

(184) Using pip from interpreter 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\pip_install_2.py", line 2
    python -m pip install friendly
              ^^^
SyntaxError: invalid syntax

    לא ניתן להשתמש ב- Pip במתורגמן של פייתון.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\pip_install_2.py'
במקום המצוין.

   2| python -m pip install friendly
                ^^^

נראה כאילו אתה מנסה להשתמש ב- pip להתקנת מודול.
`pip` היא פקודה שצריכה לפעול במסוף,
לא מהמתורגמן של פייתון.

(192) Calling python from interpreter

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\python_interpreter.py", line 1
    python -i friendly
              ^^^^^^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\python_interpreter.py'
במקום המצוין.

   1| python -i friendly
                ^^^^^^^^

אני מנחש שאתה מנסה להשתמש ב- Python להפעלת תוכנית.
עליך לעשות זאת ממסוף ולא של מתורגמן פייתון.

(193) problem with assigning a variable to Python

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\python_not_interpreter.py", line 1
    python = a b
               ^
SyntaxError: invalid syntax

    שכחת משהו בין 'a' ל- 'b'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\python_not_interpreter.py'
במקום המצוין.

   1| python = a b
               ^^^

פייתון מציין כי השגיאה נגרמת על ידי "b" שקרה מיד לאחר "a".
אולי התכוונת להכניס אופרטור כמו '+; -; *; ,'
בין `a` ו- `b`.
שורות הקוד הבאות לא יגרמו לשום 'SyntaxError':
    python = a +  b
    python = a -  b
    python = a *  b
    python = a,  b
הערה: אלה רק חלק מהאפשרויות האפשריות וזה
חלקם עשויים להעלות סוגים אחרים של חריגים.

(194) Quote inside a string

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\quote_inside_string.py", line 3
    message = 'I don't mind.'
                            ^
SyntaxError: unterminated string literal (detected at line 3)

    אולי שכחת לברוח מדמות ציטוט.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\quote_inside_string.py'
במקום המצוין.

   3| message = 'I don't mind.'
                              ^

I suspect that you were trying to use a quote character inside a string
that was enclosed in quotes of the same kind.
Perhaps you should have escaped the inner quote character:

    message = 'I don\'t mind.'
                    ^^

(195) Raising multiple exceptions

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\raise_multiple_exceptions.py", line 2
    raise X, Y
           ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\raise_multiple_exceptions.py'
במקום המצוין.

   2| raise X, Y
             ^

נראה שאת\ה מנסה להעלות חריג באמצעות תחביר python 2.

(196) Cannot use return outside function

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\return_outside_function.py", line 3
    return
    ^^^^^^
SyntaxError: 'return' outside function

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\return_outside_function.py'
במקום המצוין.

   3| return
      ^^^^^^

אתה יכול להשתמש רק בהצהרת return(החזר) בתוך פונקציה או שיטה.

(197) Missing exponent for scientific notation

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\scientific_notation_missing_exponent.py", line 1
    a = 1.5e
          ^
SyntaxError: invalid decimal literal

    Did you mean `1.5e0`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\scientific_notation_missing_exponent.py'
במקום המצוין.

   1| a = 1.5e
          ^^^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

Did you mean `1.5e0`?
Perhaps you meant to write `1.5e0` in scientific notation
and forgot the numerical value for the exponent.

(198) Semicolon instead of colon

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\semi_colon_instead_of_colon.py", line 1
    if True;  # A comment
           ^
SyntaxError: invalid syntax

    התכוונת לכתוב נקודתיים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\semi_colon_instead_of_colon.py'
במקום המצוין.

   1| if True;  # A comment
             ^

כתבת נקודה-פסיק, `;`, שם היה צפוי נקודתיים.

(199) Semicolon instead of comma - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\semi_colon_instead_of_comma_1.py", line 1
    a = [1, 2; 3]
             ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\semi_colon_instead_of_comma_1.py'
במקום המצוין.

   1| a = [1, 2; 3]
               ^

כתבת נקודה-פסיק, `;`, שם היה צפוי פסיק.

(200) Semicolon instead of commas - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\semi_colon_instead_of_comma_2.py", line 1
    a = [1; 2; 3]
          ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב פסיקים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\semi_colon_instead_of_comma_2.py'
במקום המצוין.

   1| a = [1; 2; 3]
            ^

כתבת נקודה-פסיק, `;`, היכן שציפו לפסיקים.

(201) Semicolon instead of commas - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\semi_colon_instead_of_comma_3.py", line 1
    a = [1; 2; 3];
          ^
SyntaxError: invalid syntax

    האם התכוונת לכתוב פסיקים?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\semi_colon_instead_of_comma_3.py'
במקום המצוין.

   1| a = [1; 2; 3];
            ^

כתבת נקודה-פסיק, `;`, היכן שציפו לפסיקים.

(202) Code block inside comprehension

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\should_be_comprehension.py", line 2
    for i in 1, 2, 3:
    ^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\should_be_comprehension.py'
במקום המצוין.

   1| a = [
-->2|     for i in 1, 2, 3:
          ^^^
   3|         i**2
   4| ]

Perhaps you wrote a statement beginning a code block
intended to be part of a list comprehension.
You cannot have separate code blocks inside list comprehensions.

If this explanation is incorrect, please report this case.

(203) Single = instead of double == with if

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\single_equal_with_if.py", line 3
    if i % 2 = 0:
       ^^^^^
SyntaxError: cannot assign to expression here. Maybe you meant '==' instead of '='?

    אולי היית צריך\ה '==' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\single_equal_with_if.py'
במקום המצוין.

   3|     if i % 2 = 0:
             ^^^^^

כתבת ביטוי הכולל כמה פעולות מתמטיות
בצד שמאל של סימן השוויון שאמור להיות
משמש רק להקצאת ערך למשתנה.

(204) Single = instead of double == with elif

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\single_equal_with_elif.py", line 5
    elif i % 2 = 0:
         ^^^^^
SyntaxError: cannot assign to expression here. Maybe you meant '==' instead of '='?

    אולי היית צריך\ה '==' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\single_equal_with_elif.py'
במקום המצוין.

   5|     elif i % 2 = 0:
               ^^^^^

כתבת ביטוי הכולל כמה פעולות מתמטיות
בצד שמאל של סימן השוויון שאמור להיות
משמש רק להקצאת ערך למשתנה.

(205) Single = instead of double == with while

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\single_equal_with_while.py", line 4
    while a = 1:
          ^^^^^
SyntaxError: invalid syntax. Maybe you meant '==' or ':=' instead of '='?

    אולי היית צריך '==' או ': =' במקום '='.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\single_equal_with_while.py'
במקום המצוין.

   4| while a = 1:
            ^^^^^

השתמשת באופרטור מקוצר  `=`; אולי התכוונת להשתמש
במפעיל שוויון, `==`, או במפעיל ישיר `: =`.

(206) Space between operators 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\space_between_operators_1.py", line 1
    a = 2 * * 5
            ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\space_between_operators_1.py'
במקום המצוין.

   1| a = 2 * * 5
            ^ ^

אי אפשר לכתוב את אותו אופרטור, '*', פעמיים ברציפות.
אולי כתבת אחד מהם בטעות
או ששכחת לכתוב משהו ביניהם.
או שאולי כללת רווח בטעות בין שני המפעילים
ונועד לכתוב '**' כמפעיל יחיד.

(207) Space between operators 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\space_between_operators_2.py", line 1
    a / = b
        ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\space_between_operators_2.py'
במקום המצוין.

   1| a / = b
        ^ ^

אי אפשר לכתוב שני אופרטורים אלה, "/" ו- "=",
עוקבים אחד אחרי השני. אולי כתבת אחד מהם בטעות
או ששכחת לכתוב משהו ביניהם.
או שאולי כללת רווח בטעות בין שני המפעילים
ונועד לכתוב '/=' כמפעיל יחיד.

(208) Space in variable name

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\space_in_variable_name.py", line 1
    my name = André
       ^^^^
SyntaxError: invalid syntax

    האם התכוונת ל 'my_name'?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\space_in_variable_name.py'
במקום המצוין.

   1| my name = André
         ^^^^

לא ניתן לכלול רווחים במזהים (שמות משתנים).
אולי התכוונת ל`my_name`?

(209) Wrong target for star assignment

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\star_assignment_target.py", line 1
    *a = 1
    ^^
SyntaxError: starred assignment target must be in a list or tuple

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\star_assignment_target.py'
במקום המצוין.

   1| *a = 1
      ^^

A star assignment must be of the form:

    ... *name = list_or_tuple

(210) Too many nested blocks

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\too_many_nested_blocks.py", line 22
    while 22:
    ^-->
SyntaxError: too many statically nested blocks

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\too_many_nested_blocks.py'
במקום המצוין.

   22|                      while 22:
                            ^^^^^

Your code is too complex for Python:
you need to reduce the number of indented code blocks
contained inside other code blocks.

(211) Too many nested parentheses.

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\too_many_parentheses.py", line 4
    ((((((((((((((((((((((((((((((((((
                                     ^
SyntaxError: too many nested parentheses

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\too_many_parentheses.py'
במקום המצוין.

   1| ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((
   2|     ((((((((((((((((((((((((((((((((((((((((((((((((((((((((
   3|         (((((((((((((((((((((((((((((((((((((((((((((((((((
-->4|             ((((((((((((((((((((((((((((((((((
                                                   ^
   5|                                              ))))))))))))))))))))))))))))))))))))))))))))))))))
   6|         )))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))
   7|     ))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))

Your code is too complex for Python:
you need to reduce the number of parentheses
contained inside other parentheses.

(212) Trailing comma in import statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\trailing_comma_in_import.py", line 2
    from math import sin, cos,
                              ^
SyntaxError: trailing comma not allowed without surrounding parentheses

    כתבת פסיק בטעות?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\trailing_comma_in_import.py'
במקום המצוין.

   2| from math import sin, cos,
                               ^

Python indicates that you need to surround an expression
ending with a comma by parentheses.
However, if you remove the last comma, there will be no syntax error.
Perhaps you meant to write

`from math import sin, cos`

(213) Triple-equal sign

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\triple_equal.py", line 3
    x = y === z
            ^
SyntaxError: invalid syntax

    האם התכוונת להשתמש ב- 'is' (הוא) במקום '==='?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\triple_equal.py'
במקום המצוין.

   3| x = y === z
            ^^^

כתבת שלושה סימנים שווים ברצף. זה דבר שמותר בחלק
משפות תכנות, אך לא ב- פייתון. כדי לבדוק אם שני אובייקטים
שווים, השתמש בשני סימני שוויון, `==`; כדי לראות אם שני שמות מייצגים
אותו אובייקט בדיוק, השתמש באופרטור `is`.

(214) Unclosed bracket

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unclosed_bracket.py", line 5
    return [1, 2, 3
           ^
SyntaxError: '[' was never closed

    ה- סוגר מרובע `[` מעולם לא נסגר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unclosed_bracket.py'
במקום המצוין.

-->5|     return [1, 2, 3
                 ^
   6|
   7| print(foo())
   8|

הפתיחה סוגר מרובע `[` בשורה 5 אינה סגורה.

    5:     return [1, 2, 3
                  ^

(215) Unclosed parenthesis - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unclosed_paren_1.py", line 2
    x = int('1'
           ^
SyntaxError: '(' was never closed

    ה- סוגריים `(` מעולם לא נסגר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unclosed_paren_1.py'
במקום המצוין.

-->2| x = int('1'
             ^
   3| if x == 1:
   4|     print('yes')
   5|

הפתיחה סוגריים `(` בשורה 2 אינה סגורה.

    2: x = int('1'
              ^

(216) Unclosed parenthesis - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unclosed_paren_2.py", line 2
    a = (b+c
        ^
SyntaxError: '(' was never closed

    ה- סוגריים `(` מעולם לא נסגר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unclosed_paren_2.py'
במקום המצוין.

-->2| a = (b+c
          ^
   3| d = a*a
   4|

הפתיחה סוגריים `(` בשורה 2 אינה סגורה.

    2: a = (b+c
           ^

(217) Unclosed parenthesis - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unclosed_paren_3.py", line 7
    if 2:
        ^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unclosed_paren_3.py'
במקום המצוין.

   5|         print(((123))
   6|
-->7| if 2:
          ^
   8|     print(123))

הפתיחה סוגריים `(` בשורה 5 אינה סגורה.

    5:         print(((123))
                    ^

אם זה לא נכון, אנא דווח על מקרה זה.

(218) Unclosed parenthesis - 4

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unclosed_paren_4.py", line 4
    def test():
    ^^^
SyntaxError: invalid syntax

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unclosed_paren_4.py'
במקום המצוין.

   2| print('hello'
   3|
-->4| def test():
      ^^^

הפתיחה סוגריים `(` בשורה 2 אינה סגורה.

    2: print('hello'
            ^

(219) Content passed continuation line character

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unexpected_after_continuation_character.py", line 5
    print(\t)
           ^
SyntaxError: unexpected character after line continuation character

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unexpected_after_continuation_character.py'
במקום המצוין.

   5| print(\t)
             ^

את\ה משתמש\ת בתו '\' מחוץ למחרוזת,
ואחריו כמה דמויות אחרות.
אני מנחש ששכחת לסגור תוכן כלשהו במחרוזת.

(220) Unexpected EOF while parsing

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unexpected_eof.py", line 5
    return [1, 2, 3,
           ^
SyntaxError: '[' was never closed

    ה- סוגר מרובע `[` מעולם לא נסגר.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unexpected_eof.py'
במקום המצוין.

-->5|     return [1, 2, 3,
                 ^
   6|
   7| print(foo())
   8|

הפתיחה סוגר מרובע `[` בשורה 5 אינה סגורה.

    5:     return [1, 2, 3,
                  ^

(221) Invalid character (unicode fraction 3/4)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_fraction.py", line 1
    a = ¾  # 3/4
        ^
SyntaxError: invalid character '¾' (U+00BE)

    Did you mean `3/4`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_fraction.py'
במקום המצוין.

   1| a = ¾  # 3/4
          ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '¾'
מה שאסור.
You used the unicode character ¾ which is known as
VULGAR FRACTION THREE QUARTERS
I suspect that you meant to write the fraction `3/4` instead.

(222) Invalid character (unicode fraction 1/2)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_fraction2.py", line 1
    a = 1½  # 1 1/2
        ^
SyntaxError: invalid decimal literal

    Did you mean `1/2`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_fraction2.py'
במקום המצוין.

   1| a = 1½  # 1 1/2
          ^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

You used the unicode character ½ which is known as
VULGAR FRACTION ONE HALF
I suspect that you meant to write the fraction `1/2` instead.

(223) Invalid character (unicode fraction slash)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_fraction3.py", line 1
    a = 22 ⁄ 7
           ^
SyntaxError: invalid character '⁄' (U+2044)

    Did you mean to use the division operator, `/`?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_fraction3.py'
במקום המצוין.

   1| a = 22 ⁄ 7
             ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '⁄'
מה שאסור.
I suspect that you used the unicode character known as
'FRACTION SLASH', which looks similar to
but is different from the division operator `/`.

(224) Invalid character (unicode quote)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_quote.py", line 3
    a = « hello »
        ^
SyntaxError: invalid character '«' (U+00AB)

    האם התכוונת להשתמש בגרש או גרשיים נורמליים, '' או '' ''?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_quote.py'
במקום המצוין.

   3| a = « hello »
          ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '«'
מה שאסור.
I suspect that you used a fancy unicode quotation mark
whose name is LEFT-POINTING DOUBLE ANGLE QUOTATION MARK
instead of a normal single or double quote for a string.

(225) Invalid character (unicode quote2)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_quote2.py", line 2
    a = ‹ hello ›
        ^
SyntaxError: invalid character '‹' (U+2039)

    האם התכוונת להשתמש בגרש או גרשיים נורמליים, '' או '' ''?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_quote2.py'
במקום המצוין.

   2| a = ‹ hello ›
          ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '‹'
מה שאסור.
I suspect that you used a fancy unicode quotation mark
whose name is SINGLE LEFT-POINTING ANGLE QUOTATION MARK
instead of a normal single or double quote for a string.

(226) Invalid character (mistaken <)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_quote3.py", line 2
    if a ‹ hello:
         ^
SyntaxError: invalid character '‹' (U+2039)

    האם התכוונת להשתמש בגרש או גרשיים נורמליים, '' או '' ''?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_quote3.py'
במקום המצוין.

   2| if a ‹ hello:
           ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '‹'
מה שאסור.
I suspect that you used a fancy unicode quotation mark
whose name is SINGLE LEFT-POINTING ANGLE QUOTATION MARK
instead of a normal single or double quote for a string.
Or perhaps, you meant to write a less than sign, `<`.

(227) Invalid character (mistaken >)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_quote4.py", line 2
    if a › hello:
         ^
SyntaxError: invalid character '›' (U+203A)

    האם התכוונת להשתמש בגרש או גרשיים נורמליים, '' או '' ''?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_quote4.py'
במקום המצוין.

   2| if a › hello:
           ^

האם השתמשת בהעתק-הדבק?
Python מציין שהשתמשת בתו unicode '›'
מה שאסור.
I suspect that you used a fancy unicode quotation mark
whose name is SINGLE RIGHT-POINTING ANGLE QUOTATION MARK
instead of a normal single or double quote for a string.
Or perhaps, you meant to write a greater than sign, `>`.

(228) Invalid character (mistaken comma)

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_quote5.py", line 2
    a = (1‚ 2)
         ^
SyntaxError: invalid decimal literal

    האם התכוונת לכתוב פסיק?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_quote5.py'
במקום המצוין.

   2| a = (1‚ 2)
           ^^

Python tells us that you have written an invalid number.
However, I think that the problem might be the following.

I suspect that you used a fancy unicode quotation mark
whose name is SINGLE LOW-9 QUOTATION MARK.

Perhaps, you meant to write a comma.

(229) Unmatched closing curly bracket

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unmatched_closing_curly.py", line 6
    3, 4,}}
          ^
SyntaxError: unmatched '}'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unmatched_closing_curly.py'
במקום המצוין.

   4| a = {1,
   5|     2,
-->6|     3, 4,}}
                ^

הסגירה סוגר מתולתל `}` בשורה 6 אינה תואמת דבר.

(230) Unmatched closing parenthesis

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unmatched_closing_paren.py", line 6
    3, 4,))
          ^
SyntaxError: unmatched ')'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unmatched_closing_paren.py'
במקום המצוין.

   4| a = (1,
   5|     2,
-->6|     3, 4,))
                ^

הסגירה סוגריים `)` בשורה 6 אינה תואמת דבר.

(231) Mismatched brackets - 1

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unmatched_closing_bracket_1.py", line 2
    x = (1, 2, 3]
                ^
SyntaxError: closing parenthesis ']' does not match opening parenthesis '('

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unmatched_closing_bracket_1.py'
במקום המצוין.

   2| x = (1, 2, 3]
          ^       ^

סגירת סוגר מרובע `]` בשורה 2 אינה תואמת את סוגריים `(` הפתיחה בשורה 2.

    2: x = (1, 2, 3]
           ^       ^

(232) Mismatched brackets - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unmatched_closing_bracket_2.py", line 4
    3]
     ^
SyntaxError: closing parenthesis ']' does not match opening parenthesis '(' on line 2

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unmatched_closing_bracket_2.py'
במקום המצוין.

-->2| x = (1,
          ^
   3|      2,
-->4|      3]
            ^

סגירת סוגר מרובע `]` בשורה 4 אינה תואמת את סוגריים `(` הפתיחה בשורה 2.

    2: x = (1,
           ^
    4:      3]
             ^

(233) Unmatched brackets - 3

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unmatched_closing_bracket_3.py", line 3
    3]]
      ^
SyntaxError: unmatched ']'

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unmatched_closing_bracket_3.py'
במקום המצוין.

   1| x = [1,
   2|      2,
-->3|      3]]
             ^

הסגירה סוגר מרובע `]` בשורה 3 אינה תואמת דבר.

(234) Unpacking a dict value

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unpacking_dict_value.py", line 1
    {'a': *(1, 2, 3)}
          ^^^^^^^^^^
SyntaxError: cannot use a starred expression in a dictionary value

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unpacking_dict_value.py'
במקום המצוין.

   1| {'a': *(1, 2, 3)}
            ^^^^^^^^^^

It looks like you tried to use a starred expression as a dict value;
this is not allowed.

The following statement has no syntax error:

    {'a': (1, 2, 3)}

(235) Unterminated triple quoted string

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unterminated_triple_quote_string.py", line 1
    some_text = """In a land
                ^
SyntaxError: unterminated triple-quoted string literal (detected at line 4)

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unterminated_triple_quote_string.py'
במקום המצוין.

   1| some_text = """In a land
                  ^^^^^^^^^^^^

התחלת לכתוב מחרוזת עם שלושה גרשיים אך מעולם לא כתבת את
את שלושת הגרשיים המסיימים הדרושים כדי לסיים את המחרוזת.

(236) TabError

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\tab_error.py", line 7
    pass
    ^
TabError: inconsistent use of tabs and spaces in indentation

'TabError' מציין שהשתמשת בשני הרווחים
ותווי טאב כדי להכניס את הקוד שלך.
זה אסור ב-Python.
הזחה של הקוד שלך פירושה גוש קודים מיושר אנכית
על ידי הוספת רווחים או תווי טאב בתחילת השורות.
ההמלצה של Python היא להשתמש תמיד ברווחים כדי להכניס את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\tab_error.py'
במקום המצוין.

   7|       pass
       ^^^^

(237) Wrong word instead of expect

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\typo_in_except.py", line 3
    something Exception:
    ^^^^^^^^^
SyntaxError: expected 'except' or 'finally' block

    Did you mean `except Exception:`?
'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\typo_in_except.py'
במקום המצוין.

   3| something Exception:
      ^^^^^^^^^

You wrote a `try` block which did not include an `except` nor a `finally` block.
Perhaps you meant to write

    except Exception:

(238) Typo in finally

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\typo_in_finally.py", line 3
    finnally:
    ^^^^^^^^
SyntaxError: expected 'except' or 'finally' block

    Did you mean `finally:`?
'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\typo_in_finally.py'
במקום המצוין.

   3| finnally:
      ^^^^^^^^

You wrote a `try` block which did not include an `except` nor a `finally` block.
Perhaps you meant to write

    finally:

(239) EOL unescaped backslash

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unescaped_backslash.py", line 1
    a = "abc\"
        ^
SyntaxError: unterminated string literal (detected at line 1)

    שכחת לשים לוחסן "\"?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unescaped_backslash.py'
במקום המצוין.

   1| a = "abc\"
          ^

התחלת לכתוב מחרוזת עם גרש או מרכאות
אך מעולם לא סיימת את המחרוזת בציטוט\מרכאות נוסף בשורה זו.
אולי התכוונת לכתוב את הלוכסן , '\'
באות האחרונה במחרוזת ושכחת שאתה
צריך לתקן זאת על ידי כתיבת שני '\' ברציפות.

(240) Using the backquote character

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\use_backquote.py", line 3
    a = `1`
        ^
SyntaxError: invalid syntax

    אתה לא אמור להשתמש בתו סימן ההטעמה המשני (grave accent).

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\use_backquote.py'
במקום המצוין.

   3| a = `1`
          ^

אתה משתמש בתו הציטוט האחורי.
או שהתכוונת לכתוב ציטוט בודד, ', או שהעתקת את קוד Python 2;
במקרה האחרון הזה, השתמש בפונקציה `repr(x)`.

(241) unicode error

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\unicode_error.py", line 1
    path = "c:\Users\andre"
                           ^
SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UXXXXXXXX escape

    אולי אתה צריך להכפיל את הלוֹכסן האחורי .

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\unicode_error.py'
במקום המצוין.

   1| path = "c:\Users\andre"
             ^^^^^^^^^^^^^^^^

I suspect that you wrote a string that contains
one backslash character, `\` followed by an uppercase `U`
and some more characters.
Python likely interpreted this as indicating the beginning of
what is known as an escape sequence for special unicode characters.
To solve the problem, either write a so-called 'raw string'
by adding the letter `r` as a prefix in
front of the string, or replace `\U`, by `\\U`.

(242) Walrus instead of equal

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\walrus_instead_of_equal.py", line 1
    a := 3
      ^^
SyntaxError: invalid syntax

    האם התכוונת להשתמש ב- '= `?

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\walrus_instead_of_equal.py'
במקום המצוין.

   1| a := 3
        ^^

אתה משתמש באופרטור מקוצר `: =` מתי
שמפעיל ההקצאה הרגיל `=` נדרש.

(243) Missing condition in while statement

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\while_missing_condition.py", line 1
    while:
         ^
SyntaxError: invalid syntax

    שכחת להוסיף תנאי.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\while_missing_condition.py'
במקום המצוין.

   1| while:
           ^

לולאת 'while (בעוד)' דורשת תנאי:

     while (בעוד) מצב:
         ...

(244) Would-be variable declaration

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\would_be_type_declaration_1.py", line 3
    if var start := begin < end:
           ^^^^^
SyntaxError: invalid syntax

    אינך צריך להכריז על סוג משתנים בפייתון.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\would_be_type_declaration_1.py'
במקום המצוין.

   3| if var start := begin < end:
             ^^^^^

נראה שניסית להצהיר כי "start" היה
משתנה באמצעות המילה 'var'.
אם תסיר את 'var', תהיה לך הצהרת Python חוקית.

(245) Would-be variable declaration - 2

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\would_be_type_declaration_2.py", line 5
    var start := begin < end
    ^^^^^^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?

    אינך צריך להכריז על סוג משתנים בפייתון.

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\would_be_type_declaration_2.py'
במקום המצוין.

   4| if (
-->5|     var start := begin < end
          ^^^^^^^^^
   6|    ):

נראה שניסית להצהיר כי "var" היה
משתנה באמצעות המילה 'var'.
אם תסיר את 'var', תהיה לך הצהרת Python חוקית.

(246) Cannot use yield outside function

Traceback (most recent call last):
  File "TESTS:\trb_syntax_common.py", line 52, in create_tracebacks
    __import__(name)
  File "TESTS:\syntax\yield_outside_function.py", line 1
    (yield i) == 3
     ^^^^^^^
SyntaxError: 'yield' outside function

'SyntaxError' נזרק כאשר פייתון אינו מצליח להבין את הקוד שלך.

פייתון לא הצליח להבין את הקוד בקובץ
 'TESTS:\syntax\yield_outside_function.py'
במקום המצוין.

   1| (yield i) == 3
       ^^^^^

You can only use a `yield` statement inside a function.