8000 [Snyk] Security upgrade python from 3.9-slim to 3.14.3-slim by dominicusin · Pull Request #4 · dominicusin/package-maximizer · GitHub
[go: up one dir, main page]

Skip to content

[Snyk] Security upgrade python from 3.9-slim to 3.14.3-slim - #4

Merged
dominicusin merged 1 commit into
mainfrom
snyk-fix-f9e35dcb780de5c2a0bb935ff7842e25
Aug 25, 2026
Merged

dominicusin merged 1 commit into
mainfrom
snyk-fix-f9e35dcb780de5c2a0bb935ff7842e25

Conversation

@dominicusin
@dominicusin dominicusin commented Feb 7, 2026 •
Copy link
Copy Markdown
Owner

snyk-top-banner

Snyk has created this PR to fix 5 vulnerabilities in the dockerfile dependencies of this project.

Keeping your Docker base image up-to-date means you’ll benefit from security fixes in the latest version of your chosen image.

Snyk changed the following file(s):

  • Dockerfile

We recommend upgrading to python:3.14.3-slim, as this image has only 26 known vulnerabilities. To do this, merge this pull request, then verify your application still works as expected.

Vulnerabilities that will be fixed with an upgrade:

Issue Score
low severity CVE-2025-69421
SNYK-DEBIAN13-OPENSSL-15123186
  686  
low severity CVE-2025-15467
SNYK-DEBIAN13-OPENSSL-15123178
  436  
low severity CVE-2025-66199
SNYK-DEBIAN13-OPENSSL-15123183
  436  
low severity CVE-2026-22795
SNYK-DEBIAN13-OPENSSL-15123206
  436  
low severity CVE-2025-11187
SNYK-DEBIAN13-OPENSSL-15123211
  436  

Important

  • Check the changes in this PR to ensure they won't cause issues with your project.
  • Max score is 1000. Note that the real score may have changed since the PR was raised.
  • This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.

For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic


Learn how to fix vulnerabilities with free interactive lessons:

🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.

Summary by CodeRabbit

  • Chores
    • Updated the application’s container runtime to Python 3.14.3 for improved platform support and maintenance.

@coderabbitai
coderabbitai Bot commented Feb 7, 2026 •
Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 404d7bbf-8b39-466f-998c-10bd7a85e99e

📥 Commits

Reviewing files that changed from the base of the PR and between a207888 and 761cd16.

📒 Files selected for processing (1)
  • Dockerfile

Walkthrough

The Dockerfile now uses python:3.14.3-slim instead of python:3.9-slim. No other Dockerfile instructions changed.

Changes

Container Image

Layer / File(s) Summary
Python base image update
Dockerfile
The container base image changes from python:3.9-slim to python:3.14.3-slim.

Estimated code review effort: 1 (Trivial) | ~2 minutes

Poem

A rabbit checks the Dockerfile line
Python hops to three-fourteen
The slim base waits in bright clean air
One small change rests quietly there
No other lines move anywhere

✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch snyk-fix-f9e35dcb780de5c2a0bb935ff7842e25

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@qodo-code-review
Copy link
Copy Markdown

CI Feedback 🧐

A test triggered by this PR failed. Here is an AI-generated analysis of the failure:

Action: test (macos-latest, 3.11)

Failed stage: Test with pytest [❌]

Failed test name: tests/test_basic.py::test_import

Failure summary:

The action failed because pytest reported 2 failing tests due to an import error in the package:
-
tests/test_basic.py::test_import failed because importing package_maximizer raised
ModuleNotFoundError: No module named 'package_maximizer.core.enums' (triggered via
package_maximizer/init.py:14 importing .core.enums, which then fails in
package_maximizer/core/init.py:3).
- tests/test_basic.py::test_version failed for the same root
cause when executing from package_maximizer import version, which imports
package_maximizer/init.py and again errors on missing package_maximizer.core.enums.
This
indicates the module/file package_maximizer/core/enums.py (or equivalent package path) is missing,
misnamed, or not included in the package structure expected by package_maximizer/init.py.

Relevant error logs:
1:  ##[group]Runner Image Provisioner
2:  Hosted Compute Agent
...

