## START: Set by rpmautospec ## (rpmautospec version 0.3.5) ## RPMAUTOSPEC: autorelease, autochangelog %define autorelease(e:s:pb:n) %{?-p:0.}%{lua: release_number = 1; base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}")); print(release_number + base_release_number - 1); }%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}} ## END: Set by rpmautospec %bcond_without tests # opentelemetry-instrumentation is not yet packaged. %bcond_with opentelemetry-instrumentation # db-dtypes is not yet packaged %bcond_with db-dtypes %global srcname google-cloud-bigquery %global forgeurl https://github.com/googleapis/python-bigquery Version: 3.12.0 %global tag v%{version} %forgemeta Name: python-%{srcname} Release: %autorelease Summary: Python Client for Google BigQuery License: Apache-2.0 URL: %forgeurl Source0: %forgesource BuildArch: noarch ExcludeArch: %{ix86} BuildRequires: python3-devel %if %{with tests} BuildRequires: python3dist(freezegun) BuildRequires: python3dist(google-cloud-testutils) BuildRequires: python3dist(ipython) BuildRequires: python3dist(pytest) BuildRequires: python3dist(pytest-asyncio) %endif %global _description %{expand: Python Client for Google BigQuery} %description %{_description} %package -n python3-%{srcname} Summary: %{summary} %description -n python3-%{srcname} %{_description} # Extra packages %pyproject_extras_subpkg -n python3-%{srcname} bqstorage %if %{with db-dtypes} %pyproject_extras_subpkg -n python3-%{srcname} pandas %endif %if %{with opentelemetry-instrumentation} %pyproject_extras_subpkg -n python3-%{srcname} opentelemetry %endif %pyproject_extras_subpkg -n python3-%{srcname} geopandas %pyproject_extras_subpkg -n python3-%{srcname} ipython %pyproject_extras_subpkg -n python3-%{srcname} tqdm %prep %forgeautosetup # Allow a slightly older protobuf. sed -i 's/"protobuf.*",/"protobuf>=3.19.4",/' setup.py # Replace mock imports with unittest.mock. grep -rl "^[[:space:]]*import mock" tests | \ xargs sed -i -E 's/^([[:space:]]*)import mock/\1from unittest import mock/' # Allow a slightly older version of grpcio. sed -i 's/1.49.1/1.48.3/g' setup.py # Remove Python version limitation. sed -i '/python_requires/d' setup.py # Remove upper bound on Shapely. sed -i 's/Shapely>=1.8.4, <2.0dev/Shapely>=1.8.4/' setup.py %generate_buildrequires %pyproject_buildrequires -x bqstorage,%{?with_db-dtypes:pandas,geopandas,}%{?with_opentelemetry-instrumentation:opentelemetry,}ipython,tqdm %build %pyproject_wheel %install %pyproject_install %pyproject_save_files google %check %pyproject_check_import %if %{with tests} # NOTE(mhayden): Setting PYTHONUSERBASE as a hack for PEP 420 namespaces. # Thanks to churchyard for the fix. PYTHONUSERBASE=%{buildroot}%{_prefix} \ %pytest tests/unit -k "not test___repr__" %endif %files -n python3-%{srcname} -f %{pyproject_files} %license LICENSE %doc README.rst CHANGELOG.md %{python3_sitelib}/google_cloud_bigquery-%{version}-py%{python3_version}-nspkg.pth %changelog * Tue Oct 03 2023 Packit - 3.12.0-1 - [packit] 3.12.0 upstream release * Thu Jul 20 2023 Major Hayden - 3.11.4-1 - Update to 3.11.4 rhbz#2216775 * Sun Jul 02 2023 Python Maint - 3.11.1-2 - Rebuilt for Python 3.12 * Fri Jun 16 2023 Major Hayden - 3.11.1-1 - Update to 3.11.1 rhbz#2214614 * Mon Jun 12 2023 Major Hayden - 3.11.0-1 - Update to 3.11.0 rhbz#2211724 * Thu Apr 20 2023 Major Hayden - 3.10.0-1 - Update to 3.10.0 rhbz#2186354 * Tue Mar 28 2023 Major Hayden - 3.9.0-1 - Update to 3.9.0 rhbz#2182448 * Mon Mar 27 2023 Major Hayden - 3.8.0-1 - Update to 3.8.0 rhbz#2182079 * Mon Mar 20 2023 Major Hayden - 3.7.0-1 - Update to 3.7.0 rhbz#2177890 * Wed Mar 01 2023 Major Hayden - 3.6.0-2 - Shapely: remove upper bound rhbz#2173428 * Wed Mar 01 2023 Major Hayden - 3.6.0-1 - Update to 3.6.0 rhbz#2172668 * Tue Feb 21 2023 Major Hayden - 3.5.0-1 - Update to 3.5.0 rhbz#2152677 * Tue Feb 21 2023 Major Hayden - 3.4.0-7 - Apply PYTHONUSERBASE namespace hack for testing * Tue Feb 21 2023 Major Hayden - 3.4.0-6 - Fix license string * Tue Feb 14 2023 Major Hayden - 3.4.0-5 - Remove upper bound for pyarrow * Fri Feb 10 2023 Major Hayden - 3.4.0-4 - Fix FTI bug rhbz#2168137 * Thu Feb 09 2023 Benjamin A. Beasley - 3.4.0-3 - Remove packaging version upper-bound (fix RHBZ#2168137) * Fri Jan 20 2023 Fedora Release Engineering - 3.4.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild * Wed Dec 07 2022 Major Hayden - 3.4.0-1 - Update to 3.4.0 rhbz#2144021 * Mon Nov 07 2022 fkolwa - 3.3.6-1 - Update to 3.3.6 rhbz#2140167 * Wed Oct 19 2022 Major Hayden - 3.3.5-1 - Update to 3.3.5 rhbz#2133575 * Fri Sep 30 2022 fkolwa - 3.3.3-1 - Update to 3.3.3 rhbz#2131079 * Fri Sep 16 2022 Benjamin A. Beasley - 3.3.2-4 - Generate BR’s for extras * Fri Sep 16 2022 Benjamin A. Beasley - 3.3.2-3 - Enable pyarrow support * Fri Sep 16 2022 Benjamin A. Beasley - 3.3.2-2 - Add ExcludeArch on i686 * Fri Aug 26 2022 Major Hayden - 3.3.2-1 - Update to 3.3.2 rhbz#2116850 * Fri Jul 22 2022 Fedora Release Engineering - 2.34.4-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild * Wed Jun 29 2022 Major Hayden - 2.34.4-2 - Enable some extras packages * Wed Jun 29 2022 Major Hayden - 2.34.4-1 - Update to 2.34.4, fix FTBFS rhbz#2098932 * Tue Jun 28 2022 Python Maint - 2.34.3-2 - Rebuilt for Python 3.11 * Fri May 06 2022 Major Hayden - 2.34.3-1 - Update to 2.34.3 * Fri Jan 21 2022 Fedora Release Engineering - 2.30.1-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild * Mon Nov 08 2021 Major Hayden - 2.30.1-1 - Update to 2.30.1 * Thu Nov 04 2021 Major Hayden - 2.30.0-1 - Update to 2.30.0 * Wed Oct 27 2021 Major Hayden - 2.29.0-1 - Update to 2.29.0 * Thu Oct 07 2021 Major Hayden - 2.28.1-1 - Update to 2.28.1 * Tue Oct 05 2021 Major Hayden - 2.28.0-1 - Initial import (#2010752)