openSUSE Commits
Threads by month
- ----- 2025 -----
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
March 2023
- 2 participants
- 2681 discussions
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-uniseg for openSUSE:Factory checked in at 2023-03-01 16:14:23
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-uniseg (Old)
and /work/SRC/openSUSE:Factory/.python-uniseg.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-uniseg"
Wed Mar 1 16:14:23 2023 rev:7 rq:1068328 version:0.7.2
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-uniseg/python-uniseg.changes 2022-03-14 19:37:59.062192423 +0100
+++ /work/SRC/openSUSE:Factory/.python-uniseg.new.31432/python-uniseg.changes 2023-03-01 16:14:50.470844641 +0100
@@ -1,0 +2,7 @@
+Mon Feb 27 13:53:27 UTC 2023 - Martin Hauke <mardnh(a)gmx.de>
+
+- Update to version 0.7.2
+ * Improve performance of Unicode lookups.
+- Drop uniseg-dbpath
+
+-------------------------------------------------------------------
Old:
----
uniseg-0.7.1.post2.zip
New:
----
uniseg-0.7.2.zip
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-uniseg.spec ++++++
--- /var/tmp/diff_new_pack.Yifokh/_old 2023-03-01 16:14:50.978847268 +0100
+++ /var/tmp/diff_new_pack.Yifokh/_new 2023-03-01 16:14:50.986847309 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-uniseg
#
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -16,13 +16,12 @@
#
-%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-uniseg
-Version: 0.7.1.post2
+Version: 0.7.2
Release: 0
Summary: Python module for determining Unicode text segmentations
License: MIT
-URL: https://bitbucket.org/emptypage/uniseg-python
+URL: https://bitbucket.org/emptypage/uniseg-py
Source: https://files.pythonhosted.org/packages/source/u/uniseg/uniseg-%{version}.z…
BuildRequires: %{python_module setuptools}
BuildRequires: %{pythons}
@@ -30,8 +29,6 @@
BuildRequires: python-rpm-macros
BuildRequires: unzip
Requires: python
-Requires(post): update-alternatives
-Requires(postun):update-alternatives
BuildArch: noarch
%python_subpackages
@@ -47,22 +44,20 @@
%install
%python_install
-%python_clone -a %{buildroot}%{_bindir}/uniseg-dbpath
-%python_expand %fdupes %{buildroot}%{$python_sitelib}
+%python_expand rm -Rv %{buildroot}%{$python_sitelib}/uniseg/samples
+%python_expand rm -Rv %{buildroot}%{$python_sitelib}/uniseg/docs
+%python_expand %fdupes %{buildroot}%{$python_sitelib}/uniseg/__pycache__
%check
%pyunittest -v uniseg/*test.py
-%post
-%python_install_alternative uniseg-dbpath
-
-%postun
-%python_uninstall_alternative uniseg-dbpath
-
%files %{python_files}
%license LICENSE
-%doc README
-%python_alternative %{_bindir}/uniseg-dbpath
-%{python_sitelib}/*
+%doc README.rst
+%doc uniseg/docs/uniseg.ja.html
+%{python_sitelib}/uniseg-*
+%{python_sitelib}/uniseg/*.py
+%dir %{python_sitelib}/uniseg
+%pycache_only %{python_sitelib}/uniseg/__pycache__
%changelog
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-pyp for openSUSE:Factory checked in at 2023-03-01 16:14:24
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-pyp (Old)
and /work/SRC/openSUSE:Factory/.python-pyp.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-pyp"
Wed Mar 1 16:14:24 2023 rev:2 rq:1068349 version:1.1.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-pyp/python-pyp.changes 2021-09-10 23:41:51.366594168 +0200
+++ /work/SRC/openSUSE:Factory/.python-pyp.new.31432/python-pyp.changes 2023-03-01 16:14:51.154848178 +0100
@@ -1,0 +2,30 @@
+Wed Feb 22 06:20:21 UTC 2023 - Daniel Garcia <daniel.garcia(a)suse.com>
+
+- Use release from github, the new release was created there
+ (gh#hauntsaninja/pyp#33)
+
+-------------------------------------------------------------------
+Tue Feb 21 16:35:23 UTC 2023 - Daniel Garcia <daniel.garcia(a)suse.com>
+
+- Use release from pypi, the last release it not tagged in github, but
+ add a new source with the github repo to get the tests that are not
+ in the pypi release. (gh#hauntsaninja/pyp#33)
+- Update to 1.1.0:
+ * Fix AST construction on Python 3.11
+ * Constructed ASTs now have a more convincing end_lineno
+ * Test coverage for fallback unparsing, other test improvements
+ * Now packaged by flit
+- [v1.0.0]
+ * Configuration now allows the use of magic variables, effectively
+ allowing you to define your own magic variables. See README.md for
+ details
+ * Explicit printing in used config functions will now disable
+ automatic printing
+ * Config definitions can now use things defined from wildcard
+ imports. Automatic imports now work in config as well
+ * Removed s as a magic variable. If you miss it, you can redefine it
+ in your config using s = x
+ * Implement correct scoping semantics for comprehensions, including
+ with assignment expressions
+
+-------------------------------------------------------------------
Old:
----
pyp-0.3.4.tar.gz
New:
----
pyp-1.1.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-pyp.spec ++++++
--- /var/tmp/diff_new_pack.Eqaib4/_old 2023-03-01 16:14:51.622850598 +0100
+++ /var/tmp/diff_new_pack.Eqaib4/_new 2023-03-01 16:14:51.630850640 +0100
@@ -1,7 +1,7 @@
#
# spec file for package python-pyp
#
-# Copyright (c) 2021 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
# Copyright (c) 2020-2021 LISA GmbH, Bingen, Germany
#
# All modifications and additions to the file contributed by third parties
@@ -17,10 +17,9 @@
#
-%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python2 1
Name: python-pyp
-Version: 0.3.4
+Version: 1.1.0
Release: 0
Summary: Python at the shell
License: MIT
@@ -29,17 +28,19 @@
Source0: https://github.com/hauntsaninja/pyp/archive/v%{version}.tar.gz#/pyp-%{versi…
BuildRequires: %{python_module astunparse}
BuildRequires: %{python_module base}
-BuildRequires: %{python_module setuptools}
+BuildRequires: %{python_module flit-core}
+BuildRequires: %{python_module pip}
+BuildRequires: %{python_module wheel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
# testing requirements
BuildRequires: bc
-BuildRequires: jq
BuildRequires: %{python_module pytest}
+BuildRequires: jq
Requires: python-astunparse
BuildArch: noarch
Requires(post): update-alternatives
-Requires(postun): update-alternatives
+Requires(postun):update-alternatives
%python_subpackages
%description
@@ -48,14 +49,14 @@
See README.md or https://github.com/hauntsaninja/pyp for examples.
%prep
-%setup -q -n pyp-%{version}
+%autosetup -p1 -n pyp-%{version}
sed -i '/^#!\//, 1d' pyp.py
%build
-%python_build
+%pyproject_wheel
%install
-%python_install
+%pyproject_install
%python_clone -a %{buildroot}%{_bindir}/pyp
%python_expand %fdupes %{buildroot}%{$python_sitelib}
@@ -74,7 +75,9 @@
%files %{python_files}
%license LICENSE
%doc *.md
-%{python_sitelib}/
+%{python_sitelib}/pyp.py
+%{python_sitelib}/pypyp-%{version}*-info
+%pycache_only %{python_sitelib}/__pycache__
%python_alternative %{_bindir}/pyp
%changelog
++++++ pyp-0.3.4.tar.gz -> pyp-1.1.0.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/.github/workflows/tests.yml new/pyp-1.1.0/.github/workflows/tests.yml
--- old/pyp-0.3.4/.github/workflows/tests.yml 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/.github/workflows/tests.yml 2023-01-12 10:45:46.000000000 +0100
@@ -1,8 +1,6 @@
name: Tests
-on:
- push:
- pull_request:
+on: [push, pull_request, workflow_dispatch]
permissions:
contents: read
@@ -11,15 +9,15 @@
lint:
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-python@v2
+ - uses: actions/checkout@v3
+ - uses: actions/setup-python@v4
- run: pip install tox
- run: tox -e lint
mypy:
runs-on: ubuntu-latest
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-python@v2
+ - uses: actions/checkout@v3
+ - uses: actions/setup-python@v4
- run: pip install tox
- run: tox -e mypy
tests:
@@ -28,12 +26,14 @@
fail-fast: false
matrix:
include:
- - {python: '3.6', tox: py36}
+ - {python: '3.7', tox: py37}
- {python: '3.8', tox: py38}
- {python: '3.9', tox: py39}
+ - {python: '3.10', tox: py310}
+ - {python: '3.11', tox: py311}
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-python@v2
+ - uses: actions/checkout@v3
+ - uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python }}
- run: pip install tox
@@ -43,9 +43,8 @@
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- - uses: actions/checkout@v2
- - uses: actions/setup-python@v2
+ - uses: actions/checkout@v3
+ - uses: actions/setup-python@v4
- run: pip install tox coveralls
- run: tox -e coverage
- run: coveralls --service=github
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/CHANGELOG.md new/pyp-1.1.0/CHANGELOG.md
--- old/pyp-0.3.4/CHANGELOG.md 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/CHANGELOG.md 2023-01-12 10:45:46.000000000 +0100
@@ -1,5 +1,22 @@
# Changelog
+## [v1.1.0]
+
+- Fix AST construction on Python 3.11
+- Constructed ASTs now have a more convincing `end_lineno`
+- Test coverage for fallback unparsing, other test improvements
+- Now packaged by `flit`
+
+## [v1.0.0]
+
+- Configuration now allows the use of magic variables, effectively allowing you to define your own
+magic variables. See README.md for details
+- Explicit printing in used config functions will now disable automatic printing
+- Config definitions can now use things defined from wildcard imports. Automatic imports now work
+in config as well
+- Removed `s` as a magic variable. If you miss it, you can redefine it in your config using `s = x`
+- Implement correct scoping semantics for comprehensions, including with assignment expressions
+
## [v0.3.4]
- Reduce reconstructed traceback's reliance on CPython implementation details
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/CONTRIBUTING.md new/pyp-1.1.0/CONTRIBUTING.md
--- old/pyp-0.3.4/CONTRIBUTING.md 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/CONTRIBUTING.md 2023-01-12 10:45:46.000000000 +0100
@@ -16,9 +16,10 @@
## Making a release
- Update the changelog
+- Update the version in `CHANGELOG.md`
- Update the version in `__version__`
-- Update the version in `setup.py`
+- Update the version in `pyproject.toml`
- `rm -rf dist`
-- `python setup.py sdist bdist_wheel`
+- `python -m build .`
- `twine upload dist/*`
- Tag the release on Github
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/FAQ.md new/pyp-1.1.0/FAQ.md
--- old/pyp-0.3.4/FAQ.md 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/FAQ.md 2023-01-12 10:45:46.000000000 +0100
@@ -3,6 +3,7 @@
### Contents
- [I'm running into issues with newlines / complicated statements](#im-running-into-issues-with-newlines--complicated-statements)
+- [What's in your config?](#whats-in-your-config)
- [What are pyp's dependencies?](#what-are-pyps-dependencies)
- [Can I customise the shebang on the output of `--script`?](#can-i-customise-the-shebang-on-the-output-of---script)
- [The output of `--explain` is a little weirdly formatted](#the-output-of---explain-is-a-little-weirdly-formatted)
@@ -48,6 +49,21 @@
$ pyp --explain $'if int(x) >= 100:\n x += " is big"\n print(x)\nelse:\n print(x + " is small")'
```
+#### What's in your config?
+
+My config is pretty simple:
+```py
+import numpy as np
+
+n = int(x)
+j = json.loads(stdin)
+f = x.split()
+# like f, but returns None if index is of bounds
+ff = defaultdict(lambda: None, dict(enumerate(x.split())))
+
+d = defaultdict(list)
+```
+
#### What are pyp's dependencies?
If run on Python 3.9 or later, pyp has no dependencies.
@@ -80,12 +96,12 @@
processes start in parallel, so this is zero extra wall time if your piped input has any latency.
Here's a benchmark that should basically just be measuring the fixed costs of start up and AST
-transformation (run on my old, not powerful laptop):
+transformation (run on my laptop):
```
-$ hyperfine -w 10 -m 100 'pyp x'
+hyperfine -w 10 -m 100 'pyp x'
Benchmark #1: pyp x
- Time (mean �� ��): 81.5 ms �� 1.4 ms [User: 60.3 ms, System: 15.9 ms]
- Range (min ��� max): 78.6 ms ��� 84.8 ms 100 runs
+ Time (mean �� ��): 56.3 ms �� 1.0 ms [User: 41.2 ms, System: 11.4 ms]
+ Range (min ��� max): 53.9 ms ��� 60.3 ms 100 runs
```
One note here, as mentioned in the README, is that if you use wildcard imports (`from x import *`)
@@ -100,13 +116,13 @@
```
$ hyperfine -w 3 -m 10 "seq 1 999999 | pyp 'sum(map(int, stdin))'"
Benchmark #1: seq 1 999999 | pyp 'sum(map(int, stdin))'
- Time (mean �� ��): 490.9 ms �� 4.3 ms [User: 848.8 ms, System: 26.0 ms]
- Range (min ��� max): 487.4 ms ��� 502.3 ms 10 runs
+ Time (mean �� ��): 258.2 ms �� 5.6 ms [User: 422.3 ms, System: 17.0 ms]
+ Range (min ��� max): 252.1 ms ��� 270.7 ms 11 runs
$ hyperfine -w 3 -m 10 'seq 1 999999 | awk "{s += $0} END {print s}"'
Benchmark #1: seq 1 999999 | awk "{s += $0} END {print s}"
- Time (mean �� ��): 754.6 ms �� 4.8 ms [User: 1.152 s, System: 0.013 s]
- Range (min ��� max): 748.9 ms ��� 763.2 ms 10 runs
+ Time (mean �� ��): 405.3 ms �� 3.4 ms [User: 599.6 ms, System: 5.5 ms]
+ Range (min ��� max): 399.4 ms ��� 410.9 ms 10 runs
```
More seriously, random micro benchmark aside, pyp should be fast enough that you shouldn't worry
@@ -119,8 +135,8 @@
```
$ hyperfine -w 3 -m 10 "seq 1 999999 | pyp 'sum(map(int, lines))'"
Benchmark #1: seq 1 999999 | pyp 'sum(map(int, lines))'
- Time (mean �� ��): 848.5 ms �� 146.2 ms [User: 1.157 s, System: 0.087 s]
- Range (min ��� max): 748.4 ms ��� 1239.1 ms 10 runs
+ Time (mean �� ��): 378.9 ms �� 3.2 ms [User: 530.2 ms, System: 38.5 ms]
+ Range (min ��� max): 375.4 ms ��� 384.6 ms 10 runs
```
#### Can I use pyp with PyPy?
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/README.md new/pyp-1.1.0/README.md
--- old/pyp-0.3.4/README.md 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/README.md 2023-01-12 10:45:46.000000000 +0100
@@ -24,7 +24,7 @@
for many common shell utilities. For a cheatsheet / tldr, run `pyp --help`.
#### pyp can easily be used to apply Python code to each line in the input.
-Just use one of the magic variables `x`, `l`, `s` or `line` to refer to the current line.
+Just use one of the magic variables `x`, `l` or `line` to refer to the current line.
```sh
# pyp like cut
@@ -146,7 +146,7 @@
class PotentiallyUsefulClass: ...
```
-When attempting to define undefined names, pyp will statically* analyse this file as a source of
+When attempting to define undefined names, pyp will statically\* analyse this file as a source of
possible definitions. This means that if you don't use `tf`, we won't import `tensorflow`! And of
course, `--explain` will show you exactly what gets run (and hence what doesn't!):
@@ -174,6 +174,28 @@
names, though we skip this in the happy path. If this matters to you, definitely don't
`from tensorflow import *` in your config! </sub>
+#### pyp lets you configure your own magic!
+
+If definitions in your config file depend on magic variables, pyp will substitute them in the
+way that makes sense. For example, put the following in your config...
+```py
+n = int(x)
+f = x.split()
+j = json.load(stdin)
+
+import pandas as pd
+csv = pd.read_csv(stdin)
+```
+
+...to make pyp easier than ever for your custom use cases:
+```sh
+ps | pyp 'f[3]'
+
+cat commits.json | pyp 'j[0]["commit"]["author"]'
+
+< cities.csv pyp 'csv.to_string()'
+```
+
#### I have questions!
There's additional documentation and examples at [FAQ](https://github.com/hauntsaninja/pyp/blob/master/FAQ.md).
@@ -215,6 +237,7 @@
- Some of them have specialised support for things like JSON input or running shell commands.
- Some of them expose the input in interesting ways with custom line / file / stream objects.
- Some of them have more advanced options for error handling.
+- None of them have powerful configuration like pyp.
- None of them have anything like `--explain`.
For whatever it's worth, I've listed these projects in approximate order of my personal preference.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/pyp.py new/pyp-1.1.0/pyp.py
--- old/pyp-0.3.4/pyp.py 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/pyp.py 2023-01-12 10:45:46.000000000 +0100
@@ -12,7 +12,7 @@
from typing import Any, Dict, Iterator, List, Optional, Set, Tuple, cast
__all__ = ["pypprint"]
-__version__ = "0.3.4"
+__version__ = "1.1.0"
def pypprint(*args, **kwargs): # type: ignore
@@ -46,12 +46,14 @@
An undefined name is any name that is loaded before it is defined (in any scope).
Notes: a) we ignore deletes, b) used builtins will appear in undefined names, c) this logic
- doesn't fully support comprehension / nonlocal / global / late-binding scopes.
+ doesn't fully support nonlocal / global / late-binding scopes.
"""
def __init__(self, *trees: ast.AST) -> None:
self._scopes: List[Set[str]] = [set()]
+ self._comprehension_scopes: List[int] = []
+
self.undefined: Set[str] = set()
self.wildcard_imports: List[str] = []
for tree in trees:
@@ -72,8 +74,8 @@
def generic_visit(self, node: ast.AST) -> None:
def order(f_v: Tuple[str, Any]) -> int:
- # This ordering fixes comprehensions, loops, assignments
- return {"generators": -2, "iter": -2, "value": -1}.get(f_v[0], 0)
+ # This ordering fixes comprehensions, dict comps, loops, assignments
+ return {"generators": -3, "iter": -3, "key": -2, "value": -1}.get(f_v[0], 0)
# Adapted from ast.NodeVisitor.generic_visit, but re-orders traversal a little
for _, value in sorted(ast.iter_fields(node), key=order):
@@ -102,6 +104,18 @@
self.undefined.add(node.target.id)
self.generic_visit(node)
+ def visit_NamedExpr(self, node: Any) -> None:
+ self.visit(node.value)
+ # PEP 572 has weird scoping rules
+ assert isinstance(node.target, ast.Name)
+ assert isinstance(node.target.ctx, ast.Store)
+ scope_index = len(self._scopes) - 1
+ comp_index = len(self._comprehension_scopes) - 1
+ while comp_index >= 0 and scope_index == self._comprehension_scopes[comp_index]:
+ scope_index -= 1
+ comp_index -= 1
+ self._scopes[scope_index].add(node.target.id)
+
def visit_alias(self, node: ast.alias) -> None:
if node.name != "*":
self._scopes[-1].add(node.asname if node.asname is not None else node.name)
@@ -159,6 +173,18 @@
self.flexible_visit(node.body)
self._scopes[-1].remove(node.name)
+ def visit_comprehension_helper(self, node: Any) -> None:
+ self._comprehension_scopes.append(len(self._scopes))
+ self._scopes.append(set())
+ self.generic_visit(node)
+ self._scopes.pop()
+ self._comprehension_scopes.pop()
+
+ visit_ListComp = visit_comprehension_helper
+ visit_SetComp = visit_comprehension_helper
+ visit_GeneratorExp = visit_comprehension_helper
+ visit_DictComp = visit_comprehension_helper
+
def dfs_walk(node: ast.AST) -> Iterator[ast.AST]:
"""Helper to iterate over an AST depth-first."""
@@ -169,6 +195,21 @@
yield node
+MAGIC_VARS = {
+ "index": {"i", "idx", "index"},
+ "loop": {"line", "x", "l"},
+ "input": {"lines", "stdin"},
+}
+
+
+def is_magic_var(name: str) -> bool:
+ return any(name in vars for vars in MAGIC_VARS.values())
+
+
+class PypError(Exception):
+ pass
+
+
def get_config_contents() -> str:
"""Returns the empty string if no config file is specified."""
config_file = os.environ.get("PYP_CONFIG_PATH")
@@ -181,10 +222,6 @@
raise PypError(f"Config file not found at PYP_CONFIG_PATH={config_file}") from e
-class PypError(Exception):
- pass
-
-
class PypConfig:
"""PypConfig is responsible for handling user configuration.
@@ -210,6 +247,7 @@
self.parts: List[ast.stmt] = config_ast.body
# Maps from a name to index of config part that defines it
self.name_to_def: Dict[str, int] = {}
+ self.def_to_names: Dict[int, List[str]] = defaultdict(list)
# Maps from index of config part to undefined names it needs
self.requires: Dict[int, Set[str]] = defaultdict(set)
# Modules from which automatic imports work without qualification, ordered by AST encounter
@@ -218,7 +256,7 @@
self.shebang: str = "#!/usr/bin/env python3"
if config_contents.startswith("#!"):
self.shebang = "\n".join(
- itertools.takewhile(lambda l: l.startswith("#"), config_contents.splitlines())
+ itertools.takewhile(lambda line: line.startswith("#"), config_contents.splitlines())
)
top_level: Tuple[Any, ...] = (ast.FunctionDef, ast.AsyncFunctionDef, ast.ClassDef)
@@ -236,7 +274,10 @@
for name in f.top_level_defined:
if self.name_to_def.get(name, index) != index:
raise PypError(f"Config has multiple definitions of {repr(name)}")
+ if is_magic_var(name):
+ raise PypError(f"Config cannot redefine built-in magic variable {repr(name)}")
self.name_to_def[name] = index
+ self.def_to_names[index].append(name)
self.requires[index] = f.undefined
self.wildcard_imports.extend(f.wildcard_imports)
@@ -276,6 +317,10 @@
self.defined: Set[str] = f.top_level_defined
self.undefined: Set[str] = f.undefined
self.wildcard_imports: List[str] = f.wildcard_imports
+ # We'll always use sys in ``build_input``, so add it to undefined.
+ # This lets config define it or lets us automatically import it later
+ # (If before defines it, we'll just let it override the import...)
+ self.undefined.add("sys")
self.define_pypprint = define_pypprint
self.config = config
@@ -283,6 +328,51 @@
# The print statement ``build_output`` will add, if it determines it needs to.
self.implicit_print: Optional[ast.Call] = None
+ def build_missing_config(self) -> None:
+ """Modifies the AST to define undefined names defined in config."""
+ config_definitions: Set[str] = set()
+ attempt_to_define = set(self.undefined)
+ while attempt_to_define:
+ can_define = attempt_to_define & set(self.config.name_to_def)
+ # The things we can define might in turn require some definitions, so update the things
+ # we need to attempt to define and loop
+ attempt_to_define = set()
+ for name in can_define:
+ config_definitions.update(self.config.def_to_names[self.config.name_to_def[name]])
+ attempt_to_define.update(self.config.requires[self.config.name_to_def[name]])
+ # We don't need to attempt to define things we've already decided we need to define
+ attempt_to_define -= config_definitions
+
+ config_indices = {self.config.name_to_def[name] for name in config_definitions}
+
+ # Run basically the same thing in reverse to see which dependencies stem from magic vars
+ before_config_indices = set(config_indices)
+ derived_magic_indices = {
+ i for i in config_indices if any(map(is_magic_var, self.config.requires[i]))
+ }
+ derived_magic_names = set()
+
+ while derived_magic_indices:
+ before_config_indices -= derived_magic_indices
+ derived_magic_names |= {
+ name for i in derived_magic_indices for name in self.config.def_to_names[i]
+ }
+ derived_magic_indices = {
+ i for i in before_config_indices if self.config.requires[i] & derived_magic_names
+ }
+ magic_config_indices = config_indices - before_config_indices
+
+ before_config_defs = [self.config.parts[i] for i in sorted(before_config_indices)]
+ magic_config_defs = [self.config.parts[i] for i in sorted(magic_config_indices)]
+
+ self.before_tree.body = before_config_defs + self.before_tree.body
+ self.tree.body = magic_config_defs + self.tree.body
+
+ for i in config_indices:
+ self.undefined.update(self.config.requires[i])
+ self.defined |= config_definitions
+ self.undefined -= config_definitions
+
def define(self, name: str) -> None:
"""Defines a name."""
self.defined.add(name)
@@ -322,7 +412,7 @@
)
):
# ...then recursively look for a standalone expression
- return inner(body[-1].body, use_pypprint) # type: ignore
+ return inner(body[-1].body, use_pypprint)
return False
if isinstance(body[-1].value, ast.Name):
@@ -371,11 +461,6 @@
How we do this depends on which magic variables are used.
"""
- MAGIC_VARS = {
- "index": {"i", "idx", "index"},
- "loop": {"line", "x", "l", "s"},
- "input": {"lines", "stdin"},
- }
possible_vars = {typ: names & self.undefined for typ, names in MAGIC_VARS.items()}
if (possible_vars["loop"] or possible_vars["index"]) and possible_vars["input"]:
@@ -391,9 +476,6 @@
names_str = ", ".join(names)
raise PypError(f"Multiple candidates for {typ} variable: {names_str}")
- # We'll use sys here no matter what; add it to undefined so we import it later
- self.undefined.add("sys")
-
if possible_vars["loop"] or possible_vars["index"]:
# We'll loop over stdin and define loop / index variables
idx_var = possible_vars["index"].pop() if possible_vars["index"] else None
@@ -430,32 +512,12 @@
else:
no_pipe_assertion = ast.parse(
"assert sys.stdin.isatty() or not sys.stdin.read(), "
- '''"The command doesn't process input, but input is present"'''
+ """"The command doesn't process input, but input is present. """
+ '''Maybe you meant to use a magic variable like `stdin` or `x`?"'''
)
self.tree.body = no_pipe_assertion.body + self.tree.body
self.use_pypprint_for_implicit_print()
- def build_missing_config(self) -> None:
- """Modifies the AST to define undefined names defined in config."""
- config_definitions: Set[str] = set()
- attempt_to_define = set(self.undefined)
- while attempt_to_define:
- can_define = attempt_to_define & set(self.config.name_to_def)
- config_definitions.update(can_define)
- # The things we can define might in turn require some definitions, so update the things
- # we need to attempt to define and loop
- attempt_to_define = set()
- for name in can_define:
- attempt_to_define.update(self.config.requires[self.config.name_to_def[name]])
- # We don't need to attempt to define things we've already decided we need to define
- attempt_to_define -= config_definitions
-
- config_indices = sorted({self.config.name_to_def[name] for name in config_definitions})
- self.before_tree.body = [
- self.config.parts[i] for i in config_indices
- ] + self.before_tree.body
- self.undefined -= config_definitions
-
def build_missing_imports(self) -> None:
"""Modifies the AST to import undefined names."""
self.undefined -= set(dir(__import__("builtins")))
@@ -506,9 +568,9 @@
def build(self) -> ast.Module:
"""Returns a transformed AST."""
+ self.build_missing_config()
self.build_output()
self.build_input()
- self.build_missing_config()
self.build_missing_imports()
ret = ast.parse("")
@@ -519,6 +581,8 @@
if isinstance(node, ast.stmt):
i += 1
node.lineno = i
+ if sys.version_info >= (3, 8):
+ node.end_lineno = i
return ast.fix_missing_locations(ret)
@@ -533,8 +597,14 @@
return cast(str, astunparse.unparse(tree))
except ImportError:
pass
- if short_fallback:
- return f"# {ast.dump(tree)} # --explain has instructions to make this readable"
+ return (
+ fallback_unparse(tree)
+ if not short_fallback
+ else f"# {ast.dump(tree)} # --explain has instructions to make this readable"
+ )
+
+
+def fallback_unparse(tree: ast.AST) -> str:
return f"""
from ast import *
tree = fix_missing_locations({ast.dump(tree)})
@@ -558,6 +628,8 @@
try:
exec(compile(tree, filename="<pyp>", mode="exec"), {})
except Exception as e:
+ # On error, reconstruct a traceback into the generated code
+ # Also add some diagnostics for ModuleNotFoundError and NameError
try:
line_to_node: Dict[int, ast.AST] = {}
for node in dfs_walk(tree):
@@ -577,6 +649,8 @@
)
for fs in tb_except.stack:
if fs.filename == "<pyp>":
+ if fs.lineno is None:
+ raise AssertionError("When would this happen?")
fs._line = code_for_line(fs.lineno) # type: ignore[attr-defined]
fs.lineno = "PYP_REDACTED" # type: ignore[assignment]
@@ -617,7 +691,7 @@
"Easily run Python at the shell!\n\n"
"For help and examples, see https://github.com/hauntsaninja/pyp\n\n"
"Cheatsheet:\n"
- "- Use `line`, `x`, `l`, or `s` for a line in the input. Use `i`, `idx` or `index` "
+ "- Use `x`, `l` or `line` for a line in the input. Use `i`, `idx` or `index` "
"for the index\n"
"- Use `lines` to get a list of rstripped lines\n"
"- Use `stdin` to get sys.stdin\n"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/pyproject.toml new/pyp-1.1.0/pyproject.toml
--- old/pyp-0.3.4/pyproject.toml 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/pyproject.toml 2023-01-12 10:45:46.000000000 +0100
@@ -1,2 +1,37 @@
+[project]
+name = "pypyp"
+version = "1.1.0"
+authors = [{name = "Shantanu Jain"}, {email = "hauntsaninja(a)gmail.com"}]
+description = "Easily run Python at the shell! Magical, but never mysterious."
+readme = "README.md"
+license = {file = "LICENSE"}
+classifiers = [
+ "Environment :: Console",
+ "Intended Audience :: Developers",
+ "License :: OSI Approved :: MIT License",
+ "Operating System :: OS Independent",
+ "Programming Language :: Python :: 3",
+ "Topic :: Software Development",
+ "Topic :: Utilities",
+]
+requires-python = ">=3.6"
+dependencies = ["astunparse; python_version<'3.9'"]
+
+[project.scripts]
+pyp = "pyp:main"
+
+[project.urls]
+homepage = "https://github.com/hauntsaninja/pyp"
+repository = "https://github.com/hauntsaninja/pyp"
+changelog = "https://github.com/hauntsaninja/pyp/blob/master/CHANGELOG.md"
+
+[tool.flit.module]
+name = "pyp"
+
+[build-system]
+requires = ["flit_core>=3.4"]
+build-backend = "flit_core.buildapi"
+
[tool.black]
line-length = 100
+skip-magic-trailing-comma = true
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/setup.py new/pyp-1.1.0/setup.py
--- old/pyp-0.3.4/setup.py 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/setup.py 1970-01-01 01:00:00.000000000 +0100
@@ -1,28 +0,0 @@
-from setuptools import setup
-
-with open("README.md", "r") as f:
- long_description = f.read()
-
-setup(
- name="pypyp",
- version="0.3.4",
- author="Shantanu Jain",
- author_email="hauntsaninja(a)gmail.com",
- description="Easily run Python at the shell! Magical, but never mysterious.",
- long_description=long_description,
- long_description_content_type="text/markdown",
- url="https://github.com/hauntsaninja/pyp",
- classifiers=[
- "Environment :: Console",
- "Intended Audience :: Developers",
- "License :: OSI Approved :: MIT License",
- "Operating System :: OS Independent",
- "Programming Language :: Python :: 3",
- "Topic :: Software Development",
- "Topic :: Utilities",
- ],
- py_modules=["pyp"],
- entry_points={"console_scripts": ["pyp=pyp:main"]},
- install_requires=["astunparse; python_version<'3.9'"],
- python_requires=">=3.6",
-)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/tests/test_find_names.py new/pyp-1.1.0/tests/test_find_names.py
--- old/pyp-0.3.4/tests/test_find_names.py 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/tests/test_find_names.py 2023-01-12 10:45:46.000000000 +0100
@@ -125,10 +125,21 @@
check_find_names("f((f := lambda x: x))", {"f"}, {"f"})
check_find_names("f((f := lambda x: (x, y)))", {"f"}, {"f", "y"})
check_find_names("if (x := 1): print(x)", {"x"}, {"print"})
- check_find_names("(y for x in xx if (y := x) == 'foo')", {"x", "y"}, {"xx"})
check_find_names("x: (x := 1) = 2", {"x"}, set())
check_find_names("f'{(x := 1)} {x}'", {"x"}, set())
check_find_names("class A((A := object)): ...", {"A"}, {"object"})
+
+ check_find_names("[(y := x) for x in xx]", {"y"}, {"xx"})
+ check_find_names("(y for x in xx if (y := x) == 'foo')", {"y"}, {"xx"})
+ check_find_names("[[(y := z) for z in x] for x in xx]", {"y"}, {"xx"})
+ check_find_names("[[[(y := z) for z in x] for x in xx] for x in xx]", {"y"}, {"xx"})
+ check_find_names("(lambda: [[(y := z) for z in x] for x in xx])()", set(), {"xx"})
+ check_find_names("[lambda: [[(y := z) for z in x] for x in xx] for x in xx]", set(), {"xx"})
+ check_find_names("[(lambda a=(x := 5): a) for _ in range(5)]", {"x"}, {"range"})
+
+ check_find_names("{(x := y): (y := 1) for _ in range(5)}", {"x", "y"}, {"y", "range"})
+ check_find_names("{(x := 1): (y := x) for _ in range(5)}", {"x", "y"}, {"range"})
+
if sys.version_info >= (3, 9):
check_find_names(
"d1 = lambda i: i\n@(d2 := d1)\n@(d3 := d2)\ndef f(): ...",
@@ -144,14 +155,14 @@
def test_comprehensions():
- check_find_names("(x for x in y)", {"x"}, {"y"})
- check_find_names("(x for x in x)", {"x"}, {"x"})
- check_find_names("(x for xx in xxx for x in xx)", {"x", "xx"}, {"xxx"})
- check_find_names("(x for x in xx for xx in xxx)", {"x", "xx"}, {"xx", "xxx"})
- check_find_names("(x for x in xx if x > 0)", {"x"}, {"xx"})
- check_find_names("[x for x in xx if x > 0]", {"x"}, {"xx"})
- check_find_names("{x for x in xx if x > 0}", {"x"}, {"xx"})
- check_find_names("{x: x for x in xx if x > 0}", {"x"}, {"xx"})
+ check_find_names("(x for x in y)", set(), {"y"})
+ check_find_names("(x for x in x)", set(), {"x"})
+ check_find_names("(x for xx in xxx for x in xx)", set(), {"xxx"})
+ check_find_names("(x for x in xx for xx in xxx)", set(), {"xx", "xxx"})
+ check_find_names("(x for x in xx if x > 0)", set(), {"xx"})
+ check_find_names("[x for x in xx if x > 0]", set(), {"xx"})
+ check_find_names("{x for x in xx if x > 0}", set(), {"xx"})
+ check_find_names("{x: x for x in xx if x > 0}", set(), {"xx"})
def test_args():
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/tests/test_pyp.py new/pyp-1.1.0/tests/test_pyp.py
--- old/pyp-0.3.4/tests/test_pyp.py 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/tests/test_pyp.py 2023-01-12 10:45:46.000000000 +0100
@@ -145,7 +145,7 @@
run_pyp("pyp 'print(x); print(len(lines))'")
with pytest.raises(pyp.PypError, match="Multiple candidates for loop"):
- run_pyp("pyp 'print(x); print(s)'")
+ run_pyp("pyp 'print(x); print(l)'")
with pytest.raises(pyp.PypError, match="Multiple candidates for input"):
run_pyp("pyp 'stdin; lines'")
@@ -198,15 +198,21 @@
# Check the entire output, end to end
pyp_error = run_cmd("pyp 'def f(): 1/0' 'f()'", check=False)
- message = lambda x, y: ( # noqa
- "error: Code raised the following exception, consider using --explain to investigate:\n\n"
- "Possible reconstructed traceback (most recent call last):\n"
- ' File "<pyp>", in <module>\n'
- " output = f()\n"
- ' File "<pyp>", in f\n'
- f" {x}1 / 0{y}\n"
- "ZeroDivisionError: division by zero\n"
+ message = lambda po, pc: ( # noqa
+ (
+ "error: Code raised the following exception, "
+ "consider using --explain to investigate:\n\n"
+ "Possible reconstructed traceback (most recent call last):\n"
+ ' File "<pyp>", in <module>\n'
+ " output = f()\n"
+ )
+ + (" ^^^^^^^^^^^\n" if sys.version_info >= (3, 11) else "")
+ + (' File "<pyp>", in f\n' f" {po}1 / 0{pc}\n")
+ + (" \n" if sys.version_info >= (3, 11) else "")
+ + ("ZeroDivisionError: division by zero\n")
)
+ print(repr(pyp_error))
+ print(repr(message("", "")))
assert pyp_error == message("(", ")") or pyp_error == message("", "")
# Test tracebacks involving statements with nested child statements
@@ -219,7 +225,9 @@
"pyp --explain -b 'd = defaultdict(list)' 'user, pid, *_ = x.split()' "
"""'d[user].append(pid)' -a 'del d["root"]' -a d"""
)
- script = r"""
+ po = "" if sys.version_info >= (3, 11) else "("
+ pc = "" if sys.version_info >= (3, 11) else ")"
+ script = rf"""
#!/usr/bin/env python3
from collections import defaultdict
import sys
@@ -227,7 +235,7 @@
d = defaultdict(list)
for x in sys.stdin:
x = x.rstrip('\n')
- (user, pid, *_) = x.split()
+ {po}user, pid, *_{pc} = x.split()
d[user].append(pid)
del d['root']
if d is not None:
@@ -277,7 +285,7 @@
#!/usr/bin/env python3
from shlex import split
import sys
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
from shlex import *
split
""" # noqa
@@ -287,7 +295,7 @@
#!/usr/bin/env python3
from shlex import split
import sys
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
from os.path import *
from shlex import *
split
@@ -298,6 +306,16 @@
)
+def test_fallback_unparse():
+ original_code = """
+x = 2 + 3
+x = x * x
+print((lambda: x)())
+"""
+ code = pyp.fallback_unparse(ast.parse(original_code))
+ assert subprocess.check_output([sys.executable, "-c", code]).decode().strip() == "25"
+
+
# ====================
# Config tests
# ====================
@@ -329,7 +347,7 @@
import sys
import numpy as np
from scipy.linalg import eigvals
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
eigvals(np.array([[0.0, -1.0], [1.0, 0.0]]))
""" # noqa
compare_scripts(
@@ -363,6 +381,98 @@
"""
compare_scripts(run_pyp(["--explain", "stdin; smallarray(); pass"]), script4)
+ # test using wildcard imports in config
+ config_mock.return_value = """
+from typing import *
+any = Any
+ """
+ script5 = """
+#!/usr/bin/env python3
+from typing import Any
+import sys
+any = Any
+stdin = sys.stdin
+stdin
+any
+"""
+ compare_scripts(run_pyp(["--explain", "stdin; any; pass"]), script5)
+
+
+@patch("pyp.get_config_contents")
+def test_config_magic_vars(config_mock):
+ config_mock.return_value = "n = int(x)\nj = json.loads(stdin)\ndef upfront(): pass"
+
+ script1 = """
+#!/usr/bin/env python3
+import json
+import sys
+from pyp import pypprint
+stdin = sys.stdin
+j = json.loads(stdin)
+output = j[0]
+if output is not None:
+ pypprint(output)
+"""
+ compare_scripts(run_pyp(["--explain", "j[0]"]), script1)
+
+ script2 = r"""
+#!/usr/bin/env python3
+import sys
+for x in sys.stdin:
+ x = x.rstrip('\n')
+ n = int(x)
+ if n is not None:
+ print(n)
+"""
+ compare_scripts(run_pyp(["--explain", "n"]), script2)
+
+ config_mock.return_value = """
+f = lambda x: x
+n = int(x)
+o = f(n) + 1
+p = f(o) + 3
+q = f(p) + 5
+"""
+ assert run_pyp("p", input="0\n7") == "4\n11\n"
+ assert run_pyp("q", input="0\n7") == "9\n16\n"
+
+ script3 = r"""
+#!/usr/bin/env python3
+import sys
+f = lambda x: x
+for x in sys.stdin:
+ x = x.rstrip('\n')
+ n = int(x)
+ o = f(n) + 1
+ p = f(o) + 3
+ q = f(p) + 5
+ if q is not None:
+ print(q)
+"""
+ compare_scripts(run_pyp(["--explain", "q"]), script3)
+
+ config_mock.return_value = """
+ilines = (z.rstrip() for z in stdin)
+class Indexable:
+ ...
+idxgen = Indexable(ilines)
+"""
+ script4 = r"""
+#!/usr/bin/env python3
+import sys
+from pyp import pypprint
+
+class Indexable:
+ ...
+stdin = sys.stdin
+ilines = (z.rstrip() for z in stdin)
+idxgen = Indexable(ilines)
+output = idxgen[1]
+if output is not None:
+ pypprint(output)
+"""
+ compare_scripts(run_pyp(["--explain", "idxgen[1]"]), script4)
+
@patch("pyp.get_config_contents")
def test_config_invalid(config_mock):
@@ -388,6 +498,19 @@
run_pyp("missing")
assert isinstance(e.value.__cause__, ImportError)
+ config_mock.return_value = "x = 8"
+ with pytest.raises(pyp.PypError, match=r"Config.*cannot redefine built-in.*'x'"):
+ run_pyp("x")
+
+ config_mock.return_value = "stdin = 5"
+ with pytest.raises(pyp.PypError, match=r"Config.*cannot redefine built-in.*'stdin'"):
+ run_pyp("type(stdin).__name__")
+
+ # See test_config_scope for more
+ config_mock.return_value = "def f(x): stdin = 5"
+ run_pyp("x")
+ run_pyp("stdin")
+
@patch("pyp.get_config_contents")
def test_config_shebang(config_mock):
@@ -412,11 +535,39 @@
@patch("pyp.get_config_contents")
+def test_config_automatic_import(config_mock):
+ config_mock.return_value = "j = json"
+ script1 = """
+#!/usr/bin/env python3
+import json
+import sys
+j = json
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
+j
+""" # noqa
+ compare_scripts(run_pyp(["--explain", "j; pass"]), script1)
+
+ config_mock.return_value = "from typing import *\nL = List"
+ script2 = """
+#!/usr/bin/env python3
+from typing import List
+import sys
+L = List
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
+L
+""" # noqa
+ compare_scripts(run_pyp(["--explain", "L; pass"]), script2)
+
+
+@patch("pyp.get_config_contents")
def test_config_scope(config_mock):
config_mock.return_value = """
-def f(x): contextlib = 5
-class A:
- def asyncio(self): ...
+def f(x, stdin, asyncio):
+ contextlib = 5
+ import asyncio
+class A(asyncio):
+ contextlib = 55
+ def asyncio(self, asyncio): ...
"""
script = """
#!/usr/bin/env python3
@@ -437,11 +588,10 @@
config_mock.return_value = "range = 5"
assert run_pyp("print(range)") == "5\n"
- # shadowing a magic variable
- config_mock.return_value = "stdin = 5"
- assert run_pyp("type(stdin).__name__") == "StringIO\n"
- config_mock.return_value = "x = 8"
- assert run_pyp("x") == ""
+ # shadowing print
+ config_mock.return_value = "print = lambda p: p"
+ assert run_pyp("x", input="9") == "9\n"
+ assert run_pyp("print(x)", input="9") == ""
# shadowing a wildcard import
config_mock.return_value = "from typing import *\nList = 5"
@@ -457,6 +607,12 @@
@patch("pyp.get_config_contents")
+def test_config_automatic_print(config_mock):
+ config_mock.return_value = "def tnirp(p): print(''.join(reversed(p)))"
+ assert run_pyp("tnirp(x)", input="tnirp") == "print\n"
+
+
+@patch("pyp.get_config_contents")
def test_config_recursive(config_mock):
config_mock.return_value = "def f(x): return g(x)\ndef g(x): return f(x)"
script = """
@@ -490,7 +646,7 @@
import ast
import sys
{if_block}
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
unparse(ast.parse('x'))
""" # noqa
compare_scripts(run_pyp(["--explain", "unparse(ast.parse('x')); pass"]), script1)
@@ -508,11 +664,14 @@
import sys
import ast
{except_block}
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
unparse(ast.parse('x'))
""" # noqa
compare_scripts(run_pyp(["--explain", "unparse(ast.parse('x')); pass"]), script2)
+ config_mock.return_value = "foo = False\nif foo: y = 5\nelse: y = 10"
+ assert run_pyp("y") == "10\n"
+
@pytest.mark.xfail(reason="We don't currently support this")
@patch("pyp.get_config_contents")
@@ -534,7 +693,7 @@
import sys
import ast
{except_block}
-assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present"
+assert sys.stdin.isatty() or not sys.stdin.read(), "The command doesn't process input, but input is present. Maybe you meant to use a magic variable like `stdin` or `x`?"
unparse(ast.parse('x'))
""" # noqa
compare_scripts(run_pyp(["--explain", "unparse(ast.parse('x')); pass"]), script3)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/pyp-0.3.4/tox.ini new/pyp-1.1.0/tox.ini
--- old/pyp-0.3.4/tox.ini 2021-09-09 03:44:01.000000000 +0200
+++ new/pyp-1.1.0/tox.ini 2023-01-12 10:45:46.000000000 +0100
@@ -1,12 +1,12 @@
[tox]
skipsdist = True
-envlist = py36, py39, lint, mypy
+envlist = py39, py311, lint, mypy
[testenv]
deps = pytest
commands =
pip install -e .
- pytest
+ pytest {posargs}
[testenv:lint]
deps =
@@ -20,12 +20,15 @@
isort --diff --check --quiet .
[testenv:mypy]
-deps = mypy
-commands = mypy --strict -m pyp
+deps = mypy>=0.991
+commands =
+ mypy --strict -m pyp --python-version 3.6
+ mypy --strict -m pyp --python-version 3.11
[coverage:report]
exclude_lines =
- def unparse
+ raise AssertionError
+ def unparse\(
if __name__ == "__main__":
[testenv:coverage]
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package java-11-openj9 for openSUSE:Factory checked in at 2023-03-01 16:14:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/java-11-openj9 (Old)
and /work/SRC/openSUSE:Factory/.java-11-openj9.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "java-11-openj9"
Wed Mar 1 16:14:21 2023 rev:15 rq:1068375 version:11.0.17.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/java-11-openj9/java-11-openj9.changes 2023-02-25 19:55:19.955348257 +0100
+++ /work/SRC/openSUSE:Factory/.java-11-openj9.new.31432/java-11-openj9.changes 2023-03-01 16:14:48.646835209 +0100
@@ -5 +5 @@
- working and creates another problems (bsc#1205916). It can
+ working and creates another problems (bsc#1206549). It can
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package vale for openSUSE:Factory checked in at 2023-03-01 16:14:21
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/vale (Old)
and /work/SRC/openSUSE:Factory/.vale.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "vale"
Wed Mar 1 16:14:21 2023 rev:11 rq:1068326 version:2.23.3
Changes:
--------
--- /work/SRC/openSUSE:Factory/vale/vale.changes 2023-02-12 19:14:27.641091931 +0100
+++ /work/SRC/openSUSE:Factory/.vale.new.31432/vale.changes 2023-03-01 16:14:47.386828692 +0100
@@ -1,0 +2,35 @@
+Tue Feb 28 19:49:15 UTC 2023 - jkowalczyk(a)suse.com
+
+- Update to version 2.23.3:
+ * chore: fix naming again
+
+-------------------------------------------------------------------
+Tue Feb 28 19:29:31 UTC 2023 - jkowalczyk(a)suse.com
+
+- Update to version 2.23.2:
+ * fix: asset naming scheme
+
+-------------------------------------------------------------------
+Tue Feb 28 19:29:05 UTC 2023 - jkowalczyk(a)suse.com
+
+- Update to version 2.23.1:
+ * chore: remove `id`
+ * chore: remove `--clean`
+ * chore: fix `name_template`
+ * chore: remove `archives.replacements`
+ * chore: fix GoReleaser
+ * chore: clean up workflows
+ * fix: CLI test isn't deterministic
+ * fix: include `.vale.ini` in action tests
+ * chore: bring back `chocolateys`
+ * test: start action cases
+ * refactor: remove old TODO
+ * refactor: remove `pkg`
+ * fix: handle trailing commas in listing block
+ * Add PowerShell as a supported code language (#579)
+ * feat: support Typescript, TSX and JSX files (#564)
+ * fix: use `determinePath` in `Transform`
+ * fix: ignore empty tokens
+ * fix: trim leading newlines from sentences
+
+-------------------------------------------------------------------
Old:
----
vale-2.23.0.tar.gz
New:
----
vale-2.23.3.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ vale.spec ++++++
--- /var/tmp/diff_new_pack.mkfHlT/_old 2023-03-01 16:14:48.362833740 +0100
+++ /var/tmp/diff_new_pack.mkfHlT/_new 2023-03-01 16:14:48.370833781 +0100
@@ -20,7 +20,7 @@
%define __arch_install_post export NO_BRP_STRIP_DEBUG=true
Name: vale
-Version: 2.23.0
+Version: 2.23.3
Release: 0
Summary: CLI tool to lint prose text with syntax awareneness and extensible markup format support
License: MIT
++++++ _service ++++++
--- /var/tmp/diff_new_pack.mkfHlT/_old 2023-03-01 16:14:48.418834029 +0100
+++ /var/tmp/diff_new_pack.mkfHlT/_new 2023-03-01 16:14:48.422834049 +0100
@@ -3,7 +3,7 @@
<param name="url">https://github.com/errata-ai/vale.git</param>
<param name="scm">git</param>
<param name="exclude">.git</param>
- <param name="revision">v2.23.0</param>
+ <param name="revision">v2.23.3</param>
<param name="versionformat">@PARENT_TAG@</param>
<param name="changesgenerate">enable</param>
<param name="versionrewrite-pattern">v(.*)</param>
++++++ _servicedata ++++++
--- /var/tmp/diff_new_pack.mkfHlT/_old 2023-03-01 16:14:48.446834174 +0100
+++ /var/tmp/diff_new_pack.mkfHlT/_new 2023-03-01 16:14:48.450834195 +0100
@@ -1,6 +1,6 @@
<servicedata>
<service name="tar_scm">
<param name="url">https://github.com/errata-ai/vale.git</param>
- <param name="changesrevision">6832233da6bf7ea8cee2d8e2e5add414c50bd187</param></service></servicedata>
+ <param name="changesrevision">0b5d829c7bfb3d930dd547b3f06ec584df51a16c</param></service></servicedata>
(No newline at EOF)
++++++ vale-2.23.0.tar.gz -> vale-2.23.3.tar.gz ++++++
/work/SRC/openSUSE:Factory/vale/vale-2.23.0.tar.gz /work/SRC/openSUSE:Factory/.vale.new.31432/vale-2.23.3.tar.gz differ: char 12, line 1
++++++ vendor.tar.gz ++++++
/work/SRC/openSUSE:Factory/vale/vendor.tar.gz /work/SRC/openSUSE:Factory/.vale.new.31432/vendor.tar.gz differ: char 5, line 1
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package yq for openSUSE:Factory checked in at 2023-03-01 16:14:19
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yq (Old)
and /work/SRC/openSUSE:Factory/.yq.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "yq"
Wed Mar 1 16:14:19 2023 rev:6 rq:1068321 version:4.31.1
Changes:
--------
--- /work/SRC/openSUSE:Factory/yq/yq.changes 2023-01-16 18:02:21.747976983 +0100
+++ /work/SRC/openSUSE:Factory/.yq.new.31432/yq.changes 2023-03-01 16:14:45.870820853 +0100
@@ -1,0 +2,12 @@
+Tue Feb 28 20:21:17 UTC 2023 - Dirk M��ller <dmueller(a)suse.com>
+
+- update to 4.31.1:
+ * Added shuffle command #1503
+ * Added ability to sort by multiple fields #1541
+ * Added @sh encoder #1526
+ * Added @uri/@urid encoder/decoder #1529
+ * Fixed date comparison with string date #1537
+ * Added from_unix/to_unix Operators
+ * Bumped dependency versions
+
+-------------------------------------------------------------------
Old:
----
yq-4.30.8.tar.gz
New:
----
yq-4.31.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ yq.spec ++++++
--- /var/tmp/diff_new_pack.Hw1ALr/_old 2023-03-01 16:14:46.338823273 +0100
+++ /var/tmp/diff_new_pack.Hw1ALr/_new 2023-03-01 16:14:46.346823315 +0100
@@ -20,7 +20,7 @@
%global import_path %{provider_prefix}
Name: yq
-Version: 4.30.8
+Version: 4.31.1
Release: 0
Summary: A portable command-line YAML processor
License: MIT
++++++ vendor.tar.gz ++++++
++++ 29204 lines of diff (skipped)
++++++ yq-4.30.8.tar.gz -> yq-4.31.1.tar.gz ++++++
++++ 2170 lines of diff (skipped)
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package slurm for openSUSE:Factory checked in at 2023-03-01 16:14:17
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/slurm (Old)
and /work/SRC/openSUSE:Factory/.slurm.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "slurm"
Wed Mar 1 16:14:17 2023 rev:83 rq:1068320 version:23.02.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/slurm/slurm.changes 2023-02-09 16:23:31.054808967 +0100
+++ /work/SRC/openSUSE:Factory/.slurm.new.31432/slurm.changes 2023-03-01 16:14:44.838815517 +0100
@@ -1,0 +2,241 @@
+Mon Feb 20 20:45:59 UTC 2023 - Egbert Eich <eich(a)suse.com>
+
+- updated to 23.02.0
+ * Highlights
+ + slurmctld - Add new RPC rate limiting feature. This is enabled through
+ SlurmctldParameters=rl_enable, otherwise disabled by default.
+ + Make scontrol reconfigure and sending a SIGHUP to the slurmctld behave
+ the same. If you were using SIGHUP as a 'lighter' scontrol reconfigure
+ to rotate logs please update your scripts to use SIGUSR2 instead.
+ + Change cloud nodes to show by default. PrivateData=cloud is no longer
+ needed.
+ + sreport - Count planned (FKA reserved) time for jobs running in
+ IGNORE_JOBS reservations. Previously was lumped into IDLE time.
+ + job_container/tmpfs - Support running with an arbitrary list of private
+ mount points (/tmp and /dev/shm are the default, but not required).
+ + job_container/tmpfs - Set more environment variables in InitScript.
+ + Make all cgroup directories created by Slurm owned by root. This was the
+ behavior in cgroup/v2 but not in cgroup/v1 where by default the step
+ directories ownership were set to the user and group of the job.
+ + accounting_storage/mysql - change purge/archive to calculate record ages
+ based on end time, rather than start or submission times.
+ + job_submit/lua - add support for log_user() from slurm_job_modify().
+ + Run the following scripts in slurmscriptd instead of slurmctld:
+ ResumeProgram, ResumeFailProgram, SuspendProgram, ResvProlog, ResvEpilog,
+ and RebootProgram (only with SlurmctldParameters=reboot_from_controller).
+ + Only permit changing log levels with 'srun --slurmd-debug' by root
+ or SlurmUser.
+ + slurmctld will fatal() when reconfiguring the job_submit plugin fails.
+ + Add PowerDownOnIdle partition option to power down nodes after nodes
+ become idle.
+ + Add "[jobid.stepid]" prefix from slurmstepd and "slurmscriptd" prefix
+ from slurmcriptd to Syslog logging. Previously was only happening when
+ logging to a file.
+ + Add purge and archive functionality for job environment and job batch
+ script records.
+ + Extend support for Include files to all "configless" client commands.
+ + Make node weight usable for powered down and rebooting nodes.
+ + Removed 'launch' plugin.
+ + Add "Extra" field to job to store extra information other than a comment.
+ + Add usage gathering for AMD (requires ROCM 5.5+) and NVIDIA gpus.
+ + Add job's allocated nodes, features, oversubscribe, partition, and
+ reservation to SLURM_RESUME_FILE output for power saving.
+ + Automatically create directories for stdout/stderr output files. Paths
+ may use %j and related substitution characters as well.
+ + Add --tres-per-task to salloc/sbatch/srun.
+ + Allow nodefeatures plugin features to work with cloud nodes.
+ e.g. - Powered down nodes have no active changeable features.
+ - Nodes can't be changed to other active features until powered down.
+ - Active changeable features are reset/cleared on power down.
+ + Make slurmstepd cgroups constrained by total configured memory from
+ slurm.conf (NodeName=<> RealMemory=#) instead of total physical memory.
+ + node_features/helpers - add support for the OR and parentheses operators
+ in a --constraint expression.
+ + slurmctld will fatal() when [Prolog|Epilog]Slurmctld are defined but
+ are not executable.
+ + Validate node registered active features are a super set of node's
+ currently active changeable features.
+ + On clusters without any PrologFlags options, batch jobs with failed
+ prologs no longer generate an output file.
+ + Add SLURM_JOB_START_TIME and SLURM_JOB_END_TIME environment variables.
+ + Add SuspendExcStates option to slurm.conf to avoid suspending/powering
+ down specific node states.
+ + Add support for DCMI power readings in IPMI plugin.
+ + slurmrestd served /slurm/v0.0.39 and /slurmdb/v0.0.39 endpoints had major
+ changes from prior versions. Almost all schemas have been renamed and
+ modified. Sites using OpenAPI Generator clients are highly suggested to
+ upgrade to to using atleast version 6.x due to limitations with prior
+ versions.
+ + Allow for --nodelist to contain more nodes than required by --nodes.
+ + Rename "nodes" to "nodes_resume" in SLURM_RESUME_FILE job output.
+ + Rename "all_nodes" to "all_nodes_resume" in SLURM_RESUME_FILE output.
+ + Add jobcomp/kafka plugin.
+ + Add new PreemptParameters=reclaim_licenses option which will allow higher
+ priority jobs to preempt jobs to free up used licenses. (This is only
+ enabled for with PreemptModes of CANCEL and REQUEUE, as Slurm cannot
+ guarantee suspended jobs will release licenses correctly.)
+ + hpe/slingshot - add support for the instant-on feature.
+ + Add ability to update SuspendExc* parameters with scontrol.
+ + Add ability to restore SuspendExc* parameters on restart with slurmctld
+ -R option.
+ + Add ability to clear a GRES specification by setting it to "0" via
+ 'scontrol update job'.
+ + Add SLURM_JOB_OVERSUBSCRIBE environment variable for Epilog, Prolog,
+ EpilogSlurmctld, PrologSlurmctld, and mail ouput.
+ + System node down reasons are appended to existing reasons, separated
+ by ':'.
+ + New command scrun has been added. scrun acts as an Open Container
+ Initiative (OCI) runtime proxy to run containers seamlessly via Slurm.
+ + Fixed GpuFreqDef option. When set in slurm.conf, it will be used if
+ --gpu-freq was not explicitly set by the job step.
+ * Configuration Changes
+ + job_container.conf - Added "Dirs" option to list desired private mount
+ points.
+ + node_features plugins - invalid users specified for AllowUserBoot will
+ now result in fatal() rather than just an error.
+ + Deprecate AllowedKmemSpace, ConstrainKmemSpace, MaxKmemPercent, and
+ MinKmemSpace.
+ + Allow jobs to queue even if the user is not in AllowGroups when
+ EnforcePartLimits=no is set. This ensures consistency for all the
+ Partition access controls, and matches the documented behavior for
+ EnforcePartLimits.
+ + Add InfluxDBTimeout parameter to acct_gather.conf.
+ + job_container/tmpfs - add support for expanding %h and %n in BasePath.
+ + slurm.conf - Removed SlurmctldPlugstack option.
+ + Add new SlurmctldParameters=validate_nodeaddr_threads=<number> option to
+ allow concurrent hostname resolution at slurmctld startup.
+ + Add new AccountingStoreFlags=job_extra option to store a job's extra field
+ in the database.
+ + Add new "defer_batch" option to SchedulerParameters to only defer
+ scheduling for batch jobs.
+ + Add new DebugFlags option 'JobComp' to replace 'Elasticsearch'.
+ + Add configurable job requeue limit parameter - MaxBatchRequeue - in
+ slurm.conf to permit changes from the old hard-coded value of 5.
+ + helpers.conf - Allow specification of node specific features.
+ + helpers.conf - Allow many features to one helper script.
+ + job_container/tmpfs - Add "Shared" option to support shared namespaces.
+ This allows autofs to work with the job_container/tmpfs plugin when
+ enabled.
+ + acct_gather.conf - Added EnergyIPMIPowerSensors=Node=DCMI and
+ Node=DCMI_ENHANCED.
+ + Add new "getnameinfo_cache_timeout=<number>" option to
+ CommunicationParameters to adjust or disable caching the results of
+ getnameinfo().
+ + Add new PrologFlags=ForceRequeueOnFail option to automatically requeue
+ batch jobs on Prolog failures regardless of the job --requeue setting.
+ + Add HealthCheckNodeState=NONDRAINED_IDLE option.
+ + Add 'explicit' to Flags in gres.conf. This makes it so the gres is not
+ automatically added to a job's allocation when --exclusive is used. Note
+ that this is a per-node flag.
+ + Moved the "preempt_" options from SchedulerParameters to
+ PreemptParameters, and dropped the prefix from the option names.
+ (The old options will still be parsed for backwards compatibility,
+ but are now undocumented.)
+ + Add LaunchParameters=ulimit_pam_adopt, which enables setting RLIMIT_RSS
+ in adopted processes.
+ + Update SwitchParameters=job_vni to enable/disable creating job VNIs
+ for all jobs, or when a user requests them.
+ + Update SwitchParameters=single_node_vni to enable/disable creating
+ single node vnis for all jobs, or when a user requests them.
+ + Add ability to preserve SuspendExc* parameters on reconfig with
+ ReconfigFlags=KeepPowerSaveSettings.
+ + slurmdbd.conf - Add new AllResourcesAbsolute to force all new resources
+ to be created with the Absolute flag.
+ + topology/tree - Add new TopologyParam=SwitchAsNodeRank option to reorder
+ nodes based on switch layout. This can be useful if the naming convention
+ for the nodes does not natually map to the network topology.
+ + Removed the default setting for GpuFreqDef. If unset, no attempt to change
+ the GPU frequency will be made if --gpu-freq is not set for the step.
+ * Command Changes
+ + sacctmgr - no longer force updates to the AdminComment, Comment, or
+ SystemComment to lower-case.
+ + sinfo - Add -F/--future option to sinfo to display future nodes.
+ + sacct - Rename 'Reserved' field to 'Planned' to match sreport and the
+ nomenclature of the 'Planned' node.
+ + scontrol - advanced reservation flag MAINT will no longer replace nodes,
+ similar to STATIC_ALLOC
+ + sbatch - add parsing for #PBS -d and #PBS -w.
+ + scontrol show assoc_mgr will show username(uid) instead of uid in
+ QoS section.
+ + Add strigger --draining and -R/--resume options.
+ + Change --oversubscribe and --exclusive to be mutually exclusive for
+ job submission. Job submission commands will now fatal if both are set.
+ Previously, these options would override each other, with the last one
+ in the job submission command taking effect.
+ + scontrol - Requested TRES and allocated TRES will now always be printed
+ when showing jobs, instead of one TRES output that was either the
+ requested or allocated.
+ + srun --ntasks-per-core now applies to job and step allocations. Now,
+ use of --ntasks-per-core=1 implies --cpu-bind=cores and
+ --ntasks-per-core>1 implies --cpu-bind=threads.
+ + salloc/sbatch/srun - Check and abort if ntasks-per-core >
+ threads-per-core.
+ + scontrol - Add ResumeAfter=<secs> option to "scontrol update nodename=".
+ + Add a new "nodes=" argument to scontrol setdebug to allow the debug
+ level on the slurmd processes to be temporarily altered.
+ + Add a new "nodes=" argument to "scontrol setdebugflags" as well.
+ + Make it so scrontab prints client-side the job_submit() err_msg (which
+ can be set i.e. by using the log_user() function for the lua plugin).
+ + scontrol - Reservations will not be allowed to have STATIC_ALLOC or
+ MAINT flags and REPLACE[_DOWN] flags simultaneously.
+ + scontrol - Reservations will only accept one reoccurring flag when
+ being created or updated.
+ + scontrol - A reservation cannot be updated to be reoccurring if it is
+ already a floating reservation.
+ + squeue - removed unused '%s' and 'SelectJobInfo' formats.
+ + squeue - align print format for exit and derived codes with that of
+ other components (<exit_status>:<signal_number>).
+ + sacct - Add --array option to expand job arrays and display array
+ tasks on separate lines.
+ + Partial support for '--json' and '--yaml' formated outputs have been
+ implemented for sacctmgr, sdiag, sinfo, squeue, and scontrol. The
+ resultant data ouput will be filtered by normal command arguments.
+ Formatting arguments will continue to be ignored.
+ + salloc/sbatch/srun - extended the --nodes syntax to allow for a list
+ of valid node counts to be allocated to the job. This also supports
+ a "step count" value (e.g., --nodes=20-100:20 is equivalent to
+ --nodes=20,40,60,80,100) which can simplify the syntax when the job
++++ 47 more lines (skipped)
++++ between /work/SRC/openSUSE:Factory/slurm/slurm.changes
++++ and /work/SRC/openSUSE:Factory/.slurm.new.31432/slurm.changes
Old:
----
slurm-22.05.5.tar.bz2
New:
----
slurm-23.02.0.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ slurm.spec ++++++
--- /var/tmp/diff_new_pack.gBWu6G/_old 2023-03-01 16:14:45.502818950 +0100
+++ /var/tmp/diff_new_pack.gBWu6G/_new 2023-03-01 16:14:45.506818971 +0100
@@ -17,10 +17,12 @@
# Check file META in sources: update so_version to (API_CURRENT - API_AGE)
-%define so_version 38
-%define ver 22.05.5
-%define _ver _22_05
+%define so_version 39
+%define ver 23.02.0
+%define _ver _23_02
+#%%define rc_v 0rc1
%define dl_ver %{ver}
+#%%define dl_ver 23-02-0%{?rc_v:-%rc_v}
# so-version is 0 and seems to be stable
%define pmi_so 0
%define nss_so 2
@@ -54,6 +56,9 @@
%if 0%{?sle_version} == 150300 || 0%{?sle_version} == 150400
%define base_ver 2011
%endif
+%if 0%{?sle_version} == 150500
+%define base_ver 2302
+%endif
%if 0%{?suse_version} >= 1500
%define have_sysuser 1
@@ -148,6 +153,7 @@
Group: Productivity/Clustering/Computing
URL: https://www.schedmd.com
Source: https://download.schedmd.com/slurm/%{pname}-%{dl_ver}.tar.bz2
+#Source: https://github.com/SchedMD/slurm/archive/refs/tags/%{pname}-%{dl_ver}.tar.gz
Source1: slurm-rpmlintrc
Source10: https://raw.githubusercontent.com/openSUSE/hpc/10c105e/files/slurm/slurmd.x…
Source11: https://raw.githubusercontent.com/openSUSE/hpc/10c105e/files/slurm/slurmctl…
@@ -226,6 +232,7 @@
%{?have_sysuser:BuildRequires: sysuser-tools}
%{?systemd_ordering}
BuildRequires: dejagnu
+BuildRequires: zlib-devel
BuildRequires: pkgconfig(dbus-1)
BuildRequires: pkgconfig(systemd)
%else
@@ -638,9 +645,7 @@
%prep
%setup -q -n %{pname}-%{dl_ver}
%patch0 -p1
-#%%patch1 -p1
%patch2 -p1
-#%%patch3 -p1
%patch10 -p1
%patch11 -p1
%patch12 -p1
@@ -1209,8 +1214,8 @@
%files doc
%{?comp_at}
-%dir %{_datadir}/doc/%{pname}-%{dl_ver}
-%{_datadir}/doc/%{pname}-%{dl_ver}/*
+%dir %{_datadir}/doc/%{pname}-%{version}%{?rc_v:-%rc_v}
+%{_datadir}/doc/%{pname}-%{version}%{?rc_v:-%rc_v}/*
%files webdoc
%{?comp_at}
@@ -1302,6 +1307,7 @@
%{_libdir}/slurm/acct_gather_profile_none.so
%{_libdir}/slurm/burst_buffer_lua.so
%{?have_json_c:%{_libdir}/slurm/burst_buffer_datawarp.so}
+%{_libdir}/slurm/data_parser_v0_0_39.so
%{_libdir}/slurm/cgroup_v1.so
%if 0%{?suse_version} >= 1500
%{_libdir}/slurm/cgroup_v2.so
@@ -1335,7 +1341,6 @@
%{_libdir}/slurm/job_submit_partition.so
%{_libdir}/slurm/job_submit_require_timelimit.so
%{_libdir}/slurm/job_submit_throttle.so
-%{_libdir}/slurm/launch_slurm.so
%{_libdir}/slurm/libslurm_pmi.so
%{_libdir}/slurm/mcs_account.so
%{_libdir}/slurm/mcs_group.so
@@ -1369,7 +1374,6 @@
%{_libdir}/slurm/serializer_url_encoded.so
%{_libdir}/slurm/serializer_yaml.so
%{_libdir}/slurm/site_factor_none.so
-%{_libdir}/slurm/slurmctld_nonstop.so
%{_libdir}/slurm/switch_none.so
%{_libdir}/slurm/task_affinity.so
%{_libdir}/slurm/task_cgroup.so
@@ -1428,13 +1432,12 @@
%{?comp_at}
%{_sbindir}/slurmrestd
%{_mandir}/man8/slurmrestd.*
+%{_libdir}/slurm/openapi_dbv0_0_39.so
+%{_libdir}/slurm/openapi_v0_0_39.so
%{_libdir}/slurm/openapi_dbv0_0_38.so
%{_libdir}/slurm/openapi_v0_0_38.so
%{_libdir}/slurm/openapi_dbv0_0_37.so
%{_libdir}/slurm/openapi_v0_0_37.so
-%{_libdir}/slurm/openapi_dbv0_0_36.so
-#%{_libdir}/slurm/openapi_v0_0_35.so
-%{_libdir}/slurm/openapi_v0_0_36.so
#%{_libdir}/slurm/rest_auth_jwt.so
%{_libdir}/slurm/rest_auth_local.so
%endif
@@ -1445,7 +1448,9 @@
%{_sbindir}/slurmstepd
# bsc#1153095
%{_bindir}/srun
+%{_bindir}/scrun
%{_mandir}/man1/srun.1*
+%{_mandir}/man1/scrun.1*
%{_mandir}/man8/slurmd.*
%{_mandir}/man8/slurmstepd*
%if 0%{?with_systemd}
@@ -1506,6 +1511,7 @@
%{_libdir}/slurm/select_cray_aries.so
%{_libdir}/slurm/switch_cray_aries.so
%{_libdir}/slurm/task_cray_aries.so
+%{_libdir}/slurm/proctrack_cray_aries.so
%{_libdir}/slurm/mpi_cray_shasta.so
%if 0%{?have_json_c}
%{_libdir}/slurm/node_features_knl_cray.so
@@ -1518,7 +1524,7 @@
%dir %attr(-, %slurm_u, %slurm_u) /srv/slurm-testsuite
%attr(-, root, root) %{_datadir}/%{name}
%if 0%{?sle_version} == 120200 || 0%{?suse_version} >= 1550
-%dir %{_pam_secconfdir}/limits.d
+%dir %attr(-, root, root) %{_pam_secconfdir}/limits.d
%endif
%doc testsuite/expect/README
%doc %{basename: %{S:21}}
++++++ Fix-test-38.11.patch ++++++
--- /var/tmp/diff_new_pack.gBWu6G/_old 2023-03-01 16:14:45.546819178 +0100
+++ /var/tmp/diff_new_pack.gBWu6G/_new 2023-03-01 16:14:45.550819198 +0100
@@ -1,9 +1,8 @@
From: Egbert Eich <eich(a)suse.com>
-Date: Wed Jun 15 08:41:45 2022 +0200
+Date: Mon Feb 20 21:35:37 2023 +0100
Subject: Fix test 38.11
Patch-mainline: Not yet
-Git-repo: https://github.com/SchedMD/slurm
-Git-commit: 235768790cb2e9cf011e6d08116a468ebec71582
+Git-commit: 80c7c8b897fde0c025f695b8301f4cbbc605581d
References:
Signed-off-by: Egbert Eich <eich(a)suse.com>
@@ -12,20 +11,20 @@
testsuite/expect/test38.11 | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/testsuite/expect/test38.11 b/testsuite/expect/test38.11
-index d2c07d60c7..bf5d10ecc9 100755
+index 3d2954f..89e5333 100755
--- a/testsuite/expect/test38.11
+++ b/testsuite/expect/test38.11
-@@ -99,9 +99,9 @@ make_bash_script $script "
- $srun -N1 -n1 --het-group=0 mkdir -p $tmp_dir/$node1
- $srun -N1 -n1 --het-group=1 mkdir -p $tmp_dir/$node2
+@@ -83,9 +83,9 @@ if {$het_job_id == 0} {
+ run_command -fail "$srun -N1 -n1 --het-group=0 mkdir -p $tmp_dir"
+ run_command -fail "$srun -N1 -n1 --het-group=1 mkdir -p $tmp_dir"
--$sbcast -f -j$het_job_id $srun $tmp_dir/file
--$sbcast -f -j${het_job_id}+0 $srun $tmp_dir/$node1/file_comp0
--$sbcast -f -j${het_job_id}+1 $srun $tmp_dir/$node2/file_comp1
-+$sbcast -f -j\$SLURM_JOBID $srun $tmp_dir/file
-+$sbcast -f -j\$SLURM_JOBID $srun $tmp_dir/$node1/file_comp0
-+$sbcast -f -j\$((SLURM_JOBID+1)) $srun $tmp_dir/$node2/file_comp1
+-run_command -fail "$sbcast -f --jobid=$het_job_id $srun $tmp_dir/file"
+-run_command -fail "$sbcast -f --jobid=${het_job_id}+0 $srun $tmp_dir/file_comp0"
+-run_command -fail "$sbcast -f --jobid=${het_job_id}+1 $srun $tmp_dir/file_comp1"
++run_command -fail "$sbcast -f --jobid=\$SLURM_JOBID $srun $tmp_dir/file"
++run_command -fail "$sbcast -f --jobid=\$SLURM_JOBID $srun $tmp_dir/file_comp0"
++run_command -fail "$sbcast -f --jobid=\$((SLURM_JOBID+1)) $srun $tmp_dir/file_comp1"
- echo -n \"\nChecking node 1: \"
- $srun -Q -N1 -n1 --het-group=1 ls $tmp_dir/file
+ subtest {![run_command_status "$srun -N1 -n1 --het-group=0 ls $tmp_dir/file"]} "Verify main file is in node of component 0"
+ subtest {![run_command_status "$srun -N1 -n1 --het-group=1 ls $tmp_dir/file"]} "Verify main file is in node of component 1"
++++++ pam_slurm-Initialize-arrays-and-pass-sizes.patch ++++++
--- /var/tmp/diff_new_pack.gBWu6G/_old 2023-03-01 16:14:45.602819467 +0100
+++ /var/tmp/diff_new_pack.gBWu6G/_new 2023-03-01 16:14:45.606819487 +0100
@@ -1,22 +1,25 @@
-From: Sebastian Krahmer <krahmer(a)suse.com>
-Date: Thu Feb 2 09:49:38 2017 +0100
-Subject: [PATCH]pam_slurm: Initialize arrays and pass sizes
-Git-repo: https://github.com/SchedMD/slurm
-Git-commit: fbfbb90f6a2e7f134220991ed3263894ba365411
+From: Egbert Eich <eich(a)suse.com>
+Date: Mon Feb 20 21:29:27 2023 +0100
+Subject: pam_slurm: Initialize arrays and pass sizes
+Patch-mainline: Not yet
+Git-commit: 5feca5c29d4e820dafd8d34c0343944b28890902
References: bsc#1007053
-Signed-off-by: Egbert Eich <eich(a)suse.de>
PAM is security critical:
- clear arrays
- ensure strings are NULL-terminated.
Signed-off-by: Egbert Eich <eich(a)suse.com>
+Originally-from: Sebastian Krahmer <krahmer(a)suse.com>
+Signed-off-by: Egbert Eich <eich(a)suse.de>
---
-
-diff -Nrua a/contribs/pam/pam_slurm.c b/contribs/pam/pam_slurm.c
+ contribs/pam/pam_slurm.c | 20 +++++++++++---------
+ 1 file changed, 11 insertions(+), 9 deletions(-)
+diff --git a/contribs/pam/pam_slurm.c b/contribs/pam/pam_slurm.c
+index 20d21a9..363b6ae 100644
--- a/contribs/pam/pam_slurm.c
+++ b/contribs/pam/pam_slurm.c
-@@ -266,9 +266,9 @@
+@@ -266,9 +266,9 @@ static int
_gethostname_short (char *name, size_t len)
{
int error_code, name_len;
@@ -28,7 +31,7 @@
if (error_code)
return error_code;
-@@ -296,13 +296,13 @@
+@@ -296,13 +296,13 @@ static int
_slurm_match_allocation(uid_t uid)
{
int authorized = 0, i;
@@ -37,14 +40,14 @@
char *nodename = NULL;
job_info_msg_t * msg;
- slurm_conf_init(NULL);
+ slurm_init(NULL);
- if (_gethostname_short(hostname, sizeof(hostname)) < 0) {
+ if (_gethostname_short(hostname, sizeof(hostname) - 1) < 0) {
_log_msg(LOG_ERR, "gethostname: %m");
return 0;
}
-@@ -425,7 +425,7 @@
+@@ -425,7 +425,7 @@ _send_denial_msg(pam_handle_t *pamh, struct _options *opts,
*/
extern void libpam_slurm_init (void)
{
@@ -53,7 +56,7 @@
if (slurm_h)
return;
-@@ -433,10 +433,10 @@
+@@ -433,10 +433,10 @@ extern void libpam_slurm_init (void)
/* First try to use the same libslurm version ("libslurm.so.24.0.0"),
* Second try to match the major version number ("libslurm.so.24"),
* Otherwise use "libslurm.so" */
@@ -66,7 +69,7 @@
_log_msg (LOG_ERR, "Unable to write libslurmname\n");
} else if ((slurm_h = dlopen(libslurmname, RTLD_NOW|RTLD_GLOBAL))) {
return;
-@@ -445,8 +445,10 @@
+@@ -445,8 +445,10 @@ extern void libpam_slurm_init (void)
libslurmname, dlerror ());
}
++++++ slurm-22.05.5.tar.bz2 -> slurm-23.02.0.tar.bz2 ++++++
/work/SRC/openSUSE:Factory/slurm/slurm-22.05.5.tar.bz2 /work/SRC/openSUSE:Factory/.slurm.new.31432/slurm-23.02.0.tar.bz2 differ: char 11, line 1
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package java-17-openj9 for openSUSE:Factory checked in at 2023-03-01 16:14:16
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/java-17-openj9 (Old)
and /work/SRC/openSUSE:Factory/.java-17-openj9.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "java-17-openj9"
Wed Mar 1 16:14:16 2023 rev:5 rq:1068374 version:17.0.5.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/java-17-openj9/java-17-openj9.changes 2023-02-25 19:55:21.763359399 +0100
+++ /work/SRC/openSUSE:Factory/.java-17-openj9.new.31432/java-17-openj9.changes 2023-03-01 16:14:41.978800726 +0100
@@ -5 +5 @@
- working and creates another problems (bsc#1205916). It can
+ working and creates another problems (bsc#1206549). It can
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package driverctl for openSUSE:Factory checked in at 2023-03-01 16:14:16
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/driverctl (Old)
and /work/SRC/openSUSE:Factory/.driverctl.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "driverctl"
Wed Mar 1 16:14:16 2023 rev:3 rq:1068306 version:0.111
Changes:
--------
--- /work/SRC/openSUSE:Factory/driverctl/driverctl.changes 2020-08-17 16:42:07.053833314 +0200
+++ /work/SRC/openSUSE:Factory/.driverctl.new.31432/driverctl.changes 2023-03-01 16:14:40.402792577 +0100
@@ -1,0 +2,16 @@
+Fri Feb 24 15:35:17 UTC 2023 - Wolfgang Engel <wolfgang.engel(a)suse.com>
+
+- Add patch add_list-persisted_command-ec102481.patch:
+ * driverctl: add list-persisted command
+ * Fix device driver binding issue after re-enumeration
+ * driverctl: fix list_devices() when `driver_override` is not set
+ * driverctl: fix --help to return success.
+ * Makefile: drop extra '/'
+ * improve help text
+ * bash-completion: suggest pci addresses instead of driver.
+ * bash-completion: add support for options.
+ * bash-completion: simplify and autocomplete cmds.
+ * bash-completion: add support for list- commands.
+
+
+-------------------------------------------------------------------
Old:
----
driverctl-0.111.tar.gz
New:
----
add_list-persisted_command-ec102481.patch
driverctl-0.111.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ driverctl.spec ++++++
--- /var/tmp/diff_new_pack.XfWQEC/_old 2023-03-01 16:14:40.914795224 +0100
+++ /var/tmp/diff_new_pack.XfWQEC/_new 2023-03-01 16:14:40.918795245 +0100
@@ -1,7 +1,7 @@
#
# spec file for package driverctl
#
-# Copyright (c) 2020 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -22,7 +22,8 @@
Summary: Device driver control utility
License: LGPL-2.0-only
URL: https://gitlab.com/driverctl/driverctl
-Source0: https://gitlab.com/driverctl/driverctl/-/archive/%{version}/driverctl-%{ver…
+Source0: https://gitlab.com/driverctl/driverctl/-/archive/%{version}/driverctl-%{ver…
+Patch0: add_list-persisted_command-ec102481.patch
BuildRequires: pkg-config
BuildRequires: pkgconfig(systemd)
BuildRequires: pkgconfig(udev)
@@ -51,6 +52,7 @@
%prep
%setup -q
+%patch0 -p1
%build
%make_build
++++++ add_list-persisted_command-ec102481.patch ++++++
diff -uNr driverctl-0.111/driverctl driverctl-0.111+git20220928.ec10248/driverctl
--- driverctl-0.111/driverctl 2020-02-05 17:49:46.000000000 +0100
+++ driverctl-0.111+git20220928.ec10248/driverctl 2022-09-28 18:28:13.000000000 +0200
@@ -52,6 +52,7 @@
echo " for <device>"
echo " list-devices List all overridable devices"
echo " list-overrides List all currently specified overrides"
+ echo " list-persisted List all persisted overrides"
echo
echo "Supported options:"
echo " -h --help Show this help"
@@ -93,13 +94,18 @@
fi
}
+function override_is_set()
+{
+ [ "$1" != "(null)" ] && [ "$1" != "" ]
+}
+
function list_devices()
{
devices=()
for d in "/sys/bus/$bus/devices"/*; do
if [ -f "$d/driver_override" ]; then
override="$(< "$d/driver_override")"
- if [ "$1" -eq 1 ] && [ "$override" == "(null)" ]; then
+ if [ "$1" -eq 1 ] && ! override_is_set "$override"; then
continue
fi
@@ -115,7 +121,7 @@
else
line+=" (none)"
fi
- if [ "$1" -ne 1 ] && [ "$override" != "(null)" ]; then
+ if [ "$1" -ne 1 ] && override_is_set "$override"; then
line+=" [*]"
fi
@@ -130,6 +136,19 @@
fi
}
+function list_persisted()
+{
+ busL=$(( ${#bus} + 1 ))
+ for d in "$confdir/$bus"-*; do
+ if [ -f "$d" ]; then
+ fn=$(basename "$d")
+ line="${fn:$busL}"
+ line+=" $(< "$d")"
+ echo "$line"
+ fi
+ done
+}
+
function set_override()
{
if [ ! -f "$syspath/driver_override" ]; then
@@ -145,6 +164,9 @@
debug "unsetting driver override for $dev"
fi
unbind
+ if [ "$drv" = "vfio-pci" ]; then
+ echo -n $(< "$syspath/vendor") $(< "$syspath/device") > "/sys/module/vfio_pci/drivers/pci:vfio-pci/new_id"
+ fi
echo "$drv" > "$syspath/driver_override"
if [ "$drv" != "none" ] && [ $probe -ne 0 ]; then
@@ -208,6 +230,15 @@
devtype="${devclasses[${2:-all}]}"
break
;;
+ list-persisted)
+ if [ $# -gt 1 ]; then
+ usage
+ exit 1
+ fi
+
+ cmd=$1
+ break
+ ;;
*)
usage
exit 1
@@ -254,6 +285,9 @@
list-overrides)
list_devices 1 "$devtype"
;;
+ list-persisted)
+ list_persisted
+ ;;
set-override)
set_override "$dev" "$drv"
if [ $save -ne 0 ]; then
diff -uNr driverctl-0.111/driverctl.8 driverctl-0.111+git20220928.ec10248/driverctl.8
--- driverctl-0.111/driverctl.8 2020-02-05 17:49:46.000000000 +0100
+++ driverctl-0.111+git20220928.ec10248/driverctl.8 2022-09-28 18:28:13.000000000 +0200
@@ -117,6 +117,13 @@
as an optional argument, for example "network" to list only network devices.
.RE
+.PP
+\fBlist-persisted\fR
+.RS 4
+List devices with currently persisted overrides on a bus (\fBpci\fR
+by default) along with their driver to be bound on the next boot.
+.RE
+
.SH "EXIT STATUS"
On success, 0 is returned, a non-zero failure code otherwise.
@@ -147,6 +154,13 @@
Remove the override from slot 0000:01:00.1:
# driverctl unset-override 0000:01:00.1
+Transiently remove the override from slot 0000:01:00.0:
+# driverctl --nosave unset-override 0000:01:00.0
+
+Find devices with persisted driver overrides:
+# driverctl list-persisted
+0000:01:00.0 vfio-pci
+
.SH FILES
\fI/etc/driverctl.d/*\fR
++++++ driverctl-0.111.tar.gz -> driverctl-0.111.tar.bz2 ++++++
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package gl3w for openSUSE:Factory checked in at 2023-03-01 16:14:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/gl3w (Old)
and /work/SRC/openSUSE:Factory/.gl3w.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "gl3w"
Wed Mar 1 16:14:15 2023 rev:2 rq:1068304 version:2022.03.24
Changes:
--------
--- /work/SRC/openSUSE:Factory/gl3w/gl3w.changes 2023-02-26 14:51:35.220939899 +0100
+++ /work/SRC/openSUSE:Factory/.gl3w.new.31432/gl3w.changes 2023-03-01 16:14:39.546788150 +0100
@@ -1,0 +2,5 @@
+Sun Feb 26 10:11:07 UTC 2023 - Jan Engelhardt <jengelh(a)inai.de>
+
+- Ensure neutrality of descriptions
+
+-------------------------------------------------------------------
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ gl3w.spec ++++++
--- /var/tmp/diff_new_pack.TYRpm2/_old 2023-03-01 16:14:40.230791687 +0100
+++ /var/tmp/diff_new_pack.TYRpm2/_new 2023-03-01 16:14:40.238791728 +0100
@@ -1,7 +1,7 @@
#
# spec file for package jsonnet
#
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -20,7 +20,7 @@
Name: gl3w
Version: 2022.03.24
Release: 0
-Summary: Simple OpenGL core profile loading
+Summary: OpenGL core profile loading
License: Unlicense
URL: https://github.com/skaslev/gl3w
Source: https://github.com/skaslev/gl3w/archive/%{gitsha}.zip
@@ -32,18 +32,20 @@
BuildRequires: pkgconfig(glu)
%description
-gl3w is the easiest way to get your hands on the functionality offered by the
+gl3w is a way to get at functionality offered by the
OpenGL core profile specification.
%package devel
-Summary: development files for gl3w
+Summary: Header files for gl3w
%description devel
-gl3w is the easiest way to get your hands on the functionality offered by the
-OpenGL core profile specification. - development files
+gl3w is a way to get at functionality offered by the
+OpenGL core profile specification.
+
+This package contains header files for gl3w.
%prep
-%setup -q -n gl3w-%{gitsha}
+%autosetup -n gl3w-%{gitsha}
%build
%cmake
@@ -59,4 +61,5 @@
%license UNLICENSE
%{_includedir}/gl3w
%{_datadir}/gl3w
+
%changelog
1
0
Script 'mail_helper' called by obssrc
Hello community,
here is the log from the commit of package python-node-semver for openSUSE:Factory checked in at 2023-03-01 16:14:14
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-node-semver (Old)
and /work/SRC/openSUSE:Factory/.python-node-semver.new.31432 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "python-node-semver"
Wed Mar 1 16:14:14 2023 rev:9 rq:1068310 version:0.9.0
Changes:
--------
--- /work/SRC/openSUSE:Factory/python-node-semver/python-node-semver.changes 2023-01-03 15:05:14.342465621 +0100
+++ /work/SRC/openSUSE:Factory/.python-node-semver.new.31432/python-node-semver.changes 2023-03-01 16:14:38.766784116 +0100
@@ -1,0 +2,7 @@
+Tue Feb 28 20:07:23 UTC 2023 - Dirk M��ller <dmueller(a)suse.com>
+
+- update to 0.9.0:
+ * RENAME MODULE semver -> nodesemver
+ * pre release range fix
+
+-------------------------------------------------------------------
Old:
----
python-node-semver-0.8.1.tar.gz
New:
----
python-node-semver-0.9.0.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ python-node-semver.spec ++++++
--- /var/tmp/diff_new_pack.SIWI7o/_old 2023-03-01 16:14:39.306786909 +0100
+++ /var/tmp/diff_new_pack.SIWI7o/_new 2023-03-01 16:14:39.310786929 +0100
@@ -19,7 +19,7 @@
%define skip_python2 1
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
Name: python-node-semver
-Version: 0.8.1
+Version: 0.9.0
Release: 0
Summary: Port of node-semver
License: MIT
@@ -55,6 +55,7 @@
%files %{python_files}
%license LICENSE
%doc README.rst
-%{python_sitelib}/*
+%{python_sitelib}/node_semver-%{version}-py*.egg-info
+%{python_sitelib}/nodesemver
%changelog
++++++ python-node-semver-0.8.1.tar.gz -> python-node-semver-0.9.0.tar.gz ++++++
++++ 5169 lines of diff (skipped)
1
0