541:  env:
542:  PYTHON_VERSION: 3.9
543:  pythonLocation: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
544:  PKG_CONFIG_PATH: /Users/runner/hostedtoolcache/Python/3.11.9/arm64/lib/pkgconfig
545:  Python_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
546:  Python2_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
547:  Python3_ROOT_DIR: /Users/runner/hostedtoolcache/Python/3.11.9/arm64
548:  ##[endgroup]
549:  ============================= test session starts ==============================
550:  platform darwin -- Python 3.11.9, pytest-9.0.2, pluggy-1.6.0 -- /Library/Frameworks/Python.framework/Versions/3.11/bin/python
551:  cachedir: .pytest_cache
552:  rootdir: /Users/runner/work/package-maximizer/package-maximizer
553:  configfile: pyproject.toml
554:  plugins: cov-7.0.0
555:  collecting ... collected 3 items
556:  tests/test_basic.py::test_import FAILED                                  [ 33%]
557:  tests/tes
8000
t_basic.py::test_basic_functionality PASSED                     [ 66%]
558:  tests/test_basic.py::test_version FAILED                                 [100%]
559:  =================================== FAILURES ===================================
560:  _________________________________ test_import __________________________________
561:  def test_import():
562:  """Тест импорта основных модулей"""
563:  try:
564:  >           import package_maximizer
565:  tests/test_basic.py:7: 
566:  _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
567:  package_maximizer/__init__.py:14: in <module>
568:  from .core.enums import PackageManagerType, SolverType
569:  _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
570:  """Основные компоненты Package Maximizer"""
571:  >   from .enums import PackageManagerType, SolverType
572:  E   ModuleNotFoundError: No module named 'package_maximizer.core.enums'
573:  package_maximizer/core/__init__.py:3: ModuleNotFoundError
574:  During handling of the above exception, another exception occurred:
575:  def test_import():
576:  """Тест импорта основных модулей"""
577:  try:
578:  import package_maximizer
579:  assert hasattr(package_maximizer, "__version__")
580:  assert package_maximizer.__version__ == "0.1.0"
581:  except ImportError:
582:  >           assert False, "Не удалось импортировать package_maximizer"
583:  E           AssertionError: Не удалось импортировать package_maximizer
584:  E           assert False
585:  tests/test_basic.py:12: AssertionError
586:  _________________________________ test_version _________________________________
587:  def test_version():
588:  """Тест версии пакета"""
589:  >       from package_maximizer import __version__
590:  tests/test_basic.py:23: 
591:  _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
592:  package_maximizer/__init__.py:14: in <module>
593:  from .core.enums import PackageManagerType, SolverType
594:  _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
595:  """Основные компоненты Package Maximizer"""
596:  >   from .enums import PackageManagerType, SolverType
597:  E   ModuleNotFoundError: No module named 'package_maximizer.core.enums'
598:  package_maximizer/core/__init__.py:3: ModuleNotFoundError
599:  ================================ tests coverage ================================
...

601:  Name                                      Stmts   Miss  Cover
602:  -------------------------------------------------------------
603:  package_maximizer/__init__.py                 9      4    56%
604:  package_maximizer/analyzers/__init__.py       0      0   100%
605:  package_maximizer/cli/__init__.py             0      0   100%
606:  package_maximizer/config/__init__.py          0      0   100%
607:  package_maximizer/core/__init__.py            5      4    20%
608:  package_maximizer/parsers/__init__.py         0      0   100%
609:  package_maximizer/solvers/__init__.py         0      0   100%
610:  package_maximizer/utils/__init__.py           0      0   100%
611:  package_maximizer/web/__init__.py             0      0   100%
612:  -------------------------------------------------------------
613:  TOTAL                                        14      8    43%
614:  Coverage XML written to file coverage.xml
615:  =========================== short test summary info ============================
616:  FAILED tests/test_basic.py::test_import - AssertionError: Не удалось импортировать package_maximizer
617:  assert False
618:  FAILED tests/test_basic.py::test_version - ModuleNotFoundError: No module named 'package_maximizer.core.enums'
619:  ========================= 2 failed, 1 passed in 0.05s ==========================
620:  ##[error]Process completed with exit code 1.
621:  Post job cleanup.

