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 .gitignore to avoid tracking python-generated files #84

Merged
merged 1 commit into from
Mar 17, 2025

Conversation

theStack
Copy link
Contributor

Avoids tracking pre-compiled python files that are created in the course of running the tests or examples for the first time, e.g. on master:

$ ./python/tests.sh && git status
On branch master
Your branch is up to date with 'origin/master'.

Untracked files:
  (use "git add <file>..." to include in what will be committed)
        python/__pycache__/
        python/chilldkg_ref/__pycache__/
        python/secp256k1lab/__pycache__/

nothing added to commit but untracked files present (use "git add" to track)

@real-or-random
Copy link
Collaborator

Perhaps just add https://github.com/github/gitignore/blob/main/Python.gitignore, or better, a hand-picked selection of the sections in this file?

Avoids tracking pre-compiled python files that are created
in the course of running the tests or examples for the first time.
@theStack theStack changed the title Ignore *.pyc files Add .gitignore to avoid tracking python-generated files Mar 17, 2025
@theStack
Copy link
Contributor Author

Perhaps just add https://github.com/github/gitignore/blob/main/Python.gitignore, or better, a hand-picked selection of the sections in this file?

Didn't pick by hand, but used the one that uv creates by default as a starting point:

$ uv --version
uv 0.6.6
$ uv init test_project
Initialized project `test-project` at `/home/thestack/test_project`
$ cat test_project/.gitignore
# Python-generated files
__pycache__/
*.py[oc]
build/
dist/
wheels/
*.egg-info

# Virtual environments
.venv

Not sure if they are all relevant for us, as bip-frost-dkg itself is not a python package though. Happy to take suggestions.

@jonasnick jonasnick merged commit 7203ca0 into BlockstreamResearch:master Mar 17, 2025
1 check passed
@theStack theStack deleted the ignore_pyc_files branch March 17, 2025 20:39
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.

3 participants