You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Write a multi-line code snippet (e.g., a Keras Sequential model definition) and place the #@ marker at the end of the line.
Try splitting the code across multiple lines while keeping the #@ marker.
Run the checker that leverages the #@ marker to see how nodes are created.
Current behavior
The code checker creates new nodes for each line when the #@ marker is used in multi-line code snippets, resulting in separate nodes rather than treating the code block as one unit. This reduces the clarity of scenarios and makes it challenging to handle more complex, multi-line code.
model = tf.keras.Sequential(layers=[
tf.keras.layers.Dense(units=64, activation='relu'),
tf.keras.layers.Dense(units=10)
]) #@
Additionally, having everything on a single line makes the code harder to read and maintain. For example, writing it all in one line like below is less readable and too long:
model = tf.keras.Sequential(layers=[tf.keras.layers.Dense(units=64, activation='relu'), tf.keras.layers.Dense(units=10)]) #@
Expected behavior
The code checker should treat multi-line code snippets marked with #@ as a single unit, allowing for improved readability and easier handling of more complex scenarios.
Steps to reproduce
Current behavior
The code checker creates new nodes for each line when the #@ marker is used in multi-line code snippets, resulting in separate nodes rather than treating the code block as one unit. This reduces the clarity of scenarios and makes it challenging to handle more complex, multi-line code.
Additionally, having everything on a single line makes the code harder to read and maintain. For example, writing it all in one line like below is less readable and too long:
model = tf.keras.Sequential(layers=[tf.keras.layers.Dense(units=64, activation='relu'), tf.keras.layers.Dense(units=10)]) #@
Expected behavior
The code checker should treat multi-line code snippets marked with #@ as a single unit, allowing for improved readability and easier handling of more complex scenarios.
python -c "from astroid import __pkginfo__; print(__pkginfo__.version)"
outputThe text was updated successfully, but these errors were encountered: