Skip to content

add 3d-print docs #90

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 24 commits into
base: dev
Choose a base branch
from
Draft

add 3d-print docs #90

wants to merge 24 commits into from

Conversation

goldfishlaser
Copy link
Member

create file based on storage.rst to start working on 3d printed buskill installation instructions

@goldfishlaser
Copy link
Member Author

@maltfield I'm not sure what's going on here can you check on it?

goldfishlaser

This comment was marked as resolved.

@maltfield
Copy link
Member

@goldfishlaser what do you want me to check-on?

@goldfishlaser
Copy link
Member Author

goldfishlaser commented Aug 7, 2024 via email

@maltfield
Copy link
Member

@maltfield
Copy link
Member

maltfield commented Aug 7, 2024

I think I've fixed the (malicious) unicode checker workflow. I think it was an issue with new github actions permissions and also the new safe.directory git config that was breaking the diff. For more info, see:

@maltfield
Copy link
Member

I also added some better error codes and some better ways to trigger it to re-run. One thing that'll cause it to re-run is by unlocking a PR, so I'm going to toggle that to force it to re-run on this PR.

@BusKill BusKill locked and limited conversation to collaborators Aug 7, 2024
@BusKill BusKill unlocked this conversation Aug 7, 2024
maltfield added a commit that referenced this pull request Aug 7, 2024
This commit attempts to update the (malicious) unicode detection workflow to fix an error on diff

 * #90
 * https://github.com/BusKill/buskill-app/actions/runs/10290611003/job/28481143563?pr=90

  2024-08-07T19:38:13.0639703Z + git branch -a
  2024-08-07T19:38:13.0661153Z * master
  2024-08-07T19:38:13.0662070Z   remotes/origin/HEAD -> origin/master
  2024-08-07T19:38:13.0662923Z   remotes/origin/dev
  2024-08-07T19:38:13.0663562Z   remotes/origin/font_setting
  2024-08-07T19:38:13.0664273Z   remotes/origin/gh-pages
  2024-08-07T19:38:13.0665072Z   remotes/origin/master
  2024-08-07T19:38:13.0665603Z   remotes/origin/v0.1.0
  2024-08-07T19:38:13.0666164Z   remotes/origin/v0.2.0
  2024-08-07T19:38:13.0666849Z   remotes/origin/v0.2.1
  2024-08-07T19:38:13.0667376Z   remotes/origin/v0.3.0
  2024-08-07T19:38:13.0667958Z   remotes/origin/v0.3.1
  2024-08-07T19:38:13.0668493Z   remotes/origin/v0.4.0
  2024-08-07T19:38:13.0668961Z   remotes/origin/v0.5.0
  2024-08-07T19:38:13.0669349Z   remotes/origin/v0.6.0
  2024-08-07T19:38:13.0670119Z   remotes/origin/v0.7.0
  ...
  2024-08-07T19:38:13.1733843Z ++ git diff --unified=0 924ca98 43dfed1
  2024-08-07T19:38:13.1734022Z ++ grep -Ev '^(--- a/|\+\+\+ b/)'
  2024-08-07T19:38:13.1734246Z fatal: bad object 43dfed1
  2024-08-07T19:38:13.1734418Z ++ grep -E '^[+]'
  2024-08-07T19:38:13.1734545Z + diff=
  2024-08-07T19:38:13.1734685Z + '[' 1 -ne 0 ']'
  2024-08-07T19:38:13.1734986Z + human_result='WARNING: git diff failed!'
  2024-08-07T19:38:13.1735154Z + echo 'WARNING: git diff failed!'
  2024-08-07T19:38:13.1735292Z + exit 1

Since it says there was a "bad object" -- let's try changing to the correct branch first
@BusKill BusKill locked and limited conversation to collaborators Aug 7, 2024
@BusKill BusKill unlocked this conversation Aug 7, 2024
maltfield added a commit that referenced this pull request Aug 7, 2024
I'm hoping that when Melanie pushes a new change, it'll "just work". We'll seee

 * #90
@maltfield
Copy link
Member

looks like I can't trigger it on my end because it can't find Melanie's commit, which causes the diff to fail.

@goldfishlaser can you please push a trivial commit (just a newline or something) to see if the unicode_warn workflow works?

@maltfield
Copy link
Member

