-
-
Notifications
You must be signed in to change notification settings - Fork 9
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
sphobjinv-textconv #307
sphobjinv-textconv #307
Conversation
During python setup, gh runner failings to download python 3.13 for linux and windows. The runner says could be caused by an authentication issue. ##[error]Failed to download Python from the Github Actions python registry python-versions. Error: Error: Failed to download Python versions manifest from the Github Actions python registry python-versions. Invalid GitHub token could cause this. ##[error]Version spec 3.13 for architecture x64 did not match any version in Agent.ToolsDirectory. This is the relevent entries from the versions manifest. (to save time searching thru it)
|
That same config worked recently for a different pipeline, so I don't think it's a config or token problem. More likely, there was just a transient issue with the GitHub Python repository. I'll trigger a retry; if it still fails, then let's just remove 3.13 from I'm working on an overhaul of the CI (#306) that will migrate everything over to GitHub Actions anyways, which has 3.13 natively available. |
No, still fails with the same errors. Just remove 3.13 from the Azure DevOps matrix. |
Yes please retrigger the pipeline.
If needed and plan to remove of 3.13 from azure-pipelines.yml, please have me make a commit rather than causing more rebases to be necessary.
Rebases are scary.
Know the final code state, but not intern code states; what the code should look between `git rebase --continue` calls
…On Thursday, January 2nd, 2025 at 4:05 PM, Brian Skinn ***@***.***> wrote:
That same config [worked recently](https://dev.azure.com/brianskinn/sphobjinv/_build/results?buildId=573&view=logs&jobId=337cb850-2e3b-5931-1662-6e2a73a4cc60&j=337cb850-2e3b-5931-1662-6e2a73a4cc60&t=cdcb6bd4-70a6-5618-7395-9b57861e9608) for a different pipeline, so I don't think it's a config or token problem. More likely, there was just a transient issue with the GitHub Python repository. I'll trigger a retry; if it still fails, then let's just remove 3.13 from azure-pipelines.yml and not worry about it.
I'm working on an overhaul of the CI ([#306](#306)) that will migrate everything over to GitHub Actions anyways, which has 3.13 natively available.
—
Reply to this email directly, [view it on GitHub](#307 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/AVSZJ2ID6GG2CGARM7PENIL2IVPTRAVCNFSM6AAAAABUNNRT3KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNRYGAYDONRTHE).
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
With py313 removed, the pipeline passes
…On Sunday, January 5th, 2025 at 4:33 AM, msftcangoblowme ***@***.***> wrote:
Yes please retrigger the pipeline.
If needed and plan to remove of 3.13 from azure-pipelines.yml, please have me make a commit rather than causing more rebases to be necessary.
Rebases are scary.
Know the final code state, but not intern code states; what the code should look between `git rebase --continue` calls
On Thursday, January 2nd, 2025 at 4:05 PM, Brian Skinn ***@***.***> wrote:
> That same config [worked recently](https://dev.azure.com/brianskinn/sphobjinv/_build/results?buildId=573&view=logs&jobId=337cb850-2e3b-5931-1662-6e2a73a4cc60&j=337cb850-2e3b-5931-1662-6e2a73a4cc60&t=cdcb6bd4-70a6-5618-7395-9b57861e9608) for a different pipeline, so I don't think it's a config or token problem. More likely, there was just a transient issue with the GitHub Python repository. I'll trigger a retry; if it still fails, then let's just remove 3.13 from azure-pipelines.yml and not worry about it.
>
> I'm working on an overhaul of the CI ([#306](#306)) that will migrate everything over to GitHub Actions anyways, which has 3.13 natively available.
>
> —
> Reply to this email directly, [view it on GitHub](#307 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/AVSZJ2ID6GG2CGARM7PENIL2IVPTRAVCNFSM6AAAAABUNNRT3KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDKNRYGAYDONRTHE).
> You are receiving this because you authored the thread.Message ID: ***@***.***>
|
Mm, I didn't think about the rebase being such a problem... merging |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Duplicating the review comments from #301
After a quick sync, the latest commit addresses the issues you brought up, besides |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Several more comments across the PR. Still haven't had a chance to dig deeply into the new code itself, or the docs. Will get there.
Please rerun azure pipelines. Getting remotedisconnect and ssl errors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your patience as I nibble-review on this!
tox.ini
Outdated
# cd .tox; PYTHONPATH=../ tox --root=.. -c ../tox.ini \ | ||
# -e py39-sphx_latest-attrs_latest-jsch_latest --workdir=.; cd - &>/dev/null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are these commented-out lines still needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instantly forget complicated commands.
For collaborators, somewhere these commands should be documented. I prefer in context, so zero time is wasted recreating them.
non-tox commands should be in a Makefile.
pytest commands within the respective test module.
Have always written, just the complicated, tox commands within the tox file.
This particular command is how to invoke for pyenv users. The active .python-version
file differs for: project base (one py version) and the .tox
folder (many py versions)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't understand - why are you running the Python from tox environment instead of just executing pytest
from the root of the repository with an activated and configured virtual environment, as per CONTRIBUTING.md
?
As noted there, tox
on this project isn't really intended for contributor use. The matrix of test envs in tox.ini
is for my benefit, as part of my release process.
If it works to create a new virtual environment with a pyenv-managed Python, activate that virtual environment, pip-install requirements-dev.txt
into it, and run pytest
, then that should be the workflow.
I'm going to take a lot of persuading to keep this in here. If this invocation really is important to document, it should be in CONTRIBUTING.md
and include more context and probably more instructions.
Hey, @msftcangoblowm -- sorry for the delay, thanks for your patience. First thing -- I've merged the rework of the CI. Please delete |
Code review wise -- I think it'll be best to work on the code first, and then follow with the docs once the code is settled. First, high-level, I'm not sure what the value is for having so much re-implemented in the new
It also seems like there's a lot of unnecessary/irrelevant logic in In sum -- I think all of the new functional code should be much slimmer. Is that workable, to make a trim-down refactoring pass on everything? Second, related -- I'm having a hard time understanding the purpose/function of (If they are needed for some remaining tests to function correctly, please make an attempt to revise the tests so that they can successfully use the original Thanks! |
As far as i'm concerned, if the comment bothers you, i can remove it. Especially if this is the only thing holding up the PR merge.
### Why i've been using tox
Since sphobjinv supports three OS using a variety of py interpreters, before submitting a commit, been testing all that i can. To be confident have reduced the surface area of possible issues. Or at least what i can, since don't have Windows and MacOS VMs to test everything locally.
The workflow you described is enough for the dev venv with the main/default py interpreter. The entire point of tox is to test multiple py interpreters in **isolated** environments. Avoids, `well it works on my dev environment` fallacy.
Why is testing multiple py interpreters only for you and not contributors?! Testing should occur per commit. Both you and contributors test. Contributors normally would use tox. isolated environments matter.
By stating, `don't use my tox`, that would mean avoidable errors aren't being tested and found, causing lots of additional commits. This is unavoidable for Windows and MacOS, but avoidable for Linux.
There is the additional issue of `azure-pipelines.yml` being flaky. So lets say a commit has errors. Am i supposed to wait for you each time to click a button to rerun the pipeline? Especially when it's an issue i coulda caught locally.
Normally, the test and release processes are separate. The release process is normally triggered upon setting a tag and pushing the tag.
If you want me to remove the comment, just tell me and i will.
…On Monday, February 10th, 2025 at 4:56 AM, Brian Skinn ***@***.***> wrote:
@bskinn commented on this pull request.
---------------------------------------------------------------
In [tox.ini](#307 (comment)):
> +# cd .tox; PYTHONPATH=../ tox --root=.. -c ../tox.ini \
+# -e py39-sphx_latest-attrs_latest-jsch_latest --workdir=.; cd - &>/dev/null
I don't understand - why are you running the Python from tox environment instead of just executing pytest from the root of the repository with an activated and configured virtual environment, as per [CONTRIBUTING.md](https://github.com/bskinn/sphobjinv/blob/main/CONTRIBUTING.md)?
As noted there, tox on this project isn't really intended for contributor use. The matrix of test envs in tox.ini is for my benefit, as part of my release process.
If it works to create a new virtual environment with a pyenv-managed Python, activate that virtual environment, pip-install requirements-dev.txt into it, and run pytest, then that should be the workflow.
I'm going to take a lot of persuading to keep this in here. If this invocation really is important to document, it should be in CONTRIBUTING.md and include more context and probably more instructions.
—
Reply to this email directly, [view it on GitHub](#307 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/AVSZJ2PUB77K6A7SBA2THP32PAWQPAVCNFSM6AAAAABUNNRT3KVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDMMBUGY4DSNZQGU).
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
I appreciate your desire to have everything be tested cross-py and cross-platform. However, I see that as being the purpose of the CI. My contributor experience goal is for the direct efforts of contributors to only involve testing with whatever Python and platform they happen to be using; or, even not running tests locally at all, if they wish.
CI also provides this, with much lower effort by contributors.
Some testing per commit, yes. Exhaustive testing per commit, no, I disagree---at least not for ... unnecessary, actually, to the point where the CI overhaul of #306 actually made it possible for contributors to only have two test cases run on draft PRs, currently Python 3.12 on Ubuntu and Windows. Only when a PR is marked as 'ready' does a full text matrix run, plus linting. My hope is that this will allow for more rapid initial development for myself and for contributors; and, if a contributor wants the full test matrix from the outset, they have the option of leaving the PR in 'ready' state.
But the CI will catch them. And, it's been exceedingly rare, actually, that I've had a piece of work function fine on one actively supported version of Python, but fail on another---and similarly with the various runtime dependencies. Cross-platform issues have occurred more often, but they're pretty much a non-issue now that I've given up on doctesting the shell examples in the README.
Commits are cheap, I don't have any problem at all with contributions that contain many commits. I break my work up into lots of commits already, including lots of 'whoops, fix X' commits from mistakes I've made. I'm not at all concerned about a sprawling Git history, at least in If
Very good point. I actually already added some The inability for the PR author to rerun failed pipelines is quite annoying, but I understand it from a security perspective. (Maybe GitHub Actions makes it easier/possible for PR authors to trigger retries? Not sure.) In any event, the usual approach to this is to make another, trivial commit to kick off a new pipeline. Kind of janky, but it is what it is.
I misspoke. I meant to say that I use the All of this said, you're welcome to use But, in order to keep it as part of the PR, it would need to go in
No, it's unfortunately not the only thing preventing merge. Per my other comment, both the code and the docs will need significant work before the PR is merge-ready. High-level, there is just too much of both code and docs; both will need trimming and revision. And, I'm still leaning against uptaking any instructions for setting up a Git textconv into the repo... I don't really want that maintenance burden. |
tox and pyenv
if this invocation is what it takes to make tox work with pyenv Pythons, then it's worth documenting
Will write this up.
Then tox should only require a comment, `For usage see CONTRIBUTING.md`
Without which, would be non-obvious that instructions exist.
Commits are cheap
I'm glad you agree on this. Path handling, working on all platforms, took
alot of commits.
pytest-retry flaky marks to all of the --nonloc tests as part of #306
That's great. Hopefully that'll solve the Azure issue.
not the only thing preventing merge
When you get the time, let me know what would like trimmed.
Sounds great as long as it's applied after #307
And, it's been exceedingly rare, actually, that I've had a piece of work function fine on one actively supported version of Python, but fail on another---and similarly with the various runtime dependencies.
Although not in sphobjinv, in other packages, there is a gh workflow called, `Python Nightly`. Runs a limited matrix (two pypi dev and two pypy versions). Purpose is to quickly identify py interpreter or CI issues.
For package logging-strict, just received notification. Python Nightly failed for py312-dev. So know to take a look at it.
the usual approach to this is to make another, trivial commit
Hope #306 (retry) makes a trivial commit unnecessary.
…On Wednesday, February 12th, 2025 at 4:58 AM, Brian Skinn ***@***.***> wrote:
> Since sphobjinv supports three OS using a variety of py interpreters, before submitting a commit, been testing all that i can. To be confident have reduced the surface area of possible issues. Or at least what i can, since don't have Windows and MacOS VMs to test everything locally.
I appreciate your desire to have everything be tested cross-py and cross-platform. However, I see that as being the purpose of the CI. My contributor experience goal is for the direct efforts of contributors to only involve testing with whatever Python and platform they happen to be using; or, even not running tests locally at all, if they wish.
> The entire point of tox is to test multiple py interpreters in isolated environments.
CI also provides this, with much lower effort by contributors.
> Testing should occur per commit.
Some testing per commit, yes. Exhaustive testing per commit, no, I disagree---at least not for sphobjinv, as a pure-Python package. If it included, e.g., a compiled C or Rust extension I would lean more toward thorough per-commit testing; but as it is, it seems unnecessary.
... unnecessary, actually, to the point where the CI overhaul of [#306](#306) actually made it possible for contributors to only have two test cases run on draft PRs, currently Python 3.12 on Ubuntu and Windows. Only when a PR is marked as 'ready' does a full text matrix run, plus linting. My hope is that this will allow for more rapid initial development for myself and for contributors; and, if a contributor wants the full test matrix from the outset, they have the option of leaving the PR in 'ready' state.
> that would mean avoidable errors aren't being tested and found, ...
But the CI will catch them. And, it's been exceedingly rare, actually, that I've had a piece of work function fine on one actively supported version of Python, but fail on another---and similarly with the various runtime dependencies. Cross-platform issues have occurred more often, but they're pretty much a non-issue now that I've given up on doctesting the shell examples in the README.
> ... causing lots of additional commits.
Commits are cheap, I don't have any problem at all with contributions that contain many commits. I break my work up into lots of commits already, including lots of 'whoops, fix X' commits from mistakes I've made. I'm not at all concerned about a sprawling Git history, at least in sphobjinv. I actually prefer it, because a long chain of granular commits makes it much easier to follow the details of the arc of the development process.
If sphobjinv had a large, active, async dev team, with many feature branches active at once, I might feel differently. But it doesn't, so I have the luxury of not worrying about it.
> There is the additional issue of azure-pipelines.yml being flaky. So lets say a commit has errors. Am i supposed to wait for you each time to click a button to rerun the pipeline? Especially when it's an issue i coulda caught locally.
Very good point. I actually already added some pytest-retry flaky marks to all of the --nonloc tests as part of [#306](#306), to try to significantly reduce these spurious test failures.
The inability for the PR author to rerun failed pipelines is quite annoying, but I understand it from a security perspective. (Maybe GitHub Actions makes it easier/possible for PR authors to trigger retries? Not sure.) In any event, the usual approach to this is to make another, trivial commit to kick off a new pipeline. Kind of janky, but it is what it is.
> Normally, the test and release processes are separate. The release process is normally triggered upon setting a tag and pushing the tag.
I misspoke. I meant to say that I use the tox matrix as part of my pre-release process.
---------------------------------------------------------------
All of this said, you're welcome to use tox if you like, and if this invocation is what it takes to make tox work with pyenv Pythons, then it's worth documenting. (I'd be surprised if it's necessary, though -- I would expect pyenv to expose its various Python 3.x on PATH as the respective python3.# executables; and if it doesn't, that makes me glad I never tried to use it.)
But, in order to keep it as part of the PR, it would need to go in CONTRIBUTING.md, and would need to be documented more clearly with an explanatory writeup.
---------------------------------------------------------------
> Especially if this is the only thing holding up the PR merge.
No, it's unfortunately not the only thing preventing merge. Per my [other comment](#307 (comment)), both the code and the docs will need significant work before the PR is merge-ready. High-level, there is just too much of both code and docs; both will need trimming and revision. And, I'm still leaning against uptaking any instructions for setting up a Git textconv into the repo... I don't really want that maintenance burden.
—
Reply to this email directly, [view it on GitHub](#307 (comment)), or [unsubscribe](https://github.com/notifications/unsubscribe-auth/AVSZJ2JJU6XKWR22YB4RHFL2PLIIXAVCNFSM6AAAAABUNNRT3KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMNJSGY3DOOJQGI).
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
035cf6d
to
152e06a
Compare
closes #295
The rebase was challenging. Previous PR was automatically withdrawn