## Change Summary

* #7811 - make sure specification for `__pydantic_fields_set__`, `model_fields_set`, and `exclude_unset` is consistent (in docstrings + docs)
* #7588 - adding explanation for changes to `model_rebuild` vs `update_forward_refs` to migration guide

## Related issue number

Fix #7811
Fix #7588

## Checklist

* [x] The pull request title is a good summary of the changes - it will be used in the changelog
* [x] Unit tests for the changes exist
* [ ] Tests pass on CI
* [x] Documentation reflects the changes where applicable
* [x] My PR is ready to review, **please add a comment including the phrase "please review" to assign reviewers**


Selected Reviewer: @dmontagu
Docs update: keeping model_fields_set defs consistent and adding explanation for model_rebuild changes. ## Change Summary

* #7811 - make sure specification for `__pydantic_fields_set__`, `model_fields_set`, and `exclude_unset` is consistent (in docstrings + docs)
* #7588 - adding explanation for changes to `model_rebuild` vs `update_forward_refs` to migration guide

## Related issue number

Fix #7811
Fix #7588

## Checklist

* [x] The pull request title is a good summary of the changes - it will be used in the changelog
* [x] Unit tests for the changes exist
* [ ] Tests pass on CI
* [x] Documentation reflects the changes where applicable
* [x] My PR is ready to review, **please add a comment including the phrase "please review" to assign reviewers**


Selected Reviewer: @dmontagu
"""
Test mypy failure with invalid types.
"""
from datetime import datetime
from typing import List, Optional

from pydantic import BaseModel


class Model(BaseModel):
    age: int
    first_name = 'John'
    last_name: Optional[str] = None
    signup_ts: Optional[datetime] = None
    list_of_ints: List[int]


m = Model(age=42, list_of_ints=[1, '2', b'3'])

print(m.foobar)
# MYPY: error: "Model" has no attribute "foobar"  [attr-defined]

"""
Test mypy failure with invalid types.
"""
from datetime import datetime
from typing import List, Optional

from pydantic import BaseModel


class Model(BaseModel):
    age: int
    first_name = 'John'
    last_name: Optional[str] = None
    signup_ts: Optional[datetime] = None
    list_of_ints: List[int]


m = Model(age=42, list_of_ints=[1, '2', b'3'])

print(m.foobar)
# MYPY: error: "Model" has no attribute "foobar"  [attr-defined]
