%global pypi_name etelemetry Name: python-%{pypi_name} Version: 0.3.1 Release: 1%{?dist} Summary: Lightweight client for checking a project's latest version License: Apache-2.0 URL: https://github.com/sensein/etelemetry-client Source0: https://github.com/sensein/etelemetry-client/archive/v%{version}/etelemetry-client-%{version}.tar.gz BuildArch: noarch BuildRequires: python3-devel %global _description %{expand: etelemetry-client queries the etelemetry service for the latest release of a project and for known-bad versions. dandi and NiPype use it.} %description %{_description} %package -n python3-%{pypi_name} Summary: %{summary} %description -n python3-%{pypi_name} %{_description} %prep %autosetup -p1 -n etelemetry-client-%{version} # A GitHub tag archive has no git metadata for versioneer to read; pin the version. cat > etelemetry/_version.py << 'EOF' def get_versions(): return {'version': '%{version}', 'full-revisionid': None, 'dirty': False, 'error': None, 'date': None} EOF sed -i 's/version=versioneer.get_version()/version="%{version}"/' setup.py grep -q 'version="%{version}"' setup.py %generate_buildrequires %pyproject_buildrequires %build %pyproject_wheel %install %pyproject_install # Build helpers some DataLad-template projects install at top level; not part of the package. rm -rf %{buildroot}%{python3_sitelib}/_datalad_buildsupport %{buildroot}%{python3_sitelib}/tools %{buildroot}%{python3_sitelib}/benchmarks %{buildroot}%{python3_sitelib}/tests %{buildroot}%{python3_sitelib}/tests.py # Old setup.py data_files can drop these at the top of site-packages (osfclient does). rm -f %{buildroot}%{python3_sitelib}/{LICENSE,VERSION,requirements.txt} %pyproject_save_files -L etelemetry %check %pyproject_check_import -e 'etelemetry.tests*' -e 'etelemetry.*.tests*' -e '*.test_*' -e '*.conftest' -e '*.pytest_plugin' %files -n python3-%{pypi_name} -f %{pyproject_files} %license LICENSE %changelog * Mon Oct 12 2026 Morgan Hough - 0.3.1-1 - Initial package, for the DataLad extension stack and dandi.