All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works
@ 2022-03-30  0:39 bugzilla
  2022-03-30  3:17 ` [Buildroot] [Bug 14721] " bugzilla
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: bugzilla @ 2022-03-30  0:39 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14721

            Bug ID: 14721
           Summary: python-argon2_cffi no longer works
           Product: buildroot
           Version: unspecified
          Hardware: All
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P5
         Component: Other
          Assignee: unassigned@buildroot.uclibc.org
          Reporter: emile.cormier.jr@gmail.com
                CC: buildroot@uclibc.org
  Target Milestone: ---

Created attachment 9256
  --> https://bugs.busybox.net/attachment.cgi?id=9256&action=edit
Snippet of the build log concerning argon2-cffi and argon2-cffi-bindings

Commit
https://github.com/buildroot/buildroot/commit/e2957f5ce743cfaf4fb3aaa98d619e83e8e6989e
breaks the argon2-cffi Python package for my ARM target (Beaglebone Black).

The installation of the argon2-cffi Python package somehow got broken with the
version bump. Just before that commit, I get (via serial terminal):

# python -c 'help("modules")' | grep argon2
__future__          argon2              gzip                selectors

# python -c 'from argon2 import PasswordHasher;
print(PasswordHasher().hash("cor
rect horse battery staple"));'
$argon2id$v=19$m=102400,t=2,p=8$qHc/evoNvfGlp98pE26Ayw$tZWcHYjxFTKDUoaSysapPA

And just after that commit, I get:
# python -c 'help("modules")' | grep argon2
_argon2_cffi_bindings ast                 hmac                shutil

Traceback (most recent call last):
  File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'argon2'

argon2-cffi is the only Python package I have enabled via menu xconfig for this
test.

I've attached a snippet of the build log concerning argon2-cffi and
argon2-cffi-bindings.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] [Bug 14721] python-argon2_cffi no longer works
  2022-03-30  0:39 [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works bugzilla
@ 2022-03-30  3:17 ` bugzilla
  2022-03-30  4:11 ` bugzilla
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla @ 2022-03-30  3:17 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14721

--- Comment #1 from Emile Cormier <emile.cormier.jr@gmail.com> ---
TL;DR: The new Python flit setup infrastructure seems to be deploying to the
wrong destination directory.

-----

I see now that argon2-cffi now uses the new flit setup type. The argon2-cffi
package now gets installed under

    /lib/python3.10/site-packages/argon2

whereas it used to be installed under

    /usr/lib/python3.10/site-packages


Here's the output of 'python -m site' on my BeagleBone Black device:

sys.path = [
    '/lib/python3.10/site-packages/argon2',
    '/usr/lib/python310.zip',
    '/usr/lib/python3.10',
    '/usr/lib/python3.10/lib-dynload',
    '/usr/lib/python3.10/site-packages',
]
USER_BASE: '/root/.local' (doesn't exist)
USER_SITE: '/root/.local/lib/python3.10/site-packages' (doesn't exist)
ENABLE_USER_SITE: True


If I add /lib/python3.10/site-packages to the "real" system-wide site-packages
via:

    echo "/lib/python3.10/site-packages" >
/usr/lib/python3.10/site-packages/extra.pth

then argon2 now appears in

    python -c 'help("modules")'

and the following test command works!

    # python -c 'from argon2 import PasswordHasher;
print(PasswordHasher().hash("correct horse battery staple"));'
   
$argon2id$v=19$m=65536,t=3,p=4$CZO2H3qcZr/Vp9w0qVpLxA$eAz24Ry+cvSdRTJaPYDcf9HTc/Zyq/PmoFkFFPcQHm0

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] [Bug 14721] python-argon2_cffi no longer works
  2022-03-30  0:39 [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works bugzilla
  2022-03-30  3:17 ` [Buildroot] [Bug 14721] " bugzilla
@ 2022-03-30  4:11 ` bugzilla
  2022-04-03  9:42 ` bugzilla
  2022-04-03 19:15 ` bugzilla
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla @ 2022-03-30  4:11 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14721

--- Comment #2 from Emile Cormier <emile.cormier.jr@gmail.com> ---
I've tracked it down to package/pkg-python.mk using

/lib/python$(PYTHON3_VERSION_MAJOR)/site-packages

instead of

/usr/lib/python$(PYTHON3_VERSION_MAJOR)/site-packages

Submitted a patch via the mailing list:
https://lists.buildroot.org/pipermail/buildroot/2022-March/639798.html

I can import and use the argon2 module in a Python program with those changes.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] [Bug 14721] python-argon2_cffi no longer works
  2022-03-30  0:39 [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works bugzilla
  2022-03-30  3:17 ` [Buildroot] [Bug 14721] " bugzilla
  2022-03-30  4:11 ` bugzilla
@ 2022-04-03  9:42 ` bugzilla
  2022-04-03 19:15 ` bugzilla
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla @ 2022-04-03  9:42 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14721

Yann E. MORIN <yann.morin.1998@free.fr> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #3 from Yann E. MORIN <yann.morin.1998@free.fr> ---
Emile, All,

Thans for your bug report. We believe this has now been fixed with
commit 5bea8c9521b3 (package/pkg-python.mk: fix PEP517 paths).

Regards,
Yann E. MORIN.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [Buildroot] [Bug 14721] python-argon2_cffi no longer works
  2022-03-30  0:39 [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works bugzilla
                   ` (2 preceding siblings ...)
  2022-04-03  9:42 ` bugzilla
@ 2022-04-03 19:15 ` bugzilla
  3 siblings, 0 replies; 5+ messages in thread
From: bugzilla @ 2022-04-03 19:15 UTC (permalink / raw)
  To: buildroot

https://bugs.busybox.net/show_bug.cgi?id=14721

--- Comment #4 from Emile Cormier <emile.cormier.jr@gmail.com> ---
I confirm that the PasswordHasher test works for me with the latest master.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2022-04-03 19:15 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-30  0:39 [Buildroot] [Bug 14721] New: python-argon2_cffi no longer works bugzilla
2022-03-30  3:17 ` [Buildroot] [Bug 14721] " bugzilla
2022-03-30  4:11 ` bugzilla
2022-04-03  9:42 ` bugzilla
2022-04-03 19:15 ` bugzilla

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.