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

Add secp256k1 deps to dockerfile #235

Merged
merged 1 commit into from May 22, 2023

Conversation

ebrakke
Copy link
Collaborator

@ebrakke ebrakke commented May 19, 2023

The dockerfile was failing to build because it was missing some dependencies needed by https://github.com/rustyrussell/secp256k1-py

To test:

docker build .

@AngusP
Copy link
Collaborator

AngusP commented May 20, 2023

failing to build

Interesting, what error were you getting? It built and ran OK for me, albeit using podman instead of Docker -- or was there a runtime error?

@ebrakke
Copy link
Collaborator Author

ebrakke commented May 20, 2023

It was a build error when trying to do poetry install, saying it couldn’t find make.

I can try to get the original error message I was seeing, but was unable to build via docker directly on my Mac.

@ebrakke
Copy link
Collaborator Author

ebrakke commented May 20, 2023

#13 4.378   ChefBuildError
#13 4.378 
#13 4.378   Backend subprocess exited when trying to invoke get_requires_for_build_wheel
#13 4.378   
#13 4.378   'pkg-config' is required to install this package. Please see the README for details.
#13 4.378   
#13 4.378 
#13 4.378   at ~/.local/share/pypoetry/venv/lib/python3.9/site-packages/poetry/installation/chef.py:152 in _prepare
#13 4.386       148│ 
#13 4.386       149│                 error = ChefBuildError("\n\n".join(message_parts))
#13 4.386       150│ 
#13 4.386       151│             if error is not None:
#13 4.386     → 152│                 raise error from None
#13 4.386       153│ 
#13 4.386       154│             return path
#13 4.386       155│ 
#13 4.386       156│     def _prepare_sdist(self, archive: Path, destination: Path | None = None) -> Path:
#13 4.386 
#13 4.386 Note: This error originates from the build backend, and is likely not a problem with poetry but with secp256k1 (0.14.0) not supporting PEP 517 builds. You can verify this by running 'pip wheel --use-pep517 "secp256k1 (==0.14.0)"'.
#13 4.386 
Server: Docker Desktop 4.8.2 (79419)
 Engine:
  Version:          20.10.14
  API version:      1.41 (minimum version 1.12)
  Go version:       go1.16.15
  Git commit:       87a90dc
  Built:            Thu Mar 24 01:45:44 2022
  OS/Arch:          linux/arm64
  Experimental:     false
 containerd:
  Version:          1.5.11
  GitCommit:        3df54a852345ae127d1fa3092b95168e4a88e2f8
 runc:
  Version:          1.0.3
  GitCommit:        v1.0.3-0-gf46b6ba
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

@AngusP
Copy link
Collaborator

AngusP commented May 20, 2023

Slightly concerning that his builds OK on Linux but not for you on your Mac... Also for me, automake got installed as a dependency from RUN apt-get install -y curl python3-dev autoconf g++

Just wondering, is there a chance you have an old version of python:3.9-slim on your system? i.e. does the build work without this change if you add --no-cache to docker build ...?

But otherwise, these dependencies seem safe to add to me 👍

@ebrakke
Copy link
Collaborator Author

ebrakke commented May 20, 2023

No luck even with --no-cache. Definitely a mac issue as I can't reproduce on my linux box, but I can reliably repro on two different mac machines. Even deleted all existing python images from both machines to ensure it was pulling the latest.

@codecov
Copy link

codecov bot commented May 21, 2023

Codecov Report

Patch coverage has no change and project coverage change: +0.15 🎉

Comparison is base (e25100c) 55.31% compared to head (8e49e87) 55.47%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #235      +/-   ##
==========================================
+ Coverage   55.31%   55.47%   +0.15%     
==========================================
  Files          41       41              
  Lines        3290     3288       -2     
==========================================
+ Hits         1820     1824       +4     
+ Misses       1470     1464       -6     

see 2 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@callebtc callebtc merged commit a3ded1c into cashubtc:main May 22, 2023
4 checks passed
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.

None yet

3 participants