maltfield added a commit to maltfield/detect-malicious-unicode that referenced this pull request Aug 8, 2024
This commit adds some debugging (to print the full JSON github context vars) and attempts to checkout the head ref before attempting to do a diff. Hopefully this will fix issues of "object not found" because the diff is currently being done in the repo's default branch (main or master), but that won't work if the PR is being submitted to a different branch (eg 'dev') or, maybe, if the PR is being submitted from a different branch.

See also

 * https://stackoverflow.com/questions/70104600/complete-list-of-github-actions-contexts
 * #4
 * BusKill/buskill-app#90 (comment)
@BusKill BusKill locked and limited conversation to collaborators Aug 8, 2024
@BusKill BusKill unlocked this conversation Aug 8, 2024
maltfield added a commit to maltfield/detect-malicious-unicode that referenced this pull request Aug 8, 2024
This commit tries to fix a logic error where we `exit 1` if the diff or hd fails, but then the next step gets an empty env.UNICODE_HUMAN_RESULT and tries to write a comment to the PR with the empty string because I never appended it to the $GITHUB_ENV

 * BusKill/buskill-app#90 (comment)
 * https://github.com/BusKill/buskill-app/actions/runs/10306695941/job/28530322900?pr=90

2024-08-08T17:27:50.2608516Z WARNING: git diff failed!
2024-08-08T17:27:50.2611926Z ##[error]Process completed with exit code 1.
2024-08-08T17:27:50.2711200Z ##[group]Run actions/github-script@v5
2024-08-08T17:27:50.2711316Z with:
2024-08-08T17:27:50.2711670Z   github-token: ***
2024-08-08T17:27:50.2712275Z   script: github.rest.issues.createComment({
  issue_number: context.issue.number,
  owner: context.repo.owner,
  repo: context.repo.repo,
  body: ""
})

