unstale

pypi / pygithub

pygithub

What changed in pygithub 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-21.

3 breaking1 security6 deprecations15 new APIs and options13 fixes and other

See which of these apply to your code, ranked, in your agent:

npx @unstale/cli init

@unstale/cli 0.2.2 on npm

pygithub 238 changes

Breaking changes 3

  • PyGithub adds support for Python 3.15.

    2.10.0release notes

  • Support for Python 3.9 has been removed because it reached end-of-life.

    2.10.0release notes

  • Support for Python 3.8 has been removed because the Python version reached end-of-life.

    2.9.0release notes

Security 1

  • Fixes a duplicated URL; editing now seals the value and uses PUT.

    2.10.0release notes

Deprecations 6

  • Issue.assignee is deprecated; use Issue.assignees instead.

    2.9.0release notes

  • The assignee parameter is deprecated; use assignees instead.

    2.9.0release notes

  • Organization.edit_hook is deprecated; use Organization.get_hook(id).edit(...) instead. A lazy Github instance can avoid fetching the Hook object first.

    2.9.0release notes

  • Reaction.delete is deprecated; use the corresponding delete_reaction method on IssueComment, PullRequestComment, CommitComment, or Issue instead.

    2.9.0release notes

  • Team.add_to_members is deprecated; use Team.add_membership instead.

    2.9.0release notes

  • Team.remove_from_members is deprecated; use Team.remove_membership instead.

    2.9.0release notes

New APIs and options 15

  • Allows creating a custom property with the values_editable_by parameter.

    2.10.0release notes

  • The GitHub API version can now be specified.

    2.10.0release notes

  • Adds max_rate_limit_wait to cap rate limit backoff.

    2.10.0release notes

  • Issue dependency endpoints are now available.

    2.10.0release notes

  • Adds the incomplete_results property to PaginatedList.

    2.10.0release notes

  • Pull request creation now supports head_repo.

    2.10.0release notes

  • Adds Repository.get_workflow_job.

    2.10.0release notes

  • Adds the return_run_details parameter.

    2.10.0release notes

  • Adds WorkflowRun.get_attempt.

    2.10.0release notes

  • Code Scan Alerts support was improved.

    2.9.0release notes

  • get_issues now supports the type parameter.

    2.9.0release notes

  • Github instances can be created with lazy=True; object retrieval avoids API requests until methods or properties need the data. Lazy mode is off by default.

    2.9.0release notes

  • An individual per_page value can be specified when retrieving objects with paginated properties or fetching those properties.

    2.9.0release notes

  • Support for Secret Scanning Alerts was added.

    2.9.0release notes

  • A throw option was added to Workflow.create_dispatch to raise exceptions.

    2.9.0release notes

Fixes and other changes 13

  • Fixes a doubled slash in request paths when base_url has a trailing slash.

    2.10.0release notes

  • Boolean query parameters are now encoded as lowercase.

    2.10.0release notes

  • Fixes decoding of bytes data when converting GithubException to a string.

    2.10.0release notes

  • Fixes lazy retrieval of the latest tag name.

    2.10.0release notes

  • Fixes handling of the state and code_verifier parameters.

    2.10.0release notes

  • Fixes a duplicated URL in OrganizationVariable.edit.

    2.10.0release notes

  • Fixes OrganizationVariable.value by using the base class properly.

    2.10.0release notes

  • Parses only the query string when determining totalCount.

    2.10.0release notes

  • Fixed getting a release by tag in lazy mode.

    2.9.1release notes

  • Enterprise base URLs prefixed with api. are now allowed.

    2.9.0release notes

  • A default type is now used when a known type is unsupported.

    2.9.0release notes

  • Fixed totalCount returning 0 when GitHub deprecation notices are present.

    2.9.0release notes

  • Iterating paginated properties now uses the configured per_page setting.

    2.9.0release notes