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

[python] ensure rust compiler is available for package install #2454

Merged
merged 1 commit into from
May 16, 2024

Conversation

brettlangdon
Copy link
Member

@brettlangdon brettlangdon commented May 14, 2024

Motivation

We are considering add rust native extensions to the dd-trace-py Python package. In order to support that, we need a rust compiler available for us.

Changes

Install rust compiler during install_ddtrace.sh.

I decided on install_ddtrace.sh instead of adding to the base images to make it potentially easier to keep build dependencies in one place.

Workflow

  1. ⚠️ Create your PR as draft ⚠️
  2. Work on you PR until the CI passes (if something not related to your task is failing, you can ignore it)
  3. Mark it as ready for review
    • Test logic is modified? -> Get a review from RFC owner. We're working on refining the codeowners file quickly.
    • Framework is modified, or non obvious usage of it -> get a review from R&P team

🚀 Once your PR is reviewed, you can merge it!

🛟 #apm-shared-testing 🛟

Reviewer checklist

  • Relevant label (run-parametric-scenario, run-profiling-scenario...) are presents
  • If PR title starts with [<language>], double-check that only <language> is impacted by the change
  • No system-tests internal is modified. Otherwise, I have the approval from R&P team
  • CI is green, or failing jobs are not related to this change (and you are 100% sure about this statement)
  • A docker base image is modified?
    • the relevant build-XXX-image label is present
  • A scenario is added (or removed)?

@brettlangdon brettlangdon changed the title chore(python): ensure rust compiler is available for package install [python] ensure rust compiler is available for package install May 15, 2024
@brettlangdon brettlangdon marked this pull request as ready for review May 15, 2024 16:34
@brettlangdon brettlangdon requested review from a team as code owners May 15, 2024 16:34
@juanjux
Copy link
Contributor

juanjux commented May 15, 2024

image

@@ -2,6 +2,9 @@

set -eu

# Install Rust toolchain
curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain stable -y
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: maybe would be safer to cache the script in the repository? Just in case rustup.rs is compromised, trough this a docker image so consider this a non blocking nit.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure, this is similar to what we do in other places... but... 🤷🏻

@brettlangdon brettlangdon merged commit 4141826 into main May 16, 2024
85 of 93 checks passed
@brettlangdon brettlangdon deleted the brettlangdon/python.rust branch May 16, 2024 12:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants