{"id":61,"date":"2022-04-13T18:09:01","date_gmt":"2022-04-13T18:09:01","guid":{"rendered":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/?p=61"},"modified":"2022-04-13T18:57:03","modified_gmt":"2022-04-13T18:57:03","slug":"good-bones","status":"publish","type":"post","link":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/2022\/04\/13\/good-bones\/","title":{"rendered":"Good bones!"},"content":{"rendered":"\n<p>This week has been quite a refresher. I went through old material from a previous class, CS 340 Introduction to Databases, and the Flask documentation tutorial. &nbsp;A few months back I did create my own Flask web app, so I also took a look at that as well. It was actually really fun looking back at my previous work. It was my first time ever using Flask so I can see it was a bit cluttered and not very organized.<\/p>\n\n\n\n<p>The main goal I had this week was to complete the structure and layout of our project. I wanted to get it uploaded to GitHub early on. Having a good skeleton code will make sure everyone has the same starting point and does not have to worry too much about organization and merge conflicts.<\/p>\n\n\n\n<p>I followed the layout structure provided in the Flask tutorial <a rel=\"noreferrer noopener\" href=\"https:\/\/flask.palletsprojects.com\/en\/2.1.x\/tutorial\/layout\/\" data-type=\"URL\" data-id=\"https:\/\/flask.palletsprojects.com\/en\/2.1.x\/tutorial\/layout\/\" target=\"_blank\">here<\/a>.<\/p>\n\n\n\n<p> <\/p>\n\n\n\n<figure class=\"wp-block-image size-full is-resized\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/tutorial-structure-1.png\" alt=\"\" class=\"wp-image-66\" width=\"467\" height=\"643\" srcset=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/tutorial-structure-1.png 467w, https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/tutorial-structure-1-218x300.png 218w\" sizes=\"auto, (max-width: 467px) 100vw, 467px\" \/><figcaption>Project layout from Flask documentation<\/figcaption><\/figure>\n\n\n\n<p>My layout looks similar but I modified it slightly<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"458\" height=\"817\" src=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/jobtracker-structure-1.png\" alt=\"\" class=\"wp-image-67\" srcset=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/jobtracker-structure-1.png 458w, https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/jobtracker-structure-1-168x300.png 168w\" sizes=\"auto, (max-width: 458px) 100vw, 458px\" \/><figcaption>My project structure<\/figcaption><\/figure>\n\n\n\n<p>Creating this tree-like structure was done using the command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$Tree \/F &gt; output.txt<\/pre>\n\n\n\n<p>As a team, we wanted to implement features to make our codebase more robust, but let me tell you, GitHub actions and workflows were really annoying me this week! More specifically the linter. Because I created so many files, there were linting issues on a few of them. It was silly things like having an extra line or having spaces on a line. &nbsp;The feeling of finally getting that green circle made all the struggles worth it though!<\/p>\n\n\n\n<p>The other thing was to make sure all of the tests in our test folder ran. This was also so satisfying to figure out. Python unittest has a way to do this with it\u2019s discover functionality. Here is the command:<\/p>\n\n\n\n<pre class=\"wp-block-preformatted\">$python -m unittest discover tests \"*tests.py\"<\/pre>\n\n\n\n<p>What this does is it will &#8216;discover&#8217; a folder called tests and run files that have tests.py in the name. <\/p>\n\n\n\n<p>Overall, this was a busy week for me but with it, I feel I was able to improve and feel my efforts will set up our group for success!<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"932\" height=\"910\" src=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/figured-it-out-1.png\" alt=\"\" class=\"wp-image-83\" srcset=\"https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/figured-it-out-1.png 932w, https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/figured-it-out-1-300x293.png 300w, https:\/\/osu-wams-blogs-uploads.s3.amazonaws.com\/blogs.dir\/5417\/files\/2022\/04\/figured-it-out-1-768x750.png 768w\" sizes=\"auto, (max-width: 932px) 100vw, 932px\" \/><figcaption>Finally got that green circle!<\/figcaption><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>This week has been quite a refresher. I went through old material from a previous class, CS 340 Introduction to Databases, and the Flask documentation tutorial. &nbsp;A few months back I did create my own Flask web app, so I also took a look at that as well. It was actually really fun looking back [&hellip;]<\/p>\n","protected":false},"author":12178,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-61","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/posts\/61","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/users\/12178"}],"replies":[{"embeddable":true,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/comments?post=61"}],"version-history":[{"count":18,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/posts\/61\/revisions"}],"predecessor-version":[{"id":85,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/posts\/61\/revisions\/85"}],"wp:attachment":[{"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/media?parent=61"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/categories?post=61"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blogs.oregonstate.edu\/projectacuarioj\/wp-json\/wp\/v2\/tags?post=61"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}