René's URL Explorer Experiment


Title: Issue · GitHub

Open Graph Title: Issue · managedcode/Storage

X Title: Issue · managedcode/Storage

Description: Storage library provides a universal interface for accessing and manipulating data in different cloud blob storage providers - Issue · managedcode/Storage

Open Graph Description: Storage library provides a universal interface for accessing and manipulating data in different cloud blob storage providers - Issue · managedcode/Storage

X Description: Storage library provides a universal interface for accessing and manipulating data in different cloud blob storage providers - Issue · managedcode/Storage

Opengraph URL: https://github.com/managedcode/Storage

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"FileSystemStorage provider doesn't overwrite files correctly","articleBody":"If, using a MemoryStream, I write a 90kB file with name \"testfile.bin\" and then try to write 512 bytes afterwards, I expect the file to be overwritten such that the new total length of the file is 512 bytes.\r\n\r\nInstead, this library only overwrites the first e.g. 512 bytes and the file remains 90kB big.\r\n\r\nPlease see test case below:\r\n\r\n```c#\r\nusing ManagedCode.Storage.Core.Models;\r\nusing ManagedCode.Storage.FileSystem;\r\nusing ManagedCode.Storage.FileSystem.Options;\r\nusing Xunit.Abstractions;\r\n\r\nnamespace StorageFsMre;\r\n\r\npublic class MinimumExampleTest(ITestOutputHelper output)\r\n{\r\n    [Fact]\r\n    public async Task TestOverwritingFile()\r\n    {\r\n        var fsStorage = new FileSystemStorage(new FileSystemStorageOptions\r\n        {\r\n            BaseFolder = \"/tmp/\"\r\n        });\r\n\r\n        var myMemoryStream1 = new MemoryStream(90*1024);\r\n        var buffer = new byte[90 * 1024];\r\n        var random = new Random();\r\n        random.NextBytes(buffer);\r\n        myMemoryStream1.Write(buffer, 0, buffer.Length);\r\n\r\n        // print them\r\n        foreach (var b in myMemoryStream1.GetBuffer())\r\n        {\r\n            output.WriteLine(b.ToString());\r\n        }\r\n\r\n        var result = await fsStorage.UploadAsync(myMemoryStream1, new UploadOptions\r\n        {\r\n            FileName = \"testfile.bin\",\r\n        }, CancellationToken.None);\r\n\r\n        Assert.True(result.IsSuccess);\r\n\r\n        var myMemoryStream2 = new MemoryStream(512);\r\n        // write 512 bytes of 0x00\r\n        myMemoryStream2.Write(new byte[512]);\r\n\r\n\r\n        await fsStorage.UploadAsync(myMemoryStream2, new UploadOptions\r\n        {\r\n            FileName = \"testfile.bin\",\r\n        }, CancellationToken.None);\r\n\r\n        // check if the file exists\r\n        var fileInfo = new FileInfo(\"/tmp/testfile.bin\");\r\n        Assert.True(fileInfo.Exists);\r\n\r\n        // check if the file has the correct size\r\n        Assert.Equal(512, fileInfo.Length);\r\n\r\n        // read the file in a new stream\r\n        var readStream = new MemoryStream();\r\n        using (var fileStream2 = fileInfo.OpenRead())\r\n        {\r\n            await fileStream2.CopyToAsync(readStream);\r\n        }\r\n\r\n        Assert.Equal(myMemoryStream2.ToArray(), readStream.ToArray());\r\n    }\r\n}\r\n```","author":{"url":"https://github.com/lol768","@type":"Person","name":"lol768"},"datePublished":"2024-07-31T11:48:42.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":3},"url":"https://github.com/98/Storage/issues/98"}

route-pattern/:user_id/:repository/issues/:id(.:format)
route-controllerissues
route-actionshow
fetch-noncev2:b8d67aa5-1e69-8ddc-6c96-19697da36571
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idD244:102756:591F71C:7DBE280:6A5000D7
html-safe-nonce450bc4d011383874a8d75bfce2d1cdda3b836b16cc13eda54d3dd5e7ee446758
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEMjQ0OjEwMjc1Njo1OTFGNzFDOjdEQkUyODA6NkE1MDAwRDciLCJ2aXNpdG9yX2lkIjoiMzY0NDk3NjM5MTg0MDA3MTg5NiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmacc86a53c8e7383a27abe67ac3d96a2f321d27437429ae00c2052c73c677686a18
hovercard-subject-tagrepository:357467863
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///issues/show
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/managedcode/Storage/issues/98
twitter:imagehttps://opengraph.githubassets.com/81e852213210fdf4e37bc04a23a0c66b9d1e5015ae2e6a4ec3ee941584b85c8f/managedcode/Storage
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/81e852213210fdf4e37bc04a23a0c66b9d1e5015ae2e6a4ec3ee941584b85c8f/managedcode/Storage
og:image:altStorage library provides a universal interface for accessing and manipulating data in different cloud blob storage providers - Issue · managedcode/Storage
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
hostnamegithub.com
expected-hostnamegithub.com
None56eec25a3430492dd6ec2a480eb33256a0da5192d5714b0db4f5ab5f33203d94
turbo-cache-controlno-cache
go-importgithub.com/managedcode/Storage git https://github.com/managedcode/Storage.git
octolytics-dimension-user_id78253589
octolytics-dimension-user_loginmanagedcode
octolytics-dimension-repository_id357467863
octolytics-dimension-repository_nwomanagedcode/Storage
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id357467863
octolytics-dimension-repository_network_root_nwomanagedcode/Storage
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
releasee155b8a71f9284454f73118dfe5e634e74f7afb3
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/managedcode/Storage/issues/98#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fmanagedcode%2FStorage%2Fissues%2F98
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
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%2Fmanagedcode%2FStorage%2Fissues%2F98
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%2Fissues%2Fshow&source=header-repo&source_repo=managedcode%2FStorage
Reloadhttps://github.com/managedcode/Storage/issues/98
Reloadhttps://github.com/managedcode/Storage/issues/98
Reloadhttps://github.com/managedcode/Storage/issues/98
Please reload this pagehttps://github.com/managedcode/Storage/issues/98
managedcode https://github.com/managedcode
Storagehttps://github.com/managedcode/Storage
Notifications https://github.com/login?return_to=%2Fmanagedcode%2FStorage
Fork 28 https://github.com/login?return_to=%2Fmanagedcode%2FStorage
Star 135 https://github.com/login?return_to=%2Fmanagedcode%2FStorage
Code https://github.com/managedcode/Storage
Issues 9 https://github.com/managedcode/Storage/issues
Pull requests 0 https://github.com/managedcode/Storage/pulls
Actions https://github.com/managedcode/Storage/actions
Models https://github.com/managedcode/Storage/models
Security and quality 0 https://github.com/managedcode/Storage/security
Insights https://github.com/managedcode/Storage/pulse
Code https://github.com/managedcode/Storage
Issues https://github.com/managedcode/Storage/issues
Pull requests https://github.com/managedcode/Storage/pulls
Actions https://github.com/managedcode/Storage/actions
Models https://github.com/managedcode/Storage/models
Security and quality https://github.com/managedcode/Storage/security
Insights https://github.com/managedcode/Storage/pulse
FileSystemStorage provider doesn't overwrite files correctlyhttps://github.com/managedcode/Storage/issues/98#top
https://github.com/lol768
lol768https://github.com/lol768
on Jul 31, 2024https://github.com/managedcode/Storage/issues/98#issue-2439853218
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.