HemangChothani: The failed test has nothing to do with the changes here.
plamut: Indeed, and I will temporarily disable it (as per recent discussion) until that issue gets fixed.
plamut: @HemangChothani Please just update the branch so that we can merge this, thanks!
diff --git a/google/cloud/bigquery/model.py b/google/cloud/bigquery/model.py
index d39ec5f2..a2510e86 100644
--- a/google/cloud/bigquery/model.py
+++ b/google/cloud/bigquery/model.py
@@ -430,6 +430,6 @@ class ModelReference(object):
         return hash(self._key())
 
     def __repr__(self):
-        return "ModelReference(project='{}', dataset_id='{}', project_id='{}')".format(
+        return "ModelReference(project_id='{}', dataset_id='{}', model_id='{}')".format(
             self.project, self.dataset_id, self.model_id
         )

Bigquery: Model reference repr seems wrong for model_id
For `ModelReference`'s repr use project_id against model_id

https://github.com/googleapis/python-bigquery/blob/be5c8b1ede9a2d762fd5574c32587d125eca4713/google/cloud/bigquery/model.py#L432-L435
diff --git a/tests/unit/model/test_model.py b/tests/unit/model/test_model.py
index bbb93ef9..90fc09e6 100644
--- a/tests/unit/model/test_model.py
+++ b/tests/unit/model/test_model.py
@@ -316,5 +316,5 @@ def test_repr(target_class):
     got = repr(model)
     assert got == (
         "Model(reference=ModelReference("
-        "project='my-proj', dataset_id='my_dset', project_id='my_model'))"
+        "project_id='my-proj', dataset_id='my_dset', model_id='my_model'))"
     )
diff --git a/tests/unit/model/test_model_reference.py b/tests/unit/model/test_model_reference.py
index ff1d1df7..39dabb55 100644
--- a/tests/unit/model/test_model_reference.py
+++ b/tests/unit/model/test_model_reference.py
@@ -136,5 +136,5 @@ def test_repr(target_class):
     got = repr(model)
     assert (
         got
-        == "ModelReference(project='my-proj', dataset_id='my_dset', project_id='my_model')"
+        == "ModelReference(project_id='my-proj', dataset_id='my_dset', model_id='my_model')"
     )

pip install -e .[all]
parse_log_pytest
requirements.txt
pytest pytest-cov
3.8
requirements/base.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
cachetools==4.2.4
certifi==2025.1.31
charset-normalizer==3.4.1
coverage==7.6.1
exceptiongroup==1.2.2
google-api-core==1.34.1
google-auth==1.35.0
-e git+https://github.com/googleapis/python-bigquery.git@2abdef82bed31601d1ca1aa92a10fea1e09f5297#egg=google_cloud_bigquery
google-cloud-bigquery-storage==1.1.2
google-cloud-core==1.7.3
google-resumable-media==0.5.1
googleapis-common-protos==1.69.2
grpcio==1.70.0
grpcio-status==1.48.2
idna==3.10
iniconfig==2.1.0
numpy==1.24.4
packaging==24.2
pandas==2.0.3
pluggy==1.5.0
protobuf==3.20.3
pyarrow==1.0.1
pyasn1==0.6.1
pyasn1_modules==0.4.2
pytest==8.3.5
pytest-cov==5.0.0
python-dateutil==2.9.0.post0
pytz==2025.2
requests==2.32.3
rsa==4.9
six==1.17.0
tomli==2.2.1
tqdm==4.67.1
tzdata==2025.2
urllib3==2.2.3

name: python-bigquery
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=24.2=py38h06a4308_0
  - python=3.8.20=he870216_0
  - readline=8.2=h5eee18b_0
  - setuptools=75.1.0=py38h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - wheel=0.44.0=py38h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - cachetools==4.2.4
      - certifi==2025.1.31
      - charset-normalizer==3.4.1
      - coverage==7.6.1
      - exceptiongroup==1.2.2
      - google-api-core==1.34.1
      - google-auth==1.35.0
      - google-cloud-bigquery-storage==1.1.2
      - google-cloud-core==1.7.3
      - google-resumable-media==0.5.1
      - googleapis-common-protos==1.69.2
      - grpcio==1.70.0
      - grpcio-status==1.48.2
      - idna==3.10
      - iniconfig==2.1.0
      - numpy==1.24.4
      - packaging==24.2
      - pandas==2.0.3
      - pluggy==1.5.0
      - protobuf==3.20.3
      - pyarrow==1.0.1
      - pyasn1==0.6.1
      - pyasn1-modules==0.4.2
      - pytest==8.3.5
      - pytest-cov==5.0.0
      - python-dateutil==2.9.0.post0
      - pytz==2025.2
      - requests==2.32.3
      - rsa==4.9
      - six==1.17.0
      - tomli==2.2.1
      - tqdm==4.67.1
      - tzdata==2025.2
      - urllib3==2.2.3
prefix: /opt/conda/envs/python-bigquery

tests/unit/model/test_model.py::test_repr tests/unit/model/test_model_reference.py::test_repr
tests/unit/model/test_model.py::test_ctor tests/unit/model/test_model.py::test_ctor_string tests/unit/model/test_model.py::test_from_api_repr tests/unit/model/test_model.py::test_from_api_repr_w_minimal_resource tests/unit/model/test_model.py::test_from_api_repr_w_unknown_fields tests/unit/model/test_model.py::test_build_resource[resource0-filter_fields0-expected0] tests/unit/model/test_model.py::test_build_resource[resource1-filter_fields1-expected1] tests/unit/model/test_model.py::test_build_resource[resource2-filter_fields2-expected2] tests/unit/model/test_model.py::test_build_resource[resource3-filter_fields3-expected3] tests/unit/model/test_model.py::test_build_resource[resource4-filter_fields4-expected4] tests/unit/model/test_model.py::test_build_resource[resource5-filter_fields5-expected5] tests/unit/model/test_model.py::test_set_description tests/unit/model/test_model.py::test_set_expires tests/unit/model/test_model.py::test_set_friendly_name tests/unit/model/test_model.py::test_set_labels tests/unit/model/test_model.py::test_replace_labels tests/unit/model/test_model.py::test_set_encryption_configuration tests/unit/model/test_model_reference.py::test_from_api_repr tests/unit/model/test_model_reference.py::test_from_api_repr_w_unknown_fields tests/unit/model/test_model_reference.py::test_to_api_repr tests/unit/model/test_model_reference.py::test_from_string tests/unit/model/test_model_reference.py::test_from_string_legacy_string tests/unit/model/test_model_reference.py::test_from_string_not_fully_qualified tests/unit/model/test_model_reference.py::test_from_string_with_default_project tests/unit/model/test_model_reference.py::test_from_string_ignores_default_project tests/unit/model/test_model_reference.py::test_eq tests/unit/model/test_model_reference.py::test_hash
google/cloud/bigquery/model.py
google/cloud/bigquery/model.py