Skip to content
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

[Bug]: Confusing line numbers in EclassExportFuncsBeforeInherit #703

Open
1 task done
thesamesam opened this issue Sep 23, 2024 · 0 comments
Open
1 task done

[Bug]: Confusing line numbers in EclassExportFuncsBeforeInherit #703

thesamesam opened this issue Sep 23, 2024 · 0 comments
Labels

Comments

@thesamesam
Copy link
Member

thesamesam commented Sep 23, 2024

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

At b1620a6c399a9950305159728dd9d7fc40e7dfe8 in gentoo.git:

$ pkgcheck scan -k EclassExportFuncsBeforeInherit
eclass
  EclassExportFuncsBeforeInherit: guile-single: EXPORT_FUNCTIONS (line 243) called before inherit (line 115)
  EclassExportFuncsBeforeInherit: xdg: EXPORT_FUNCTIONS (line 48) called before inherit (line 28)

But, for example, in guile-single.eclass, we have:

case "${EAPI}" in
        8) ;;
        *) die "${ECLASS}: EAPI ${EAPI:-0} not supported" ;;
esac

if [[ ! "${_GUILE_SINGLE_ECLASS}" ]]; then
_GUILE_SINGLE_ECLASS=1

inherit guile-utils
[...]
EXPORT_FUNCTIONS pkg_setup src_prepare src_install

fi  # _GUILE_SINGLE_ECLASS

Saying a line was called before another is confusing, especially if an inherit guard is active. I can maybe see it if one isn't...

Expected Behavior

Clearer error if it's even a true-positive. (Unclear what's happening but the "... called before ..." line being later than the "inherit" line is weird.)

pkgcheck version

0.10.31

pkgcore version

0.12.28

@thesamesam thesamesam added the bug label Sep 23, 2024
gentoo-bot pushed a commit to gentoo/gentoo that referenced this issue Sep 25, 2024
gentoo-bot pushed a commit to gentoo/gentoo that referenced this issue Sep 25, 2024
gentoo-bot pushed a commit to gentoo/gentoo that referenced this issue Sep 25, 2024
miasvanklei pushed a commit to miasvanklei/gentoo that referenced this issue Sep 26, 2024
miasvanklei pushed a commit to miasvanklei/gentoo that referenced this issue Sep 26, 2024
miasvanklei pushed a commit to miasvanklei/gentoo that referenced this issue Sep 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant