← Back to issue list

elf: conversion from libraries

View original Github issue

Metadata

Project
snapcraft
Number
#1744
Type
pull request
State
merged
Author
sergiusens
Labels
—
Created
Updated
Closed

Current evaluation

Merged as ec7ba948a: converted snapcraft/internal/libraries.py into ELF-focused elf.py with type hints and mypy fixes, fixing #1666. Reviewer syntax/lint concerns were handled by follow-up PR #1745 (flake8 upgrade).

Resolution: closed resolved

Reason: The PR itself was merged into master as commit ec7ba948a ("elf: conversion from libraries (#1744)"), landing the libraries-to-elf module conversion plus type annotations, and explicitly fixes issue #1666.

Evaluated by: mr-cal-bot

No scores available.

Issue body

Converting the libraries module into elf and making it more focused on handling elf files as a whole. The logic also has type hinting annotations with the associated fixes from running with mypy. Fixes: #1666 Signed-off-by: Sergio Schvezov <sergio.schvezov@canonical.com> Signed-off-by: Sergio Schvezov <sergio.schvezov@canonical.com> - [x] Have you followed the [guidelines for contributing](https://github.com/snapcore/snapcraft/blob/master/CONTRIBUTING.md)? - [x] Have you signed the [CLA](http://www.ubuntu.com/legal/contributors/)? - [x] If this is a bugfix. Have you checked that there is a bug report open for the issue you are trying to fix on [bug reports](https://bugs.launchpad.net/snapcraft)? - [x] If this is a new feature. Have you discussed the design on the [forum](https://forum.snapcraft.io)? - [x] Have you successfully run `./runtests.sh static`? - [x] Have you successfully run `./runtests.sh unit`? -----

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged as ec7ba948a: converted snapcraft/internal/libraries.py into ELF-focused elf.py with type hints and mypy fixes, fixing #1666. Reviewer syntax/lint concerns were handled by follow-up PR #1745 (flake8 upgrade).
stealth/space-bunny-alpha — closed resolved Merged as commit ec7ba948a: snapcraft's libraries module was converted into an elf-focused module (snapcraft/internal/elf.py) with type hints and mypy fixes, closing #1666.
stealth/space-bunny-alpha — closed resolved Merged PR #1744 as ec7ba948a, converting the libraries module into an ELF-focused module, adding type hints and mypy fixes, and resolving #1666.
qwen/qwen3.6-35b-a3b — — Merged conversion of the libraries module into elf, incorporating type hints and mypy fixes. Reviewers requested integrating type checks into static tests and ensuring Python 3.5 compatibility; these were addressed before final approval and merge.
qwen3.6-35b-a3b-mtp-q6 — — Merged refactoring of the libraries module into a dedicated elf module for focused ELF file handling. Incorporated mypy-compatible type hints and addressed Python 3.5 compatibility. Closes #1666.

Update history

No update history recorded yet.

Related work

  • Related To: canonical/snapcraft#1666 (confidence 90%)

    Tracked issue "Refactor to support elf patching" that this PR was declared to fix.

  • Related To: canonical/snapcraft#1745 (confidence 80%)

    Follow-up merged PR upgrading flake8 in static tests; referenced in review comments to clear the CI lint failure blocking this PR.

Related issues

Issue Project State Summary Similarity
#2929 elf: fixes for corrupt shared objects snapcraft merged Merged PR snapcore/snapcraft#2929 (commit 051f24e07, Feb 2020) catching elftools ConstructErrors as CorruptedElfFileError and skipping corrupt shared objects during library crawling.
73%
#75 refactor: rewrite elf file support debcraft merged Merged as c841273, replacing Snapcraft-derived ELF handling with deb-oriented library dependency support. Symbol support was deferred to follow-up work.
72%
#1913 elf: pyelftools to parse ELF files rather than readelf snapcraft merged Merged PR #1913 (commit 9e4e88629): snapcraft.internal.elf.ElfFile now parses ELF files with pyelftools instead of shelling out to readelf, handling weak refs outside DT_NEEDED; cut test build times roughly in half.
70%
#3839 elf: add elf file handler class snapcraft merged PR #3839 was merged into main as commit 6830dc69c, porting the Snapcraft 6.x ElfFile handler into snapcraft/elf/_elf_file.py with helpers, ELF errors, and unit tests (CRAFT-1192).
70%