2024-08-08T17:27:50.2712365Z   debug: false
2024-08-08T17:27:50.2712473Z   user-agent: actions/github-script
2024-08-08T17:27:50.2712574Z   result-encoding: json
2024-08-08T17:27:50.2712881Z ##[endgroup]
2024-08-08T17:27:50.2812599Z ##[command]/usr/bin/docker exec  00316d800580718912b39a396d50ab0a80e9ce5a35ce56b9056c7315a6a097ca sh -c "cat /etc/*release | grep ^ID"
2024-08-08T17:27:50.5779265Z (node:3062) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
2024-08-08T17:27:50.5781733Z (Use `node --trace-deprecation ...` to show where the warning was created)
2024-08-08T17:27:50.9059683Z RequestError [HttpError]: Validation Failed: {"resource":"IssueComment","code":"unprocessable","field":"data","message":"Body cannot be blank"}
2024-08-08T17:27:50.9061478Z     at /__w/_actions/actions/github-script/v5/dist/index.js:4560:21
2024-08-08T17:27:50.9062520Z     at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
2024-08-08T17:27:50.9063394Z   status: 422,
2024-08-08T17:27:50.9063760Z   response: {
2024-08-08T17:27:50.9064575Z     url: 'https://api.github.com/repos/BusKill/buskill-app/issues/90/comments',
2024-08-08T17:27:50.9065361Z     status: 422,
2024-08-08T17:27:50.9065747Z     headers: {
2024-08-08T17:27:50.9066254Z       'access-control-allow-origin': '*',
2024-08-08T17:27:50.9069389Z       'access-control-expose-headers': 'ETag, Link, Location, Retry-After, X-GitHub-OTP, X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Used, X-RateLimit-Resource, X-RateLimit-Reset, X-OAuth-Scopes, X-Accepted-OAuth-Scopes, X-Poll-Interval, X-GitHub-Media-Type, X-GitHub-SSO, X-GitHub-Request-Id, Deprecation, Sunset',
2024-08-08T17:27:50.9072239Z       'content-length': '247',
2024-08-08T17:27:50.9072941Z       'content-security-policy': "default-src 'none'",
2024-08-08T17:27:50.9073774Z       'content-type': 'application/json; charset=utf-8',
2024-08-08T17:27:50.9074524Z       date: 'Thu, 08 Aug 2024 17:27:50 GMT',
2024-08-08T17:27:50.9075535Z       'referrer-policy': 'origin-when-cross-origin, strict-origin-when-cross-origin',
2024-08-08T17:27:50.9076469Z       server: 'github.com',
2024-08-08T17:27:50.9077332Z       'strict-transport-security': 'max-age=31536000; includeSubdomains; preload',
2024-08-08T17:27:50.9078374Z       vary: 'Accept-Encoding, Accept, X-Requested-With',
2024-08-08T17:27:50.9079353Z       'x-accepted-github-permissions': 'issues=write; pull_requests=write',
2024-08-08T17:27:50.9080287Z       'x-content-type-options': 'nosniff',
2024-08-08T17:27:50.9080911Z       'x-frame-options': 'deny',
2024-08-08T17:27:50.9081560Z       'x-github-api-version-selected': '2022-11-28',
2024-08-08T17:27:50.9082282Z       'x-github-media-type': 'github.v3',
2024-08-08T17:27:50.9083482Z       'x-github-request-id': 'D080:6F0B2:17F711F0:2CB179B2:66B50016',
2024-08-08T17:27:50.9084363Z       'x-ratelimit-limit': '5000',
2024-08-08T17:27:50.9084980Z       'x-ratelimit-remaining': '4999',
2024-08-08T17:27:50.9085379Z       'x-ratelimit-reset': '1723141670',
2024-08-08T17:27:50.9085756Z       'x-ratelimit-resource': 'core',
2024-08-08T17:27:50.9086118Z       'x-ratelimit-used': '1',
2024-08-08T17:27:50.9086433Z       'x-xss-protection': '0'
2024-08-08T17:27:50.9086693Z     },
2024-08-08T17:27:50.9086878Z     data: {
2024-08-08T17:27:50.9087138Z       message: 'Validation Failed',
2024-08-08T17:27:50.9087440Z       errors: [Array],
2024-08-08T17:27:50.9088003Z       documentation_url: 'https://docs.github.com/rest/issues/comments#create-an-issue-comment',
2024-08-08T17:27:50.9088572Z       status: '422'
2024-08-08T17:27:50.9088795Z     }
2024-08-08T17:27:50.9089404Z   },
2024-08-08T17:27:50.9089613Z   request: {
2024-08-08T17:27:50.9089861Z     method: 'POST',
2024-08-08T17:27:50.9090326Z     url: 'https://api.github.com/repos/BusKill/buskill-app/issues/90/comments',
2024-08-08T17:27:50.9090796Z     headers: {
2024-08-08T17:27:50.9091318Z       accept: 'application/vnd.github.-preview+json',
2024-08-08T17:27:50.9092180Z       'user-agent': 'actions/github-script octokit-core.js/3.5.1 Node.js/20.13.1 (linux; x64)',
2024-08-08T17:27:50.9093346Z       authorization: 'token [REDACTED]',
2024-08-08T17:27:50.9093784Z       'content-type': 'application/json; charset=utf-8'
2024-08-08T17:27:50.9094130Z     },
2024-08-08T17:27:50.9094361Z     body: '{"body":""}',
2024-08-08T17:27:50.9094739Z     request: { agent: [Agent], hook: [Function: bound bound register] }
2024-08-08T17:27:50.9095138Z   }
2024-08-08T17:27:50.9095317Z }
2024-08-08T17:27:50.9100654Z ##[error]Unhandled error: HttpError: Validation Failed: {"resource":"IssueComment","code":"unprocessable","field":"data","message":"Body cannot be blank"}
@BusKill BusKill locked and limited conversation to collaborators Aug 8, 2024
@BusKill BusKill unlocked this conversation Aug 8, 2024
Copy link

github-actions bot commented Aug 8, 2024

WARNING: git diff failed!

