Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ exclude: '^libs/(atom|thirdparty|cpptrace|spdlog)/'

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
rev: v6.0.0
hooks:
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/psf/black
rev: 24.10.0
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 26.3.1
hooks:
- id: black
- repo: https://github.com/pocc/pre-commit-hooks
Expand Down
1 change: 0 additions & 1 deletion python/executor/isolated_executor.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
from typing import Any, Dict, List, Optional, Callable
import contextlib


# IPC Constants
MAGIC = 0x4C495448 # "LITH"
VERSION = 1
Expand Down
1 change: 0 additions & 1 deletion python/lithium_bridge/registry_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
from .exporter import expose_controller, expose_command
from .module_info import ModuleRegistry, ModuleCategory, PlatformSupport


# Global registry instance
_registry: Optional[ModuleRegistry] = None

Expand Down
2 changes: 1 addition & 1 deletion python/tools/compiler_helper/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
High-level API for the compiler helper module.
"""

from pathlib import Path
from typing import List, Optional, Union

Expand All @@ -17,7 +18,6 @@
from .compiler import Compiler
from .build_manager import BuildManager


# Create a singleton compiler manager for global use
compiler_manager = CompilerManager()

Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/build_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Build Manager for handling compilation and linking of C++ projects.
"""

import os
import time
import re
Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Command-line interface for the compiler helper module.
"""

import sys
import argparse
from pathlib import Path
Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Compiler class implementation for the compiler helper module.
"""

from dataclasses import dataclass, field
import os
import platform
Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/compiler_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Compiler Manager for detecting and managing compilers.
"""

import os
import platform
import re
Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/core_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Core types and exceptions for the compiler helper module.
"""

from enum import Enum, auto
from typing import List, Dict, Optional, Union, Set, Any, TypedDict, Literal
from dataclasses import dataclass, field
Expand Down
1 change: 1 addition & 0 deletions python/tools/compiler_helper/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Utility functions for the compiler helper module.
"""

import json
from pathlib import Path
from typing import Dict, Any
Expand Down
1 change: 0 additions & 1 deletion python/tools/compiler_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@
import sys
from functools import partial


# Configure logging
logging.basicConfig(
level=logging.INFO, format="%(asctime)s - %(name)s - %(levelname)s - %(message)s"
Expand Down
6 changes: 2 additions & 4 deletions python/tools/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -1280,10 +1280,8 @@ def main():
try:
if args.check:
if pm.is_package_installed(args.check):
print(
f"Package '{args.check}' is installed, version: {
pm.get_installed_version(args.check)}"
)
print(f"Package '{args.check}' is installed, version: {
pm.get_installed_version(args.check)}")
else:
print(f"Package '{args.check}' is not installed.")

Expand Down
18 changes: 9 additions & 9 deletions src/target/repository/celestial_repository.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ class CelestialRepository::Impl {
}

auto stmt = db_->prepare(R"(
SELECT * FROM celestial_objects
SELECT * FROM celestial_objects
WHERE identifier LIKE ? OR chinese_name LIKE ? OR aliases LIKE ?
ORDER BY click_count DESC
LIMIT ?
Expand Down Expand Up @@ -512,8 +512,8 @@ class CelestialRepository::Impl {
std::vector<std::string> results;
try {
auto stmt = db_->prepare(R"(
SELECT DISTINCT identifier FROM celestial_objects
WHERE identifier LIKE ?
SELECT DISTINCT identifier FROM celestial_objects
WHERE identifier LIKE ?
ORDER BY click_count DESC, identifier ASC
LIMIT ?
)");
Expand Down Expand Up @@ -542,7 +542,7 @@ class CelestialRepository::Impl {
double decMax = dec + radius;

auto stmt = db_->prepare(R"(
SELECT * FROM celestial_objects
SELECT * FROM celestial_objects
WHERE rad_j2000 BETWEEN ? AND ?
AND dec_d_j2000 BETWEEN ? AND ?
LIMIT ?
Expand Down Expand Up @@ -578,7 +578,7 @@ class CelestialRepository::Impl {
std::vector<CelestialObjectModel> results;
try {
auto stmt = db_->prepare(R"(
SELECT * FROM celestial_objects
SELECT * FROM celestial_objects
WHERE type = ?
ORDER BY click_count DESC
LIMIT ?
Expand All @@ -602,7 +602,7 @@ class CelestialRepository::Impl {
std::vector<CelestialObjectModel> results;
try {
auto stmt = db_->prepare(R"(
SELECT * FROM celestial_objects
SELECT * FROM celestial_objects
WHERE visual_magnitude_v BETWEEN ? AND ?
ORDER BY visual_magnitude_v ASC
LIMIT ?
Expand Down Expand Up @@ -1100,7 +1100,7 @@ class CelestialRepository::Impl {
std::vector<UserRatingModel> results;
try {
auto stmt = db_->prepare(R"(
SELECT id, user_id, object_id, rating, timestamp
SELECT id, user_id, object_id, rating, timestamp
FROM user_ratings WHERE user_id = ?
ORDER BY timestamp DESC LIMIT ?
)");
Expand Down Expand Up @@ -1242,7 +1242,7 @@ class CelestialRepository::Impl {
bool incrementClickCount(const std::string& identifier) {
try {
auto stmt = db_->prepare(R"(
UPDATE celestial_objects
UPDATE celestial_objects
SET click_count = click_count + 1, updated_at = strftime('%s', 'now')
WHERE identifier = ?
)");
Expand All @@ -1259,7 +1259,7 @@ class CelestialRepository::Impl {
std::vector<CelestialObjectModel> results;
try {
auto stmt = db_->prepare(R"(
SELECT * FROM celestial_objects
SELECT * FROM celestial_objects
ORDER BY click_count DESC LIMIT ?
)");
stmt->bind(1, limit);
Expand Down
1 change: 0 additions & 1 deletion tests/server/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -306,4 +306,3 @@ add_custom_target(server_tests
test_controller_sequencer
test_websocket_log_stream
)

Loading