aws / aws/git-remote-codecommit
Indentation bug - Python
- Vorherrschende Sprache
- Python
- Sterne
- 289
- Forks
- 40
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
I pushed a python script to Code-commit and made a PR. Reviewers saw my code with an error in the last line, the indentation. So when I check my code it was fine, the problem was the indentation on the EOF they were watching on the PR. Let me explain this with an example:
```python
# What you passed to code-commit
for i in table_:
if i:
a='hello'
else:
a='bye' # EOF
```
```python
## What code-commit show you
for i in table_:
if i:
a='hello'
else:
a='bye' # codecommit EOF
```
The short way solution was pushing code with this "uncomfortable" enter in eof:
```python
## What code-commit show you
for i in table_:
if i:
a='hello'
else:
a='bye'
# new EOF
```
Beitragsleitfaden
Rechercherichtung
Der Bericht nennt keine Datei, keinen Test und keinen Einstiegspunkt. Reproduziere die Einrückungsänderung mithilfe der bereitgestellten Python-Snippets in einem CodeCommit-Pull-Request und ermittle anschließend den für das angezeigte EOF verantwortlichen git-remote-codecommit-Pfad; abgeschlossen ist die Aufgabe, wenn die abschließende eingerückte Zeile innerhalb des else-Blocks verbleibt, ohne dass eine zusätzliche Leerzeile erforderlich ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- devtools
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Muss geklärt werden
- Anfängerfreundlichkeit
- 25/100