maltfield added a commit to maltfield/detect-malicious-unicode that referenced this pull request Aug 8, 2024
 * BusKill/buskill-app#90 (comment)
 * https://github.com/BusKill/buskill-app/actions/runs/10306855519/job/28530828444?pr=90

  2024-08-08T17:39:22.5370542Z ##[group]Run if [[ "WARNING: git diff failed!" | grep -Ei "ERROR|WARNING" ]]; then
  2024-08-08T17:39:22.5371079Z [36;1m[0m
  2024-08-08T17:39:22.5371457Z [36;1mif [[ "WARNING: git diff failed!" | grep -Ei "ERROR|WARNING" ]]; then[0m
  2024-08-08T17:39:22.5371917Z [36;1m  exit 1[0m
  2024-08-08T17:39:22.5372141Z [36;1melse[0m
  2024-08-08T17:39:22.5372356Z [36;1m  exit 0[0m
  2024-08-08T17:39:22.5372651Z shell: bash {0}
  2024-08-08T17:39:22.5372864Z env:
  2024-08-08T17:39:22.5373114Z   UNICODE_HUMAN_RESULT: WARNING: git diff failed!
  2024-08-08T17:39:22.5373466Z ##[endgroup]
  2024-08-08T17:39:22.6145287Z /__w/_temp/8a48bf26-0dbe-4e74-bfec-9efb78fd13c5.sh: line 2: unexpected token `|', conditional binary operator expected
  2024-08-08T17:39:22.6147084Z /__w/_temp/8a48bf26-0dbe-4e74-bfec-9efb78fd13c5.sh: line 2: syntax error near `|'
  2024-08-08T17:39:22.6148958Z /__w/_temp/8a48bf26-0dbe-4e74-bfec-9efb78fd13c5.sh: line 2: `if [[ "WARNING: git diff failed!" | grep -Ei "ERROR|WARNING" ]]; then'
  2024-08-08T17:39:22.6172279Z ##[error]Process completed with exit code 2.
@maltfield
Copy link
Member

Update: Still working on fixing the unicode warning CI script. Good news is that I at least got better error reporting working; it left a comment above saying that the diff failed. Progress..

@BusKill BusKill locked and limited conversation to collaborators Aug 8, 2024
@maltfield
Copy link
Member

maltfield commented Apr 9, 2025

You're right there's a build error:

Run if [[ $(echo "INFO: No unicode characters found in PR's commits" | grep -Ei "ERROR|WARNING") ]]; then
/__w/_temp/7f0c1d6d-c102-4481-a10e-2364765da939.sh: line 6: syntax error: unexpected end of file
Error: Process completed with exit code 2.

But that's a syntax error; I think I'm missing the fi line at the end of that conditional. Sorry, that's my fault; it's not an issue for you. You can ignore it.

Thank you for bringing this to my attention.

maltfield added a commit that referenced this pull request Apr 9, 2025
Looks like builds were always failing, even when unicode wasn't found in the diff. I'm trying to fix this by adding the missing 'fi' at the end of the if statement.

 * #90 (comment)
@maltfield
Copy link
Member

I pushed a change to try to fix that syntax error:

maltfield added a commit to maltfield/detect-malicious-unicode that referenced this pull request Apr 9, 2025
Looks like builds were always failing, even when unicode wasn't found in the diff. I'm trying to fix this by adding the missing 'fi' at the end of the if statement.

 * BusKill/buskill-app#90 (comment)
@goldfishlaser goldfishlaser reopened this Apr 9, 2025
Copy link

github-actions bot commented Apr 9, 2025

INFO: No unicode characters found in PR's commits

(source)

Copy link

github-actions bot commented Apr 9, 2025

INFO: No unicode characters found in PR's commits

(source)

…bly instructions into parts, so I moved files and edited index files accordingly.
Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

@maltfield
Copy link
Member

maltfield commented Apr 11, 2025

I think I needed to add a line to the top of this file to make it like other docs

fyi, the reason you add that is to uniquely identify that file/page with a Hyperlink Reference

.. _3dphardware_dev:

Then you can use that identifier to link to that page from other parts of the documentation with a Hyperlink Target :ref:Custom Text <internal_anchor>``. Eg:

More info on reST links:

@goldfishlaser
Copy link
Member Author

goldfishlaser commented Apr 11, 2025

Appreciate that - I was expecting it was something like that but wasn't fully sure. :)

Can you remind me how I can see how my updates look in context of the built site? I thought it would be viewing the docs site from the dev branch, but that doesn't seem to be it? Thank you kindly~

@maltfield
Copy link
Member

The steps for building locally are here:

The docs itself have different branches, which are accessible by clicking the "Alternative Versions" button on the far bottom-left of the docs site, eg:

...but the latter is for tags, not unmerged PRs.

…t I may or may not have needed to make the file
Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

Copy link

INFO: No unicode characters found in PR's commits

(source)

…e parts as its own step and renamed steps procedures and renamed sections steps
Copy link

INFO: No unicode characters found in PR's commits

(source)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants