René's URL Explorer Experiment


Title: RemoteProgress._parse_progress_line may merit a broader return type · Issue #1834 · gitpython-developers/GitPython · GitHub

Open Graph Title: RemoteProgress._parse_progress_line may merit a broader return type · Issue #1834 · gitpython-developers/GitPython

X Title: RemoteProgress._parse_progress_line may merit a broader return type · Issue #1834 · gitpython-developers/GitPython

Description: RemoteProgress._parse_progress_line is conceptually a "protected" method: code outside GitPython may subclass RemoteProgress and override it with another implementation (which may also reasonably call the base class implementation). The ...

Open Graph Description: RemoteProgress._parse_progress_line is conceptually a "protected" method: code outside GitPython may subclass RemoteProgress and override it with another implementation (which may also reasonably c...

X Description: RemoteProgress._parse_progress_line is conceptually a "protected" method: code outside GitPython may subclass RemoteProgress and override it with another implementation (which may also re...

Opengraph URL: https://github.com/gitpython-developers/GitPython/issues/1834

X: @github

direct link

Domain: Github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"RemoteProgress._parse_progress_line may merit a broader return type","articleBody":"`RemoteProgress._parse_progress_line` is conceptually a \"protected\" method: code outside GitPython may subclass `RemoteProgress` and override it with another implementation (which may also reasonably call the base class implementation).\r\n\r\nThe method is [conceptually void](https://github.com/gitpython-developers/GitPython/pull/1755) as implemented in the base class, always implicitly returning `None`, and it is annotated accordingly:\r\n\r\nhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/git/util.py#L582\r\n\r\nHowever, while it would not ordinarily be useful to do so, it is--or *has* been--also intended that it be overridable to return a non-`None` value. This is mostly for compatibility with existing code that may have done so in the past, but it may be that reasonable cases for doing so in new code can still arise. This is reflected in code of GitPython:\r\n\r\nhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/git/util.py#L685-L697\r\n\r\nAnd in the subclass of `RemoteProgress` introduced in the test suite, which overrides the method:\r\n\r\nhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/test/test_remote.py#L54-L59\r\n\r\nBut any override that returns a non-`None` value is currently inconsistent with the return type annotation on the base class, which is written as `-\u003e None`. For Liskov substitutability, an overridden method's return type must be the same or a subclass of the base method's return type, and if a subclass has type annotations, and the return type is specified as a non-`Any` type, type checkers such as `mypy` and `pyright` will report a non-`None` return type as a violation.\r\n\r\nIf possible, the return type in `RemoteProgress` should be broadened, but in a way that does not unduly encourage subclasses to return non-`None`. **See comments on #1788, starting at https://github.com/gitpython-developers/GitPython/pull/1788#issuecomment-1869653326, for a discussion and analysis of this.** This issue, and the above recommendation, is based on the findings and discussion there.","author":{"url":"https://github.com/EliahKagan","@type":"Person","name":"EliahKagan"},"datePublished":"2024-02-20T23:39:26.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/1834/GitPython/issues/1834"}

route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:b4117c6b-1c45-8056-9a00-e6d27bba7f39
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idECEC:26C11C:85ADCA:B8E84C:6A624574
html-safe-nonce2cab385a80c2ded12cfd280deb9f345555e479395c8a293cf322fd6c3fbabc82
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFQ0VDOjI2QzExQzo4NUFEQ0E6QjhFODRDOjZBNjI0NTc0IiwidmlzaXRvcl9pZCI6IjM4OTUwMDA4OTUwMDEzNDc0NDQiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac9bf7055e40eaa9514b9f6a8df7873839d786d78099e3b3bf58c199017a982006
hovercard-subject-tagissue:2145472326
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/gitpython-developers/GitPython/1834/issue_layout
twitter:imagehttps://opengraph.githubassets.com/fe94911518e7d7e4cdb502d18854a868e25db71a7e50defa80915dfd69bd6f1b/gitpython-developers/GitPython/issues/1834
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/fe94911518e7d7e4cdb502d18854a868e25db71a7e50defa80915dfd69bd6f1b/gitpython-developers/GitPython/issues/1834
og:image:altRemoteProgress._parse_progress_line is conceptually a "protected" method: code outside GitPython may subclass RemoteProgress and override it with another implementation (which may also reasonably c...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameEliahKagan
hostnamegithub.com
expected-hostnamegithub.com
None5d6ba65d73ecc4e3394fe318d2b2f98e6f8eed4878b5421b938e20d30bde267b
turbo-cache-controlno-preview
go-importgithub.com/gitpython-developers/GitPython git https://github.com/gitpython-developers/GitPython.git
octolytics-dimension-user_id503709
octolytics-dimension-user_logingitpython-developers
octolytics-dimension-repository_id1126087
octolytics-dimension-repository_nwogitpython-developers/GitPython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1126087
octolytics-dimension-repository_network_root_nwogitpython-developers/GitPython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release2dadc56fd5989b76a8ae7304e3aa56d0b485e5dc
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://Github.com/gitpython-developers/GitPython/issues/1834#start-of-content
https://Github.com/
Sign in https://Github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgitpython-developers%2FGitPython%2Fissues%2F1834
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
Code QualityEnforce quality at mergehttps://github.com/features/code-quality
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://Github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgitpython-developers%2FGitPython%2Fissues%2F1834
Sign up https://Github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=gitpython-developers%2FGitPython
Reloadhttps://Github.com/gitpython-developers/GitPython/issues/1834
Reloadhttps://Github.com/gitpython-developers/GitPython/issues/1834
Reloadhttps://Github.com/gitpython-developers/GitPython/issues/1834
Please reload this pagehttps://Github.com/gitpython-developers/GitPython/issues/1834
gitpython-developers https://Github.com/gitpython-developers
GitPythonhttps://Github.com/gitpython-developers/GitPython
Please reload this pagehttps://Github.com/gitpython-developers/GitPython/issues/1834
Notifications https://Github.com/login?return_to=%2Fgitpython-developers%2FGitPython
Fork 983 https://Github.com/login?return_to=%2Fgitpython-developers%2FGitPython
Star 5.1k https://Github.com/login?return_to=%2Fgitpython-developers%2FGitPython
Code https://Github.com/gitpython-developers/GitPython
Issues 15 https://Github.com/gitpython-developers/GitPython/issues
Pull requests 4 https://Github.com/gitpython-developers/GitPython/pulls
Discussions https://Github.com/gitpython-developers/GitPython/discussions
Actions https://Github.com/gitpython-developers/GitPython/actions
Security and quality 17 https://Github.com/gitpython-developers/GitPython/security
Insights https://Github.com/gitpython-developers/GitPython/pulse
Code https://Github.com/gitpython-developers/GitPython
Issues https://Github.com/gitpython-developers/GitPython/issues
Pull requests https://Github.com/gitpython-developers/GitPython/pulls
Discussions https://Github.com/gitpython-developers/GitPython/discussions
Actions https://Github.com/gitpython-developers/GitPython/actions
Security and quality https://Github.com/gitpython-developers/GitPython/security
Insights https://Github.com/gitpython-developers/GitPython/pulse
Featurehttps://Github.com/gitpython-developers/GitPython/issues?q=type:"Feature"
RemoteProgress._parse_progress_line may merit a broader return typehttps://Github.com/gitpython-developers/GitPython/issues/1834#top
acknowledgedhttps://github.com/gitpython-developers/GitPython/issues?q=state%3Aopen%20label%3A%22acknowledged%22
help wantedhttps://github.com/gitpython-developers/GitPython/issues?q=state%3Aopen%20label%3A%22help%20wanted%22
https://github.com/EliahKagan
EliahKaganhttps://github.com/EliahKagan
on Feb 20, 2024https://github.com/gitpython-developers/GitPython/issues/1834#issue-2145472326
conceptually voidhttps://github.com/gitpython-developers/GitPython/pull/1755
GitPython/git/util.pyhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/git/util.py#L582
afa5754https://Github.com/gitpython-developers/GitPython/commit/afa575454f85b34800460881cc9c3cd7fe78c8e3
GitPython/git/util.pyhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/git/util.py#L685-L697
afa5754https://Github.com/gitpython-developers/GitPython/commit/afa575454f85b34800460881cc9c3cd7fe78c8e3
GitPython/test/test_remote.pyhttps://github.com/gitpython-developers/GitPython/blob/afa575454f85b34800460881cc9c3cd7fe78c8e3/test/test_remote.py#L54-L59
afa5754https://Github.com/gitpython-developers/GitPython/commit/afa575454f85b34800460881cc9c3cd7fe78c8e3
#1788https://github.com/gitpython-developers/GitPython/pull/1788
#1788 (comment)https://github.com/gitpython-developers/GitPython/pull/1788#issuecomment-1869653326
acknowledgedhttps://github.com/gitpython-developers/GitPython/issues?q=state%3Aopen%20label%3A%22acknowledged%22
help wantedhttps://github.com/gitpython-developers/GitPython/issues?q=state%3Aopen%20label%3A%22help%20wanted%22
Featurehttps://Github.com/gitpython-developers/GitPython/issues?q=type:"Feature"
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.