-
-
Notifications
You must be signed in to change notification settings - Fork 376
Fixing docqueries generator flag -level & updating developer tools #2723
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixing docqueries generator flag -level & updating developer tools #2723
Conversation
WalkthroughThe pull request introduces modifications to three scripts in the developer and testing tools directory. The Changes
Sequence DiagramsequenceDiagram
participant Dev as Developer
participant RunScript as run.sh
participant CMake as CMake
participant Cppcheck as Cppcheck
participant ClangTidy as Clang-Tidy
Dev->>RunScript: Execute build process
RunScript->>CMake: Generate compile commands
CMake-->>RunScript: compile_commands.json
RunScript->>Cppcheck: Static analysis
RunScript->>ClangTidy: Code tidying
RunScript->>RunScript: Build documentation
Poem
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
@coderabbitai configuration |
CodeRabbit configurationlanguage: en-US
tone_instructions: ''
early_access: true
enable_free_tier: true
reviews:
profile: assertive
request_changes_workflow: false
high_level_summary: true
high_level_summary_placeholder: '@coderabbitai summary'
auto_title_placeholder: '@coderabbitai'
auto_title_instructions: ''
review_status: true
commit_status: true
fail_commit_status: false
collapse_walkthrough: false
changed_files_summary: true
sequence_diagrams: true
assess_linked_issues: true
related_issues: true
related_prs: true
suggested_labels: true
auto_apply_labels: false
suggested_reviewers: true
poem: true
labeling_instructions: []
path_filters: []
path_instructions: []
abort_on_close: true
auto_review:
enabled: true
auto_incremental_review: true
ignore_title_keywords: []
labels: []
drafts: false
base_branches: []
tools:
shellcheck:
enabled: true
ruff:
enabled: true
markdownlint:
enabled: true
github-checks:
enabled: true
timeout_ms: 90000
languagetool:
enabled: true
enabled_only: false
level: default
enabled_rules: []
disabled_rules: []
enabled_categories: []
disabled_categories: []
biome:
enabled: true
hadolint:
enabled: true
swiftlint:
enabled: true
phpstan:
enabled: true
level: default
golangci-lint:
enabled: true
yamllint:
enabled: true
gitleaks:
enabled: true
checkov:
enabled: true
detekt:
enabled: true
eslint:
enabled: true
rubocop:
enabled: true
buf:
enabled: true
regal:
enabled: true
actionlint:
enabled: true
pmd:
enabled: true
cppcheck:
enabled: true
semgrep:
enabled: true
circleci:
enabled: true
ast-grep:
packages: []
rule_dirs: []
util_dirs: []
essential_rules: true
chat:
auto_reply: true
knowledge_base:
opt_out: false
learnings:
scope: auto
issues:
scope: auto
jira:
project_keys: []
linear:
team_keys: []
pull_requests:
scope: auto
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (3)
tools/developer/run.sh
(4 hunks)tools/developer/taptest.sh
(2 hunks)tools/testers/doc_queries_generator.pl
(1 hunks)
🧰 Additional context used
🪛 Shellcheck (0.10.0)
tools/developer/run.sh
[info] 114-114: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 114-114: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 128-128: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 128-128: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 129-129: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 130-130: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 131-131: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 131-131: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 135-135: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 136-136: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 179-179: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 180-180: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
🪛 GitHub Actions: Check files
tools/developer/run.sh
[info] 92-92: Double quote PGPORT variable to prevent globbing and word splitting. Use: tools/release-scripts/get_signatures.sh -p "${PGPORT}"
[info] 98-98: Double quote PGPORT variable to prevent globbing and word splitting. Use: tools/testers/doc_queries_generator.pl -documentation -pgport "$PGPORT"
[info] 88-183: Multiple commands appear to be unreachable. Check usage or ignore if invoked indirectly. Affects various commands throughout the script including echo statements, build commands, and function calls.
⏰ Context from checks skipped due to timeout of 90000ms (16)
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: macos (macos-14)
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Ubuntu Boost (56)
- GitHub Check: macos (macos-latest)
- GitHub Check: Ubuntu clang
- GitHub Check: Check queries
🔇 Additional comments (4)
tools/testers/doc_queries_generator.pl (1)
127-129
: LGTM! Command-line interface improvementThe changes enhance usability by supporting both
-l
and-level
options, with clear feedback about the selected level.tools/developer/taptest.sh (1)
70-80
: LGTM! Robust version managementThe version-based testing logic is well-implemented, properly handling both old and new versions with appropriate update commands.
tools/developer/run.sh (2)
127-132
: LGTM! Added static analysis integrationThe new
check
function properly integrates cppcheck with CMake's compile commands database.🧰 Tools
🪛 Shellcheck (0.10.0)
[info] 128-128: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 128-128: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 129-129: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 130-130: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 131-131: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
[info] 131-131: Command appears to be unreachable. Check usage (or ignore if invoked indirectly).
(SC2317)
161-162
: 🛠️ Refactor suggestionFix shellcheck warnings about unquoted variables
Variables should be quoted to prevent word splitting and globbing issues.
- tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -level WARNING -pgport "${PGPORT}" + tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -level WARNING -pgport "${PGPORT}"Likely invalid or redundant comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 8
♻️ Duplicate comments (1)
tools/developer/taptest.sh (1)
29-31
:⚠️ Potential issueAdd error handling for git commands.
The git command to find repository root still needs error handling in case it's not run from within a git repository.
-DIR=$(git rev-parse --show-toplevel) -pushd "${DIR}" > /dev/null || exit 1 +if ! DIR=$(git rev-parse --show-toplevel 2>/dev/null); then + echo "Error: Must be run from within the git repository" >&2 + exit 1 +fi +pushd "${DIR}" > /dev/null || exit 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (2)
tools/developer/run.sh
(4 hunks)tools/developer/taptest.sh
(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (14)
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Ubuntu clang
- GitHub Check: Ubuntu Boost (56)
- GitHub Check: Check queries
🔇 Additional comments (4)
tools/developer/taptest.sh (2)
43-45
: LGTM! Good improvement on database configuration.The changes address the previous feedback by:
- Using a standard default port
- Using the current system user as default
56-58
: Clarify the purpose of sleep delay.The 3-second sleep seems arbitrary. If this is for database connection stability, consider:
- Making the delay configurable
- Adding a comment explaining its purpose
- Using a more reliable mechanism like connection retry
tools/developer/run.sh (2)
67-67
: LGTM! Good addition of compile commands export option.The addition of
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON
is valuable as it enables static analysis tools to work with the codebase.
157-163
: LGTM! Good improvement to documentation query logging.The addition of
-level WARNING
provides better control over logging output.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🔭 Outside diff range comments (1)
tools/developer/taptest.sh (1)
Line range hint
51-52
: Remove redundant PGRVERSION assignment.The first PGRVERSION assignment is immediately overwritten by the second one, making it redundant and potentially confusing.
-PGRVERSION="3.6.1 3.6.0 3.5.1 3.5.0 3.2.0 3.1.3 3.0.6" -PGRVERSION="3.7.2" +PGRVERSION="3.7.2" # List of versions to test
♻️ Duplicate comments (2)
tools/developer/taptest.sh (2)
39-39
:⚠️ Potential issueVersion extraction needs improvement.
The current version extraction method using Perl regex (
grep -Po
) remains fragile and system-dependent.Please implement the previously suggested robust version extraction:
-VERSION=$(grep -Po '(?<=project\(PGROUTING VERSION )[^;]+' CMakeLists.txt) +if ! VERSION=$(grep -E '^[[:space:]]*project\(PGROUTING[[:space:]]+VERSION[[:space:]]+([^[:space:];]+)' CMakeLists.txt | sed -E 's/.*VERSION[[:space:]]+([^[:space:];]+).*/\1/'); then + echo "Error: Failed to extract version from CMakeLists.txt" >&2 + exit 1 +fi + +if [[ -z "${VERSION}" ]]; then + echo "Error: Version not found in CMakeLists.txt" >&2 + exit 1 +fi
66-71
:⚠️ Potential issueAdd error handling for database setup.
The call to setup_db.sh still lacks error handling.
Please implement the previously suggested error handling:
-bash setup_db.sh "${PGPORT}" "${PGDATABASE}" "${PGUSER}" "${v}" +if ! bash setup_db.sh "${PGPORT}" "${PGDATABASE}" "${PGUSER}" "${v}"; then + echo "Error: Database setup failed" >&2 + exit 1 +fi
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (1)
tools/developer/taptest.sh
(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (16)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Ubuntu Boost (56)
- GitHub Check: macos (macos-14)
- GitHub Check: Ubuntu clang
- GitHub Check: macos (macos-latest)
- GitHub Check: Check queries
🔇 Additional comments (2)
tools/developer/taptest.sh (2)
29-34
: LGTM! Error handling for git commands implemented.The repository root check has been properly implemented with error handling as previously suggested.
73-86
:⚠️ Potential issueImprove version update logic.
The version update section needs several improvements:
- Add error handling for pg_prove
- Verify extension update success
- Improve comment clarity
Apply these changes:
if [[ "${v}" != "${VERSION}" ]] then - # run tests on old version - pg_prove "$QUIET" --normalize --directives --recurse "${PGFLAGS}" -d "${PGDATABASE}" "pgtap/${DIR}" + echo "Running tests on version ${v} before update..." + if ! pg_prove "$QUIET" --normalize --directives --recurse "${PGFLAGS}" -d "${PGDATABASE}" "pgtap/${DIR}"; then + echo "Error: Tests failed on version ${v}" >&2 + exit 1 + fi - # update to this version echo "--------------------------" - echo " update version" + echo "Updating from version ${v} to ${VERSION}..." echo "--------------------------" - psql "${PGFLAGS}" -d "$PGDATABASE" -c "SET client_min_messages TO DEBUG3; ALTER EXTENSION pgrouting UPDATE TO '${VERSION}';" + if ! psql "${PGFLAGS}" -d "$PGDATABASE" -c "SET client_min_messages TO DEBUG3; ALTER EXTENSION pgrouting UPDATE TO '${VERSION}';"; then + echo "Error: Failed to update pgrouting extension to version ${VERSION}" >&2 + exit 1 + fi + + # Verify update success + if ! psql "${PGFLAGS}" -q -t -d "$PGDATABASE" -c "SELECT extversion FROM pg_extension WHERE extname = 'pgrouting';" | grep -q "^${VERSION}$"; then + echo "Error: Extension version mismatch after update" >&2 + exit 1 + fi fiLikely invalid or redundant comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 4
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (2)
tools/developer/run.sh
(4 hunks)tools/developer/taptest.sh
(2 hunks)
🧰 Additional context used
🪛 Shellcheck (0.10.0)
tools/developer/run.sh
[warning] 117-117: This action ignores everything before the -o. Use ( ) to group.
(SC2146)
🪛 GitHub Actions: Check files
tools/developer/run.sh
[warning] 117-117: Shell script warning: find command's -o operator is not properly grouped with ( ), causing it to ignore everything before -o
⏰ Context from checks skipped due to timeout of 90000ms (16)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: macos (macos-14)
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Check queries
- GitHub Check: Ubuntu clang
- GitHub Check: macos (macos-latest)
- GitHub Check: Ubuntu Boost (56)
🔇 Additional comments (6)
tools/developer/taptest.sh (4)
29-34
: LGTM! Well-implemented repository root check.The implementation correctly ensures the script runs from within the git repository with proper error handling.
39-47
: LGTM! Robust version extraction implementation.The version extraction is well-implemented with proper error handling and validation.
55-57
: Make PGPORT configurable like PGUSER.For consistency, PGPORT should be configurable with a fallback value:
-PGPORT="5432" +PGPORT="${PGPORT:-5432}"
87-108
: LGTM! Well-implemented version update logic.The version update implementation includes:
- Proper version comparison
- Error handling for the update process
- Verification of update success
tools/developer/run.sh (2)
108-109
: LGTM! Safer compiler selection implementation.Good improvement replacing sudo with environment variables for compiler selection.
128-142
: LGTM! Well-implemented static analysis function.The function includes proper error handling, report generation, and appropriate suppressions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (2)
tools/developer/run.sh
(4 hunks)tools/developer/taptest.sh
(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (15)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: Ubuntu clang
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Ubuntu Boost (56)
- GitHub Check: macos (macos-14)
- GitHub Check: macos (macos-latest)
🔇 Additional comments (11)
tools/developer/taptest.sh (5)
29-34
: LGTM! Proper repository root validation.The implementation correctly validates that the script is run from within the git repository with appropriate error handling.
55-57
: LGTM! Good use of environment variables with defaults.The implementation correctly uses parameter expansion to provide sensible defaults while allowing override through environment variables.
76-79
: LGTM! Proper error handling in database setup.The implementation correctly handles database setup failures with appropriate error messaging.
71-71
: 🧹 Nitpick (assertive)Document the purpose of the sleep command.
The
sleep 3
command appears to be used for giving time to read messages. Consider adding a comment explaining its purpose.+ # Give time to read the version and test information before proceeding sleep 3
Likely invalid or redundant comment.
39-47
: 🧹 Nitpick (assertive)Consider enhancing version extraction robustness.
While the current implementation handles basic error cases well, consider these improvements:
- Validate version format (e.g., semantic versioning)
- Handle multi-line project declarations
if ! VERSION=$(grep -E '^[[:space:]]*project\(PGROUTING[[:space:]]+VERSION[[:space:]]+([^[:space:];]+)' CMakeLists.txt | sed -E 's/.*VERSION[[:space:]]+([^[:space:];]+).*/\1/'); then echo "Error: Failed to extract version from CMakeLists.txt" >&2 exit 1 fi if [[ -z "${VERSION}" ]]; then echo "Error: Version not found in CMakeLists.txt" >&2 exit 1 +elif ! echo "${VERSION}" | grep -qE '^[0-9]+\.[0-9]+\.[0-9]+(-[0-9A-Za-z-]+(\.[0-9A-Za-z-]+)*)?(\+[0-9A-Za-z-]+(\.[0-9A-Za-z-]+)*)?$'; then + echo "Error: Invalid version format in CMakeLists.txt: ${VERSION}" >&2 + exit 1 fiLikely invalid or redundant comment.
tools/developer/run.sh (6)
110-111
: LGTM! Safe compiler configuration.The implementation correctly uses environment variables instead of sudo for compiler selection.
118-119
: LGTM! Proper documentation cleanup.The implementation correctly uses find with proper grouping to clean only generated files while preserving custom content.
146-152
: LGTM! Well-structured clang-tidy function.The implementation correctly handles base branch configuration and error cases.
192-194
:⚠️ Potential issueRemove duplicate tap_test call.
The
tap_test
function is called twice in succession.tap_test tools/testers/doc_queries_generator.pl -pgport $PGPORT build_doc - tap_test action_tests
Likely invalid or redundant comment.
176-181
: 🧹 Nitpick (assertive)Document the purpose of different documentation query options.
Add comments explaining when to use each option:
+ # Generate documentation with full examples and explanations #tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -documentation -pgport "${PGPORT}" + # Run with increased verbosity to show potential issues #tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -level WARNING -pgport "${PGPORT}" + # Execute queries and compare results with expected output tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -pgport "${PGPORT}"Likely invalid or redundant comment.
130-144
: 🧹 Nitpick (assertive)Document and enhance static analysis configuration.
Consider these improvements:
- Document the purpose of CMAKE_EXPORT_COMPILE_COMMANDS
- Allow configuration via environment variables
function check { pushd build > /dev/null || exit 1 + # Generate compile_commands.json for static analysis tools cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=ON .. # Run with error handling and report generation cppcheck --project=compile_commands.json \ - --enable=all \ - --suppress=missingIncludeSystem \ + --enable=${CPPCHECK_CHECKS:-all} \ + --suppress=${CPPCHECK_SUPPRESS:-missingIncludeSystem} \ --error-exitcode=1 \ --output-file=cppcheck-report.txt 2>&1 || { echo "Static analysis failed. See build/cppcheck-report.txt for details"Likely invalid or redundant comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 5
📜 Review details
Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro
📒 Files selected for processing (1)
tools/developer/run.sh
(4 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (14)
- GitHub Check: Ubuntu Boost (86)
- GitHub Check: Ubuntu Boost (84)
- GitHub Check: Ubuntu Boost (83)
- GitHub Check: Ubuntu Boost (80)
- GitHub Check: Ubuntu Boost (79)
- GitHub Check: Ubuntu Boost (78)
- GitHub Check: Ubuntu Boost (77)
- GitHub Check: Ubuntu Boost (76)
- GitHub Check: Ubuntu Boost (75)
- GitHub Check: Ubuntu Boost (68)
- GitHub Check: Ubuntu Boost (56)
- GitHub Check: Codacy Static Code Analysis
- GitHub Check: Ubuntu clang
- GitHub Check: Check queries
🔇 Additional comments (3)
tools/developer/run.sh (3)
110-111
: LGTM! Good improvement in compiler selection.The change to use environment variables instead of sudo is a safer and more portable approach.
118-119
: LGTM! Improved documentation cleanup approach.The targeted cleanup approach with proper find command syntax is better than removing all files.
172-181
: 🧹 Nitpick (assertive)Improve documentation of doc_queries_generator.pl modes.
The different modes need better documentation and could be made configurable.
echo -------------------------------------------- echo Execute documentation queries echo -------------------------------------------- + # DOC_QUERY_MODE controls the generator mode: + # - documentation: Generate full documentation + # - warning: Show only warnings + # - compare: Compare results (default) + local mode=${DOC_QUERY_MODE:-"compare"} for d in ${QUERIES_DIRS} do - # generate the documentation queries - #tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -documentation -pgport "${PGPORT}" - # Show warnings - #tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -level WARNING -pgport "${PGPORT}" - # Compare differences on results - tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -pgport "${PGPORT}" + case "$mode" in + documentation) + tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -documentation -pgport "${PGPORT}" + ;; + warning) + tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -level WARNING -pgport "${PGPORT}" + ;; + compare) + tools/testers/doc_queries_generator.pl -alg "docqueries/${d}" -pgport "${PGPORT}" + ;; + esacLikely invalid or redundant comment.
…gRouting#2723) * Fixing docqueries generator flag -level & updating developer tools
@pgRouting/admins
Summary by CodeRabbit
New Features
Bug Fixes
Chores