-
-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
format code, change image sub name, fix spelling
- Loading branch information
Showing
29 changed files
with
276 additions
and
188 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 11 additions & 10 deletions
21
src/navigation/failure_identification/failure_identification.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
from dataclasses import dataclass, field | ||
|
||
import numpy as np | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/usr/bin/env bash | ||
|
||
# See: https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/ | ||
set -Eeuo pipefail | ||
|
||
readonly RED='\033[0;31m' | ||
readonly NC='\033[0m' | ||
|
||
BLACK_ARGS=( | ||
"--line-length=120" | ||
"--color" | ||
) | ||
|
||
# Just do a dry run if the "fix" argument is not passed | ||
if [ $# -eq 0 ] || [ "$1" != "--fix" ]; then | ||
BLACK_ARGS+=("--diff") # Show difference | ||
BLACK_ARGS+=("--check") # Exit with non-zero code if changes are required (for CI) | ||
fi | ||
|
||
function print_update_error() { | ||
echo -e "${RED}[Error] Please update with ./ansible.sh build.yml${NC}" | ||
exit 1 | ||
} | ||
|
||
function find_executable() { | ||
local readonly executable="$1" | ||
local readonly version="$2" | ||
local readonly path=$(which "${executable}") | ||
if [ ! -x "${path}" ]; then | ||
echo -e "${RED}[Error] Could not find ${executable}${NC}" | ||
print_update_error | ||
fi | ||
if ! "${path}" --version | grep -q "${version}"; then | ||
echo -e "${RED}[Error] Wrong ${executable} version${NC}" | ||
print_update_error | ||
fi | ||
echo "${path}" | ||
} | ||
|
||
readonly BLACK_PATH=$(find_executable black 23.9.1) | ||
|
||
echo | ||
echo "Style checking Python with black ..." | ||
"${BLACK_PATH}" "${BLACK_ARGS[@]}" ./src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#!/usr/bin/env bash | ||
|
||
# See: https://vaneyckt.io/posts/safer_bash_scripts_with_set_euxo_pipefail/ | ||
set -Eeuo pipefail | ||
|
||
readonly RED='\033[0;31m' | ||
readonly NC='\033[0m' | ||
|
||
function print_update_error() { | ||
echo -e "${RED}[Error] Please update with ./ansible.sh build.yml${NC}" | ||
exit 1 | ||
} | ||
|
||
function find_executable() { | ||
local readonly executable="$1" | ||
local readonly version="$2" | ||
local readonly path=$(which "${executable}") | ||
if [ ! -x "${path}" ]; then | ||
echo -e "${RED}[Error] Could not find ${executable}${NC}" | ||
print_update_error | ||
fi | ||
if ! "${path}" --version | grep -q "${version}"; then | ||
echo -e "${RED}[Error] Wrong ${executable} version${NC}" | ||
print_update_error | ||
fi | ||
echo "${path}" | ||
} | ||
|
||
readonly MYPY_PATH=$(find_executable mypy 1.5.1) | ||
|
||
echo | ||
echo "Style checking Python with mypy ..." | ||
"${MYPY_PATH}" --config-file=mypy.ini --check ./src |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../mypy.ini |
Oops, something went wrong.