@dominicusin
dominicusin merged commit 52163aa into main Aug 25, 2026
2 of 14 checks passed
@dominicusin
dominicusin deleted the snyk-fix-f9e35dcb780de5c2a0bb935ff7842e25 branch August 25, 2026 23:23
dominicusin added a commit that referenced this pull request Aug 30, 2026
…inal touches (#21)

* feat: implement Phase 2 - additional parsers, solvers, analyzers, and utilities

Phase 2 implementation includes:

## New Parsers (3 added)
- **PacmanParser**: Parser for Pacman (Arch Linux) packages
  - Supports pacman -Q, pacman -Ss, pacman -Si formats
- **DNFParser**: Parser for DNF (Fedora/RHEL) packages
  - Supports dnf list, dnf info, dnf search formats
- **BrewParser**: Parser for Homebrew (macOS) packages
  - Supports brew list, brew info, brew search formats

## New Solvers (2 added)
- **MaxSatSolver**: SAT-based solver using MaxSAT
  - Uses python-sat library
  - Supports weighted optimization
- **MiniSatSolver**: SAT-based solver using MiniSat
  - Uses python-sat library
  - Supports weighted optimization

## New Analyzers (1 added)
- **ResultAnalyzer**: Analyzes maximization results
  - Compares installed vs proposed packages
  - Generates compatibility matrices
  - Provides dependency analysis
  - Supports solver comparison

## New Utilities
- **CacheManager**: Caching system for results
  - File-based and in-memory caching
  - TTL support
  - Cache decorator
- **BenchmarkRunner**: Performance testing framework
  - Generates test packages
  - Runs benchmarks across solvers
  - Exports reports (JSON, CSV)

## Updates
- Updated PackageMaximizer to support new components
- Updated solver registry with MaxSAT and MiniSat
- Updated parser registry with Pacman, DNF, Brew
- Added analyzer registry
- Version bump: 0.2.0 -> 0.3.0

## Tests
- Added 60+ new tests for all new components
- Total tests: 114 (all passing)

Closes #2

Co-authored-by: dominicusin <dominicusin@users.noreply.github.com>

* feat: implement Phase 3 - version constraints, enhanced solver, and real repo integration

Phase 3 implementation includes:

## New Core Features
- **VersionConstraint**: Support for version comparison operators
  - ==, !=, >, >=, <, <=, ~ (compatible version)
  - Parses semantic versions (1.2.3, 2.0.0, etc.)
  - Handles version ranges
- **DependencyConstraint**: Version-aware dependency checking
- **ConflictConstraint**: Version-aware conflict detection
- **ConstraintParser**: Parses constraint strings into objects
  - Supports complex dependency specifications
  - Handles version constraints in dependencies and conflicts

## New Solver
- **EnhancedGreedySolver**: Improved greedy algorithm
  - Version constraint awareness
  - Smart dependency handling
  - Priority-based package selection
  - Configurable conflict resolution (skip/remove)
  - Weight support

## New Integration
- **RealRepoIntegration**: Integration with real package managers
  - APT (Debian/Ubuntu)
  - Pacman (Arch Linux)
  - DNF (Fedora/RHEL/CentOS)
  - Brew (macOS)
  - Methods:
    - get_installed_packages()
    - search_packages()
    - get_package_info()
    - check_package_installed()
    - get_available_updates()
    - get_system_info()

## Core Updates
- Updated PackageMaximizer to support version constraints
- Enhanced solver registry with EnhancedGreedySolver
- Version bump: 0.3.0 -> 0.4.0

## Tests
- Added 40+ new tests for constraints, enhanced solver, and integrations
- Total tests: 161 (100% pass rate)

## Usage Examples

### Version Constraints

### Enhanced Greedy Solver

### Real Repository Integration

Closes #3

Co-authored-by: dominicusin <dominicusin@users.noreply.github.com>

* feat: implement Phase 4 - enhanced CLI, improved documentation, and final touches

Phase 4 implementation includes:

## New CLI Commands (5 added)
- **list-installed**: Show installed packages from system
  - Options: --manager, --limit, --output (text/json)
- **search**: Search packages in repository
  - Options: --manager, --limit, --output (text/json)
- **info**: Show package information
  - Options: --manager, --output (text/json)
- **check-updates**: Check for available updates
  - Options: --manager, --output (text/json)
- **system-info**: Show system and package manager information
  - Options: --manager, --output (text/json)

## CLI Improvements
- Updated all commands to support --output json option
- Enhanced error handling
- Better help messages
- Consistent output formatting
- Support for all package managers in CLI commands

## Documentation
- **Completely rewritten README.md** with:
  - Project overview and features
  - Installation instructions
  - Quick start guide
  - Python API documentation
  - CLI usage examples
  - Solver comparison table
  - Configuration guide
  - Testing instructions
  - Contribution guidelines
- Added badges (Python version, license, GitHub stats)
- Organized by use cases

## Core Updates
- Updated __init__.py exports for all new components
- Version bump: 0.4.0 -> 0.5.0

## Tests
- Added tests for new CLI commands (test_cli_extended.py)
- Total tests: 175 (100% pass rate)

## CLI Usage Examples

### Package Management

### Maximization

### Information

## Final Project Status

### All Phases Completed ✅
- Phase 1: Core solvers (4), parsers (1), CLI, tests (52)
- Phase 2: Additional parsers (3), solvers (2), analyzer, cache, benchmark (114 tests)
- Phase 3: Version constraints, enhanced solver, real repo integration (161 tests)
- Phase 4: Enhanced CLI, documentation, final touches (175 tests)

### Total Statistics
- **Files**: 40+ Python files
- **Tests**: 175 (100% pass rate)
- **Solvers**: 7 (Greedy, EnhancedGreedy, Z3, PuLP, OR-Tools, MaxSAT, MiniSat)
- **Parsers**: 4 (APT, Pacman, DNF, Brew)
- **Integrations**: 1 (RealRepoIntegration)
- **Utilities**: 2 (CacheManager, BenchmarkRunner)
- **CLI Commands**: 11

Closes #4

Co-authored-by: dominicusin <dominicusin@users.noreply.github.com>

---------

Co-authored-by: Vibe Nuage Agent <vibe@mistral.ai>
Co-authored-by: dominicusin <dominicusin@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

0