René's URL Explorer Experiment


Title: Unable to obtain empty file from git repo via MCP · Issue #2041 · github/github-mcp-server · GitHub

Open Graph Title: Unable to obtain empty file from git repo via MCP · Issue #2041 · github/github-mcp-server

X Title: Unable to obtain empty file from git repo via MCP · Issue #2041 · github/github-mcp-server

Description: Describe the bug get_file_contents tool fails when you try to obtain file which is empty (0 bytes) Affected version Latest and GitHub managed MCP server Steps to reproduce the behavior Example repo: https://github.com/kubajanusz/mcp-404-...

Open Graph Description: Describe the bug get_file_contents tool fails when you try to obtain file which is empty (0 bytes) Affected version Latest and GitHub managed MCP server Steps to reproduce the behavior Example repo...

X Description: Describe the bug get_file_contents tool fails when you try to obtain file which is empty (0 bytes) Affected version Latest and GitHub managed MCP server Steps to reproduce the behavior Example repo...

Opengraph URL: https://github.com/github/github-mcp-server/issues/2041

X: @github

direct link

Domain: github.com

IPv4 address: 140.82.112.3


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Unable to obtain empty file from git repo via MCP","articleBody":"### Describe the bug\n\nget_file_contents tool fails when you try to obtain file which is empty (0 bytes)\n\n### Affected version\n\nLatest and GitHub managed MCP server\n\n### Steps to reproduce the behavior\n\nExample repo: https://github.com/kubajanusz/mcp-404-and-tag-errors-example\n\n1. Prompt: `Run #get_file_contents to obtain file README.md from main branch`\n2. File is obtained\n3. See error\n```\nCannot read properties of undefined (reading 'length') (at tsx element Lx > sV > $Ne > Get > Xs > \u003canonymous> > \u003canonymous> > Wrt > zet > Zet > Uh > Ket > Sde > YD)\n```\n\n\u003cimg width=\"560\" height=\"596\" alt=\"Image\" src=\"https://github.com/user-attachments/assets/09e1d6df-9011-4914-a5da-6a832fcf26d5\" />\n\n### Expected vs actual behavior\n\nInformation that file is empty is handled and passed back to VS Code\n\n### Logs\n\n```\n2026-02-18 17:06:57.546 [info] ccreq:eb41aca6.copilotmd | success | claude-opus-4.6 -> claude-opus-4-6 | 9205ms | [panel/editAgent]\n2026-02-18 17:06:58.569 [error] TypeError (FileSystemError): Cannot read properties of undefined (reading 'length') (at tsx element Lx > sV > $Ne > Get > Xs > \u003canonymous> > \u003canonymous> > Wrt > zet > Zet > Uh > Ket > Sde > YD)\n\tat Rr.e (file:///home/user/.vscode-server/bin/c3a26841a84f20dfe0850d0a5a9bd01da4f003ea/out/vs/workbench/api/node/extensionHostProcess.js:116:18876)\n\tat Object.stat (file:///home/user/.vscode-server/bin/c3a26841a84f20dfe0850d0a5a9bd01da4f003ea/out/vs/workbench/api/node/extensionHostProcess.js:116:16027)\n\tat process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n\tat async TXe (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1213:10510)\n\tat async woe.readFile (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:5529:17209)\n\tat async YD.render (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1498:859)\n\tat async MHt (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:144:3828)\n\tat async /home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28188\n\tat async Promise.all (index 0)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28099)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft._processPromptRenderPiece (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28693)\n\tat async Ft._processPromptPieces (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:28343)\n\tat async Ft.renderRaw (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:29134)\n\tat async Ft.render (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:142:29018)\n\tat async Ft.render (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1484:14032)\n\tat async C2.buildPrompt (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2007:6435)\n\tat async Che.buildPrompt (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2001:7518)\n\tat async Che.buildPrompt2 (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1648:11591)\n\tat async Che.runOne (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1648:6047)\n\tat async Che.run (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:1648:2288)\n\tat async jy.runWithToolCalling (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2001:11)\n\tat async jy.getResult (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2000:1437)\n\tat async She.getResult (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2005:5959)\n\tat async RM.getResult (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:2018:9182)\n\tat async t3.x (/home/user/.vscode-server/extensions/github.copilot-chat-0.37.6/dist/extension.js:6200:1359)\n\tat async _d.$invokeAgent (file:///home/user/.vscode-server/bin/c3a26841a84f20dfe0850d0a5a9bd01da4f003ea/out/vs/workbench/api/node/extensionHostProcess.js:144:53500)\n```","author":{"url":"https://github.com/kubajanusz","@type":"Person","name":"kubajanusz"},"datePublished":"2026-02-18T16:11:14Z","url":"https://github.com/github/github-mcp-server/issues/2041"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:ad7a2de1-c3a1-e14c-7366-b4295f11caf4
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-id808A:333887:426FFB:5B2C64:6B068581
html-safe-nonce5442795f272cd60ededce48424e12783a09fbb1969aee15836804036f6a1bc00
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MDhBOjMzMzg4Nzo0MjZGRkI6NUIyQzY0OjZCMDY4NTgxIiwidmlzaXRvcl9pZCI6IjI4MzAzNTYyNzg4NzY5MTEzNyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac0cc629a6644e7bb4b16198a8281558591ff8a6960511b2cef9a6ab06148d5afe
hovercard-subject-tagissue:3958626972
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/github/github-mcp-server/2041/issue_layout
twitter:imagehttps://opengraph.githubassets.com/694275633d846ce8dab664be0eda31f83ec46788facbc8d4ae8b27d26f862a00/github/github-mcp-server/issues/2041
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/694275633d846ce8dab664be0eda31f83ec46788facbc8d4ae8b27d26f862a00/github/github-mcp-server/issues/2041
og:image:altDescribe the bug get_file_contents tool fails when you try to obtain file which is empty (0 bytes) Affected version Latest and GitHub managed MCP server Steps to reproduce the behavior Example repo...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamekubajanusz
hostnamegithub.com
expected-hostnamegithub.com
None4462ff7ebfd3d551f202659f2423dae617b6849d23b1df6465dc504ef497d14a
turbo-cache-controlno-preview
go-importgithub.com/github/github-mcp-server git https://github.com/github/github-mcp-server.git
octolytics-dimension-user_id9919
octolytics-dimension-user_logingithub
octolytics-dimension-repository_id942771284
octolytics-dimension-repository_nwogithub/github-mcp-server
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id942771284
octolytics-dimension-repository_network_root_nwogithub/github-mcp-server
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
release6d3909414814ff86ce7da4c51a0f4918a13fb41b
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/github/github-mcp-server/issues/2041#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgithub%2Fgithub-mcp-server%2Fissues%2F2041
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
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
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://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
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fgithub%2Fgithub-mcp-server%2Fissues%2F2041
Sign uphttps://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=github%2Fgithub-mcp-server
Reloadhttps://github.com/github/github-mcp-server/issues/2041
Reloadhttps://github.com/github/github-mcp-server/issues/2041
Reloadhttps://github.com/github/github-mcp-server/issues/2041
githubhttps://github.com/github
github-mcp-serverhttps://github.com/github/github-mcp-server
Codehttps://github.com/github/github-mcp-server
Issues238 (238)https://github.com/github/github-mcp-server/issues
Pull requests228 (228)https://github.com/github/github-mcp-server/pulls
Discussionshttps://github.com/github/github-mcp-server/discussions
Actionshttps://github.com/github/github-mcp-server/actions
Security and quality2 (2)https://github.com/github/github-mcp-server/security
Insightshttps://github.com/github/github-mcp-server/insights
https://github.com/github/github-mcp-server
New issuehttps://github.com/login?return_to=https://github.com/github/github-mcp-server/issues/2041
New issuehttps://github.com/login?return_to=https://github.com/github/github-mcp-server/issues/2041
#2042https://github.com/github/github-mcp-server/pull/2042
Unable to obtain empty file from git repo via MCPhttps://github.com/github/github-mcp-server/issues/2041#top
#2042https://github.com/github/github-mcp-server/pull/2042
bughttps://github.com/github/github-mcp-server/issues?q=state%3Aopen%20label%3A%22bug%22
https://github.com/kubajanusz
kubajanuszhttps://github.com/kubajanusz
on Feb 18, 2026https://github.com/github/github-mcp-server/issues/2041#issue-3958626972
https://github.com/kubajanusz/mcp-404-and-tag-errors-examplehttps://github.com/kubajanusz/mcp-404-and-tag-errors-example
https://private-user-images.githubusercontent.com/32165716/551638708-09e1d6df-9011-4914-a5da-6a832fcf26d5.png?jwt=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3OTU1ODk4MDYsIm5iZiI6MTc5NTU4OTUwNiwicGF0aCI6Ii8zMjE2NTcxNi81NTE2Mzg3MDgtMDllMWQ2ZGYtOTAxMS00OTE0LWE1ZGEtNmE4MzJmY2YyNmQ1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNjExMjUlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjYxMTI1VDA2NTE0NlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPWMwZWE5NjE0YWFmNzZlZWJmMmI5OWZmMjhkYzM5MjEwYzlmZDhjNWExYjQ3M2JkNDRiYmU0OWQyY2U4OWMyNDUmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JnJlc3BvbnNlLWNvbnRlbnQtdHlwZT1pbWFnZSUyRnBuZyJ9._K86IgLY0RTnvnFMM0DEzxOsM62onu6E5KcgEVH3ccE
kubajanuszhttps://github.com/kubajanusz
bughttps://github.com/github/github-mcp-server/issues?q=state%3Aopen%20label%3A%22bug%22
on Feb 18, 2026https://github.com/github/github-mcp-server/issues/2041#event-22889126537
github-actionshttps://github.com/apps/github-actions
request ai reviewhttps://github.com/github/github-mcp-server/issues?q=state%3Aopen%20label%3A%22request%20ai%20review%22
on Feb 18, 2026https://github.com/github/github-mcp-server/issues/2041#event-22889130431
https://github.com/kubajanusz
kubajanuszhttps://github.com/kubajanusz
on Feb 18, 2026https://github.com/github/github-mcp-server/issues/2041#issuecomment-3921807974
#2042https://github.com/github/github-mcp-server/pull/2042
almaleksiahttps://github.com/almaleksia
completedhttps://github.com/github/github-mcp-server/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#2042https://github.com/github/github-mcp-server/pull/2042
on Mar 4, 2026https://github.com/github/github-mcp-server/issues/2041#event-23263137594
Sign up for freehttps://github.com/signup?return_to=https://github.com/github/github-mcp-server/issues/2041
Sign in to commenthttps://github.com/login?return_to=https://github.com/github/github-mcp-server/issues/2041
bughttps://github.com/github/github-mcp-server/issues?q=state%3Aopen%20label%3A%22bug%22
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

Response headers:
Servergithub.com
Content-Typetext/html; charset=utf-8
Cache-Controlmax-age=0, private, must-revalidate

Viewport: width=device-width


URLs of crawlers that visited me.