Skip to content

Conversation

@APN-Pucky
Copy link
Member

Closes: #177

@codecov
Copy link

codecov bot commented Oct 18, 2024

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.86%. Comparing base (04f3577) to head (da15ffe).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #266   +/-   ##
=======================================
  Coverage   94.86%   94.86%           
=======================================
  Files           2        2           
  Lines         331      331           
  Branches       61       61           
=======================================
  Hits          314      314           
  Misses         10       10           
  Partials        7        7           
Flag Coverage Δ
unittests-3.10 94.86% <ø> (ø)
unittests-3.11 94.86% <ø> (ø)
unittests-3.12 94.86% <ø> (ø)
unittests-3.13 94.86% <ø> (ø)
unittests-3.9 94.86% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@APN-Pucky
Copy link
Member Author

APN-Pucky commented Oct 18, 2024

@matthewfeickert I am trying to create a 0.9.1 version and I followed your video, but https://github.com/scikit-hep/pylhe/actions/runs/11403842254/job/31731751820#step:8:46 here "Bump version" fails with

fatal: Failed to resolve 'v0.9.1^{}' as a valid ref.

Further I still need to figure out conda after pypi.

@APN-Pucky
Copy link
Member Author

@matthewfeickert @eduardo-rodrigues Can one of you help with releasing pylhe 0.9.1?

@eduardo-rodrigues
Copy link
Member

It is best that @matthewfeickert helps as I have not released here so far. I tend to do my releases a different way. Can you help out @matthewfeickert?

Aside - this PR isn't done, right? Maybe better have this "admin" doc under the docs directory?

@matthewfeickert
Copy link
Member

I am trying to create a 0.9.1 version and I followed your video, but https://github.com/scikit-hep/pylhe/actions/runs/11403842254/job/31731751820#step:8:46 here "Bump version" fails with

fatal: Failed to resolve 'v0.9.1^{}' as a valid ref.

Further I still need to figure out conda after pypi.

@APN-Pucky Sorry, I've been pretty distracted (feel free to poke me on email/Slack if I'm not responsive on GitHub as my notifications can become just a wall sometimes). Can you tell me where you're hitting this specifically in the release workflow?

@matthewfeickert
Copy link
Member

matthewfeickert commented Nov 5, 2024

I fixed @APN-Pucky not having publishing permissions in PR #269, but I also went ahead and released v0.9.1 which is now on PyPI.

Further I still need to figure out conda after pypi.

@APN-Pucky the good news is that there really isn't anything to figure out. Conda-forge automatically watches PyPI for new releases and will generate a new release PR to https://github.com/conda-forge/pylhe-feedstock for us in a few hours. We then just review it to make sure there are no dependency changes and then we can merge it and conda-forge will then do all the building and publishing automatically.

@APN-Pucky APN-Pucky marked this pull request as ready for review November 11, 2024 12:59
@APN-Pucky
Copy link
Member Author

I will try to create a release for v0.9.2 following the steps outlined in this PR.

@APN-Pucky
Copy link
Member Author

@matthewfeickert Unfortunately, running the dry run bump-version for 0.9.2 fails already https://github.com/scikit-hep/pylhe/actions/runs/15856437537/job/44702856720.

Error: fatal: could not read Username for 'https://github.com/': terminal prompts disabled
  The process '/usr/bin/git' failed with exit code 128

@matthewfeickert
Copy link
Member

matthewfeickert commented Jun 24, 2025

Yeah, seems unhappy about the auth I guess?

Initializing the repository
  /usr/bin/git init /home/runner/work/pylhe/pylhe
  hint: Using 'master' as the name for the initial branch. This default branch name
  hint: is subject to change. To configure the initial branch name to use in all
  hint: of your new repositories, which will suppress this warning, call:
  hint:
  hint: 	git config --global init.defaultBranch <name>
  hint:
  hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
  hint: 'development'. The just-created branch can be renamed via this command:
  hint:
  hint: 	git branch -m <name>
  Initialized empty Git repository in /home/runner/work/pylhe/pylhe/.git/
  /usr/bin/git remote add origin https://github.com/scikit-hep/pylhe
