{"action":"opened","number":10204,"pull_request":{"url":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204","id":177244457,"html_url":"https://github.com/MarlinFirmware/Marlin/pull/10204","diff_url":"https://github.com/MarlinFirmware/Marlin/pull/10204.diff","patch_url":"https://github.com/MarlinFirmware/Marlin/pull/10204.patch","issue_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/10204","number":10204,"state":"open","locked":false,"title":"Force checksum when writing to sd","user":{"login":"adriancuzman","id":893560,"avatar_url":"https://avatars1.githubusercontent.com/u/893560?v=4","gravatar_id":"","url":"https://api.github.com/users/adriancuzman","html_url":"https://github.com/adriancuzman","followers_url":"https://api.github.com/users/adriancuzman/followers","following_url":"https://api.github.com/users/adriancuzman/following{/other_user}","gists_url":"https://api.github.com/users/adriancuzman/gists{/gist_id}","starred_url":"https://api.github.com/users/adriancuzman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriancuzman/subscriptions","organizations_url":"https://api.github.com/users/adriancuzman/orgs","repos_url":"https://api.github.com/users/adriancuzman/repos","events_url":"https://api.github.com/users/adriancuzman/events{/privacy}","received_events_url":"https://api.github.com/users/adriancuzman/received_events","type":"User","site_admin":false},"body":"### Description\r\n\r\nI worked on using XON/XOFF to send files from Octoprint and found that if errors occur (resend commands) some invalid data that is still in the RX buffer will be accepted as commands without checksum and will be written in the file. The problem is that if the data that comes from the RX buffer doesn't start with N it's considered a command and it will be queued and written to the file (commands that don't have the line number, but have the checksum, the '*' and the checksum are written in the file). I haven't tested how these incomplete commands are actually executed, but this could be a problem in the future. One solution for this is to accept only commands with checksum when saving to a file. This is more like a bug report + a possible solution, maybe not the correct one. \r\n\r\n### Benefits\r\n\r\nWhen saving a file to SD with XON/XOFF enabled and RX errors occur, the file will be written without invalid commands.\r\n","created_at":"2018-03-24T16:04:02Z","updated_at":"2018-03-24T16:04:02Z","closed_at":null,"merged_at":null,"merge_commit_sha":null,"assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204/commits","review_comments_url":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204/comments","review_comment_url":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/comments{/number}","comments_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/10204/comments","statuses_url":"https://api.github.com/repos/MarlinFirmware/Marlin/statuses/30c3146f72cf8c5fef1ed4b83545558afc903601","head":{"label":"adriancuzman:force_checksum","ref":"force_checksum","sha":"30c3146f72cf8c5fef1ed4b83545558afc903601","user":{"login":"adriancuzman","id":893560,"avatar_url":"https://avatars1.githubusercontent.com/u/893560?v=4","gravatar_id":"","url":"https://api.github.com/users/adriancuzman","html_url":"https://github.com/adriancuzman","followers_url":"https://api.github.com/users/adriancuzman/followers","following_url":"https://api.github.com/users/adriancuzman/following{/other_user}","gists_url":"https://api.github.com/users/adriancuzman/gists{/gist_id}","starred_url":"https://api.github.com/users/adriancuzman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriancuzman/subscriptions","organizations_url":"https://api.github.com/users/adriancuzman/orgs","repos_url":"https://api.github.com/users/adriancuzman/repos","events_url":"https://api.github.com/users/adriancuzman/events{/privacy}","received_events_url":"https://api.github.com/users/adriancuzman/received_events","type":"User","site_admin":false},"repo":{"id":113621712,"name":"Marlin","full_name":"adriancuzman/Marlin","owner":{"login":"adriancuzman","id":893560,"avatar_url":"https://avatars1.githubusercontent.com/u/893560?v=4","gravatar_id":"","url":"https://api.github.com/users/adriancuzman","html_url":"https://github.com/adriancuzman","followers_url":"https://api.github.com/users/adriancuzman/followers","following_url":"https://api.github.com/users/adriancuzman/following{/other_user}","gists_url":"https://api.github.com/users/adriancuzman/gists{/gist_id}","starred_url":"https://api.github.com/users/adriancuzman/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adriancuzman/subscriptions","organizations_url":"https://api.github.com/users/adriancuzman/orgs","repos_url":"https://api.github.com/users/adriancuzman/repos","events_url":"https://api.github.com/users/adriancuzman/events{/privacy}","received_events_url":"https://api.github.com/users/adriancuzman/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adriancuzman/Marlin","description":"Optimized firmware for RepRap 3D printers based on the Arduino platform.","fork":true,"url":"https://api.github.com/repos/adriancuzman/Marlin","forks_url":"https://api.github.com/repos/adriancuzman/Marlin/forks","keys_url":"https://api.github.com/repos/adriancuzman/Marlin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adriancuzman/Marlin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adriancuzman/Marlin/teams","hooks_url":"https://api.github.com/repos/adriancuzman/Marlin/hooks","issue_events_url":"https://api.github.com/repos/adriancuzman/Marlin/issues/events{/number}","events_url":"https://api.github.com/repos/adriancuzman/Marlin/events","assignees_url":"https://api.github.com/repos/adriancuzman/Marlin/assignees{/user}","branches_url":"https://api.github.com/repos/adriancuzman/Marlin/branches{/branch}","tags_url":"https://api.github.com/repos/adriancuzman/Marlin/tags","blobs_url":"https://api.github.com/repos/adriancuzman/Marlin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adriancuzman/Marlin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adriancuzman/Marlin/git/refs{/sha}","trees_url":"https://api.github.com/repos/adriancuzman/Marlin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adriancuzman/Marlin/statuses/{sha}","languages_url":"https://api.github.com/repos/adriancuzman/Marlin/languages","stargazers_url":"https://api.github.com/repos/adriancuzman/Marlin/stargazers","contributors_url":"https://api.github.com/repos/adriancuzman/Marlin/contributors","subscribers_url":"https://api.github.com/repos/adriancuzman/Marlin/subscribers","subscription_url":"https://api.github.com/repos/adriancuzman/Marlin/subscription","commits_url":"https://api.github.com/repos/adriancuzman/Marlin/commits{/sha}","git_commits_url":"https://api.github.com/repos/adriancuzman/Marlin/git/commits{/sha}","comments_url":"https://api.github.com/repos/adriancuzman/Marlin/comments{/number}","issue_comment_url":"https://api.github.com/repos/adriancuzman/Marlin/issues/comments{/number}","contents_url":"https://api.github.com/repos/adriancuzman/Marlin/contents/{+path}","compare_url":"https://api.github.com/repos/adriancuzman/Marlin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adriancuzman/Marlin/merges","archive_url":"https://api.github.com/repos/adriancuzman/Marlin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adriancuzman/Marlin/downloads","issues_url":"https://api.github.com/repos/adriancuzman/Marlin/issues{/number}","pulls_url":"https://api.github.com/repos/adriancuzman/Marlin/pulls{/number}","milestones_url":"https://api.github.com/repos/adriancuzman/Marlin/milestones{/number}","notifications_url":"https://api.github.com/repos/adriancuzman/Marlin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adriancuzman/Marlin/labels{/name}","releases_url":"https://api.github.com/repos/adriancuzman/Marlin/releases{/id}","deployments_url":"https://api.github.com/repos/adriancuzman/Marlin/deployments","created_at":"2017-12-08T22:07:23Z","updated_at":"2017-12-08T22:07:28Z","pushed_at":"2018-03-24T15:49:38Z","git_url":"git://github.com/adriancuzman/Marlin.git","ssh_url":"git@github.com:adriancuzman/Marlin.git","clone_url":"https://github.com/adriancuzman/Marlin.git","svn_url":"https://github.com/adriancuzman/Marlin","homepage":"http://www.marlinfw.org/","size":60244,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"1.1.x"}},"base":{"label":"MarlinFirmware:bugfix-1.1.x","ref":"bugfix-1.1.x","sha":"f62ec5b1580cce03d21afb3e2ead2194d87eb2bc","user":{"login":"MarlinFirmware","id":10418365,"avatar_url":"https://avatars3.githubusercontent.com/u/10418365?v=4","gravatar_id":"","url":"https://api.github.com/users/MarlinFirmware","html_url":"https://github.com/MarlinFirmware","followers_url":"https://api.github.com/users/MarlinFirmware/followers","following_url":"https://api.github.com/users/MarlinFirmware/following{/other_user}","gists_url":"https://api.github.com/users/MarlinFirmware/gists{/gist_id}","starred_url":"https://api.github.com/users/MarlinFirmware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarlinFirmware/subscriptions","organizations_url":"https://api.github.com/users/MarlinFirmware/orgs","repos_url":"https://api.github.com/users/MarlinFirmware/repos","events_url":"https://api.github.com/users/MarlinFirmware/events{/privacy}","received_events_url":"https://api.github.com/users/MarlinFirmware/received_events","type":"Organization","site_admin":false},"repo":{"id":2200856,"name":"Marlin","full_name":"MarlinFirmware/Marlin","owner":{"login":"MarlinFirmware","id":10418365,"avatar_url":"https://avatars3.githubusercontent.com/u/10418365?v=4","gravatar_id":"","url":"https://api.github.com/users/MarlinFirmware","html_url":"https://github.com/MarlinFirmware","followers_url":"https://api.github.com/users/MarlinFirmware/followers","following_url":"https://api.github.com/users/MarlinFirmware/following{/other_user}","gists_url":"https://api.github.com/users/MarlinFirmware/gists{/gist_id}","starred_url":"https://api.github.com/users/MarlinFirmware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarlinFirmware/subscriptions","organizations_url":"https://api.github.com/users/MarlinFirmware/orgs","repos_url":"https://api.github.com/users/MarlinFirmware/repos","events_url":"https://api.github.com/users/MarlinFirmware/events{/privacy}","received_events_url":"https://api.github.com/users/MarlinFirmware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MarlinFirmware/Marlin","description":"Optimized firmware for RepRap 3D printers based on the Arduino platform.","fork":false,"url":"https://api.github.com/repos/MarlinFirmware/Marlin","forks_url":"https://api.github.com/repos/MarlinFirmware/Marlin/forks","keys_url":"https://api.github.com/repos/MarlinFirmware/Marlin/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MarlinFirmware/Marlin/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MarlinFirmware/Marlin/teams","hooks_url":"https://api.github.com/repos/MarlinFirmware/Marlin/hooks","issue_events_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/events{/number}","events_url":"https://api.github.com/repos/MarlinFirmware/Marlin/events","assignees_url":"https://api.github.com/repos/MarlinFirmware/Marlin/assignees{/user}","branches_url":"https://api.github.com/repos/MarlinFirmware/Marlin/branches{/branch}","tags_url":"https://api.github.com/repos/MarlinFirmware/Marlin/tags","blobs_url":"https://api.github.com/repos/MarlinFirmware/Marlin/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MarlinFirmware/Marlin/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MarlinFirmware/Marlin/git/refs{/sha}","trees_url":"https://api.github.com/repos/MarlinFirmware/Marlin/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MarlinFirmware/Marlin/statuses/{sha}","languages_url":"https://api.github.com/repos/MarlinFirmware/Marlin/languages","stargazers_url":"https://api.github.com/repos/MarlinFirmware/Marlin/stargazers","contributors_url":"https://api.github.com/repos/MarlinFirmware/Marlin/contributors","subscribers_url":"https://api.github.com/repos/MarlinFirmware/Marlin/subscribers","subscription_url":"https://api.github.com/repos/MarlinFirmware/Marlin/subscription","commits_url":"https://api.github.com/repos/MarlinFirmware/Marlin/commits{/sha}","git_commits_url":"https://api.github.com/repos/MarlinFirmware/Marlin/git/commits{/sha}","comments_url":"https://api.github.com/repos/MarlinFirmware/Marlin/comments{/number}","issue_comment_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/comments{/number}","contents_url":"https://api.github.com/repos/MarlinFirmware/Marlin/contents/{+path}","compare_url":"https://api.github.com/repos/MarlinFirmware/Marlin/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MarlinFirmware/Marlin/merges","archive_url":"https://api.github.com/repos/MarlinFirmware/Marlin/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MarlinFirmware/Marlin/downloads","issues_url":"https://api.github.com/repos/MarlinFirmware/Marlin/issues{/number}","pulls_url":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls{/number}","milestones_url":"https://api.github.com/repos/MarlinFirmware/Marlin/milestones{/number}","notifications_url":"https://api.github.com/repos/MarlinFirmware/Marlin/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MarlinFirmware/Marlin/labels{/name}","releases_url":"https://api.github.com/repos/MarlinFirmware/Marlin/releases{/id}","deployments_url":"https://api.github.com/repos/MarlinFirmware/Marlin/deployments","created_at":"2011-08-13T08:07:20Z","updated_at":"2018-03-24T13:59:51Z","pushed_at":"2018-03-24T15:20:42Z","git_url":"git://github.com/MarlinFirmware/Marlin.git","ssh_url":"git@github.com:MarlinFirmware/Marlin.git","clone_url":"https://github.com/MarlinFirmware/Marlin.git","svn_url":"https://github.com/MarlinFirmware/Marlin","homepage":"http://www.marlinfw.org/","size":68898,"stargazers_count":3579,"watchers_count":3579,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5302,"mirror_url":null,"archived":false,"open_issues_count":469,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":5302,"open_issues":469,"watchers":3579,"default_branch":"1.1.x"}},"_links":{"self":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204"},"html":{"href":"https://github.com/MarlinFirmware/Marlin/pull/10204"},"issue":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/10204"},"comments":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/issues/10204/comments"},"review_comments":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204/comments"},"review_comment":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/pulls/10204/commits"},"statuses":{"href":"https://api.github.com/repos/MarlinFirmware/Marlin/statuses/30c3146f72cf8c5fef1ed4b83545558afc903601"}},"author_association":"NONE","merged":false,"mergeable":null,"rebaseable":null,"mergeable_state":"unknown","merged_by":null,"comments":0,"review_comments":0,"maintainer_can_modify":true,"commits":1,"additions":19,"deletions":0,"changed_files":2}}
{"actor":{"display_login":"adriancuzman"}}