Disabling automatic garbage collection
  /usr/bin/git config --local gc.auto 0
Setting up auth
  /usr/bin/git config --local --name-only --get-regexp core\.sshCommand
  /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'core\.sshCommand' && git config --local --unset-all 'core.sshCommand' || :"
  /usr/bin/git config --local --name-only --get-regexp http\.https\:\/\/github\.com\/\.extraheader
  /usr/bin/git submodule foreach --recursive sh -c "git config --local --name-only --get-regexp 'http\.https\:\/\/github\.com\/\.extraheader' && git config --local --unset-all 'http.https://github.com/.extraheader' || :"
  /usr/bin/git config --local http.https://github.com/.extraheader AUTHORIZATION: basic ***
Fetching the repository
  /usr/bin/git -c protocol.version=2 fetch --prune --no-recurse-submodules origin +refs/heads/*:refs/remotes/origin/* +refs/tags/*:refs/tags/*
  Error: fatal: could not read Username for 'https://github.com': terminal prompts disabled
  The process '/usr/bin/git' failed with exit code 128
  Waiting 18 seconds before trying again
  /usr/bin/git -c protocol.version=2 fetch --prune --no-recurse-submodules origin +refs/heads/*:refs/remotes/origin/* +refs/tags/*:refs/tags/*
  Error: fatal: could not read Username for 'https://github.com': terminal prompts disabled
  The process '/usr/bin/git' failed with exit code 128
  Waiting 11 seconds before trying again
  /usr/bin/git -c protocol.version=2 fetch --prune --no-recurse-submodules origin +refs/heads/*:refs/remotes/origin/* +refs/tags/*:refs/tags/*
  Error: fatal: could not read Username for 'https://github.com': terminal prompts disabled
  Error: The process '/usr/bin/git' failed with exit code 128

my suggestion is to check to see if there's examples in the GitHub docs to have the auth get setup correctly for workflow dispatch operations, and if not, then fall back to a simpler release workflow like given in https://learn.scientific-python.org/development/guides/gha-pure/.

@eduardo-rodrigues
Copy link
Member

Hi @matthewfeickert, is the release something you could help out, assuming the workflow still works for you as in the past? I'm quite loaded this week to investigate, as I'm at the EPPSU Open Symposium.

(I will put it on my list to look at the release when back next week ... In the end it should be easy, at least things work really smoothly and easily for Particle and DecayLanguage.)

@APN-Pucky
Copy link
Member Author

APN-Pucky commented Jun 30, 2025

@matthewfeickert

# Use GitHub PAT to authenticate so other workflows trigger
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
token: ${{ secrets.ACCESS_TOKEN }}

Apparently this uses a Personal access token, maybe it expired (if it did not work for you either). Unfortunately, the default GITHUB_TOKEN does not trigger workflows based on the comment. Or github added more fine grained permissions.

@APN-Pucky
Copy link
Member Author

BTW. I personally prefer to just run the release pipeline whenever a tag is pushed (vX.Y.Z) instead of manually triggering runs. I can restructure the CI to something simpler, if the existing system can not somehow be saved.

@eduardo-rodrigues
Copy link
Member

Hi. Yep, I also reckon the present system is a bit too complicated. As I said I have things nice and easy for my packages, and @matthewfeickert seems to agree to simplify as well. Let me know if you need help.

@APN-Pucky
Copy link
Member Author

APN-Pucky commented Jul 2, 2025

I just ran tbump manually (like the bump-version does) and pushed it. Let's see if the publish action does it's job right.

@eduardo-rodrigues
Copy link
Member

Happy it worked!

@eduardo-rodrigues
Copy link
Member

Unfortunately it's not working OK on the conda feedstock, see conda-forge/pylhe-feedstock#13 :(.

@eduardo-rodrigues
Copy link
Member

Unfortunately it's not working OK on the conda feedstock, see conda-forge/pylhe-feedstock#13 :(.

This has been fixed. All good there.

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.

Write developer.md to explain maintainers process

3 participants