Skip to content

Commit

Permalink
feat: fixing unlike function and comment count (#323)
Browse files Browse the repository at this point in the history
* chore(deps): update dependency constructs to v10.0.70 (#138)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.71 (#145)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update pnpm/action-setup action to v2.2.0 (#142)

Co-authored-by: Renovate Bot <[email protected]>

* feat: lambda for put-timetable (#144)

* feat: lambda for put-timetable

* deleted newline for put-timetable.

* changed file name for consistency

* chore(deps): update actions/setup-node action to v3 (#148)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update pnpm/action-setup action to v2.2.1 (#147)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.72 (#146)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.12.1 (#143)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.14.0 (#133)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.74 (#150)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency eslint to v8.10.0 (#149)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency typescript to v4.6.2 (#153)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.15.0 (#154)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.75 (#152)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency ts-node to v10.6.0 (#155)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update actions/checkout action to v3 (#156)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.13.0 (#151)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.76 (#157)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.77 (#158)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.79 (#159)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.14.0 (#162)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency ts-node to v10.7.0 (#161)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.81 (#160)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.82 (#163)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.83 (#164)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.16.0 (#168)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update endbug/add-and-commit action to v9 (#167)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency @commitlint/cli to v16.2.3 (#170)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.15.0 (#169)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.90 (#165)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update peter-evans/find-comment action to v2 (#175)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update peter-evans/create-or-update-comment action to v2 (#174)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.17.0 (#171)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.92 (#172)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.16.0 (#173)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency eslint-import-resolver-typescript to v2.7.0 (#176)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.19.0 (#183)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.17.0 (#182)

Co-authored-by: Renovate Bot <[email protected]>

* feat: api for put-timetable lambda. (#179)

* feat: api for put-timetable lambda.

* feat: fixed syntax errors

* feat: fixed syntax error (2)

* chore(deps): update dependencies

* chore: add lint-staged

* chore(deps): update codecov/codecov-action action to v3 (#186)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update amannn/action-semantic-pull-request action to v4.3.0 (#189)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.22.0

* chore(deps): update github/codeql-action action to v2 (#192)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update amannn/action-semantic-pull-request action to v4.4.0 (#190)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependencies

* chore(deps): update amannn/action-semantic-pull-request action to v4.5.0

* chore(deps): update dependency husky to v8

* chore(deps): update dependency @commitlint/cli to v16.3.0

* chore(deps): update dependency standard-version to v9.5.0

* chore(deps): update aws-cdk monorepo to v2.27.0

* chore(deps): update dependency ts-jest to v28.0.4

* chore(deps): update dependency eslint to v8.17.0

* chore(deps): update dependency ts-node to v10.8.1

* chore(deps): update typescript-eslint monorepo to v5.27.1

* chore(deps): update jest monorepo

* chore(deps): update dependency constructs to v10.1.32

* chore(deps): update dependencies

* chore(deps): update pnpm/action-setup action to v2.2.2

* chore(deps): update dependency typescript to v4.7.3

* chore(deps): update dependencies

* f:added Put method into default Headers for new api function put-timetable (#216)

* feat: updated pnpm-lock file to latest

* feat: uploading updated package file

* feat: updating package-lock file

* fix: modified jest config file

* fix: update jest config

* fix: configured rest api settings  (#221)

* fix: config rest api

* fix: update jest config

* fix: jest types

* fix: update pnpm lock

* fix: deleted package-lock

* feat: creating only database and not API (#225)

* f:added Put method into default Headers for new api function put-timetable

* feat: adding table and api

* feat: for backup

* feat: updated pnpm-lock

* feat: initiating database creation

* feat: redoing databases

* feat: building database thread

* fix: fix git branch merging error (#226)

* fix: fix git branch merging error

* fix: fixing minor issues

* fix: hotfix

* fix: fixing db

* fix(deps): update dependency flatted to v3.2.7 (#215)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update jest monorepo (#210)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency husky to v8.0.2 (#227)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: renamed forum database and fixed multiple api (#230)

* feat: updated api get schema and renamed database

* fix: fix lambda function

* fix: fixed lambda get single thread and others

* fix: changed already existing db role name (#231)

* feat: updated api get schema and renamed database

* fix: fix lambda function

* fix: fixed lambda get single thread and others

* fix: fix already existing db role

* feat: editing forum restapi resources and added multiple CRUD lambda functions (#232)

* feat: altered api resources Trying to resolve multiple trigger issue in one lambda function

* feat: added lambdas delete patch and post fixed minor issues in other lambdas

* fix: erased unused library

* chore(deps): update dependency constructs to v10.1.205 (#206)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency ts-jest to v28.0.8 (#208)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency ts-node to v10.9.1 (#234)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency constructs to v10.1.206 (#235)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency esbuild to ^0.16.0 (#233)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency eslint-import-resolver-typescript to v3 (#214)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update commitlint monorepo to v17.3.0 (#213)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update jest monorepo to v29 (#239)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* feat: adding forum comment features (#240)

* feat: initiating forum comments function

* feat: added api gateway schemas for forum comment GET POST and PATCH

* feat: added Forum Comment Api Service

* feat: added GET POST PATCH DELETE lambda functions for forum comments

* feat: finishing fourm comment lambda functions Now capable of conducting simple curd operations

* fix: fix forum comment patch

* fix: re-configuring options resource for forum threads

* fix: renaming api resource

* fix: issue with post forum thread fixing issue (#242)

* fix: mistaken sortkey type

* fix: trying to solve a problem

* fix: changing db (#243)

* fix: solving database issue

* fix: still fixing issues

* fix: reverting error (#244)

* fix: fixing big time reverting whole thread feature

* fix: trying my best to fix

* fix: continuing fix

* fix: continuing

* fix: deleting lambda (#245)

* feat: reverting

* feat: idontknowwhatshappeningnow

* feat: fixing mistakes

* feat: retrieving db and api

* chore(deps): update dependency constructs to v10.1.210 (#241)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: fixing cross stack referencing (#247)

* fix: fixing cross stack referencing

* fix: fixing export value

* chore(deps): update dependency husky to v8.0.3 (#246)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: updating dependencies and syllabus structure (#249)

* fix: configuring-rest-api (#219)

* chore(deps): update dependency eslint to v8.9.0 (#141)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update amannn/action-semantic-pull-request action to v4.2.0 (#140)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.70 (#138)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.71 (#145)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update pnpm/action-setup action to v2.2.0 (#142)

Co-authored-by: Renovate Bot <[email protected]>

* feat: lambda for put-timetable (#144)

* feat: lambda for put-timetable

* deleted newline for put-timetable.

* changed file name for consistency

* chore(deps): update actions/setup-node action to v3 (#148)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update pnpm/action-setup action to v2.2.1 (#147)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.72 (#146)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.12.1 (#143)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.14.0 (#133)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.74 (#150)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency eslint to v8.10.0 (#149)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency typescript to v4.6.2 (#153)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.15.0 (#154)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.75 (#152)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency ts-node to v10.6.0 (#155)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update actions/checkout action to v3 (#156)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.13.0 (#151)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.76 (#157)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.77 (#158)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.79 (#159)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.14.0 (#162)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency ts-node to v10.7.0 (#161)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.81 (#160)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.82 (#163)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.83 (#164)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.16.0 (#168)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update endbug/add-and-commit action to v9 (#167)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency @commitlint/cli to v16.2.3 (#170)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.15.0 (#169)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.90 (#165)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update peter-evans/find-comment action to v2 (#175)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update peter-evans/create-or-update-comment action to v2 (#174)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.17.0 (#171)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency constructs to v10.0.92 (#172)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.16.0 (#173)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependency eslint-import-resolver-typescript to v2.7.0 (#176)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.19.0 (#183)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update typescript-eslint monorepo to v5.17.0 (#182)

Co-authored-by: Renovate Bot <[email protected]>

* feat: api for put-timetable lambda. (#179)

* feat: api for put-timetable lambda.

* feat: fixed syntax errors

* feat: fixed syntax error (2)

* chore(deps): update dependencies

* chore: add lint-staged

* chore(deps): update codecov/codecov-action action to v3 (#186)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update amannn/action-semantic-pull-request action to v4.3.0 (#189)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update aws-cdk monorepo to v2.22.0

* chore(deps): update github/codeql-action action to v2 (#192)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update amannn/action-semantic-pull-request action to v4.4.0 (#190)

Co-authored-by: Renovate Bot <[email protected]>

* chore(deps): update dependencies

* chore(deps): update amannn/action-semantic-pull-request action to v4.5.0

* chore(deps): update dependency husky to v8

* chore(deps): update dependency @commitlint/cli to v16.3.0

* chore(deps): update dependency standard-version to v9.5.0

* chore(deps): update aws-cdk monorepo to v2.27.0

* chore(deps): update dependency ts-jest to v28.0.4

* chore(deps): update dependency eslint to v8.17.0

* chore(deps): update dependency ts-node to v10.8.1

* chore(deps): update typescript-eslint monorepo to v5.27.1

* chore(deps): update jest monorepo

* chore(deps): update dependency constructs to v10.1.32

* chore(deps): update dependencies

* chore(deps): update pnpm/action-setup action to v2.2.2

* chore(deps): update dependency typescript to v4.7.3

* chore(deps): update dependencies

* f:added Put method into default Headers for new api function put-timetable (#216)

* feat: updated pnpm-lock file to latest

* feat: uploading updated package file

* feat: updating package-lock file

* fix: modified jest config file

* fix: update jest config

* fix: config rest api

* fix: update jest config

* fix: jest types

* fix: update pnpm lock

* fix: deleted package-lock

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: AustinZhu <[email protected]>

* Revert "fix: configuring-rest-api (#219)" (#220)

This reverts commit 665e252.

* fix: chaning syllabus constants

* fix: fixing actions

* fix: adding pnpm command

* fix: reverting changes to original form

---------

Co-authored-by: Jason Park <[email protected]>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: AustinZhu <[email protected]>

* chore(deps): update dependency constructs to v10.1.279 (#250)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: establishing table (#252)

* fix: minor changes (#253)

* fix: renaming table (#254)

* fix: renaming table

* fix: might be an empty commit

* fix: exporting table arn (#255)

* fix: resolving already existing identifier (#256)

* fix: rereferencing export (#258)

* fix: removed conflicting service

* fix: removing exporting value

* fix: re connecting thread service

* fix: adding lsi to table exporting arn with tablename (#259)

* fix: deleting thread table (#260)

* fix: recreating thread table with proper lsi (#261)

* fix: recreating lambdas for forum threads (#262)

* chore(deps): update typescript-eslint monorepo to v5.55.0 (#207)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency @types/node to v18 (#237)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update aws-cdk monorepo (#209)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: api service added (#266)

* chore(deps): update dependency typescript to v4.9.5 (#211)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency eslint to v8.36.0 (#212)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update commitlint monorepo to v17.4.4 (#267)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: fixing error for get thread (#271)

* feat: adding amplify micro app forum (#272)

* feat: adding amplify app forums

* fix: deleting added micro app

* feat: readding amplify app forum

* chore(deps): update dependency esbuild to ^0.17.0 (#269)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: updating outdated pnpm lock file (#274)

* fix: reinstalling pnpm lock file to solve outdate issue

* fix: reinstalling pnpm and then reinstalling pnpm lock file

* chore(deps): update dependency constructs to v10.1.305 (#263)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency @commitlint/cli to v17.5.1 (#275)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency constructs to v10.1.309 (#276)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency aws-cdk-lib to v2.74.0 (#277)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency constructs to v10.1.311 (#278)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update commitlint monorepo to v17.6.1 (#279)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency eslint to v8.38.0 (#280)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update jest monorepo to v29.5.0 (#281)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency constructs to v10.1.312 (#282)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update dependency @types/node to v18.15.12 (#273)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: adding response handler (#285)

* fix: fixing multiple lambda functions (#286)

* fix: fixing redundant data requirements described in the schema (#287)

* fix: fixing multiple lambda functions

* fix: fixing api schema

* fix: fixed schema and some lambdas (#288)

* fix: scraper and period location (#289)

* feat: adding new case for scrapper for instance multiple periods and multiple locations

* feat: adding case of multiple locations and periods devided with a slash

* feat: updated get single thread lambda role to all access to db (#290)

* feat: enabling multi-line evaluation criteria scraping (#291)

* feat: adding regex to scrape multiple eval criterias

* feat: enabling multiple line of criteria

* chore(deps): update dependency @types/jest to v29.5.1 (#284)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore(deps): update typescript-eslint monorepo to v5.59.6 (#283)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* fix: applying hotfix changes to branch develop

* feat: adding case 3 for merging period and location for exceptions (#295)

* chore(deps): update pnpm/action-setup action to v2.2.4 (#228)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chores: simple update

* fix: refactoring forum table keys (#298)

* fix: refactoring forum table keys

* fix: first deleting the table

* feat: exporting table arn

* feat: destroying table forum (#299)

* feat: destroying table forum

* feat: exporting table name and arn to disconnect api service

* feat: continue destorying the forum table (#300)

* feat: continue destorying the forum table

* feat: disconnecting endpoint and stop exporting table arn

* feat: finishing refactoring forum functionaility (#301)

* feat: changing parameters for uid (#302)

* feat: changing parameters for uid

* fix: fixing conditional statements

* feat: adding default value

* feat: github why are you doing this stop this please

* fix: small changes

* fix: fix get-course (#303)

* feat: fixing cron

* fix: fix get eval criteria (#306)

* fix-get-eval-criteria

* fix: fix get-eval-criteria

* fix: fixing pnpm version to 6 (#309)

* feat: adding oauth for flutter app (#310)

* feat: adding oauth for flutter app

* fix: fixing typo

* fix: hotfix for conditional (#311)

* fix: fixing the fucking delete and patch

* feat: i might have solved the fucking issue

* feat: add mod flag (#312)

* feat: adding mod flag to get all threads lambda

* feat: adding mod flag to board threads

* fix: multiple lambdas related forums (#313)

* fix: update node version

* feat: fixing get functionality

* fix: getting rid of default values

* fix: final fix please

* fix: taking out int

* fix: lets make it work

* feat: adding school filtering

* fix: adding contigency

* fix: fixing bool

* fix: fixing bull for starting index

* feat: adding some loggings

* fix: fixing indexing

* chore: adding logging for debug

* feat: adding end index to message response

* fix: fixing schema to array

* feat: adding tags filtering to lambda

* feat: adding filitering and pagination functionality to board thread api

* fix: fixing small typos

* feat: contacting two lambdas to one

* feat: fixing

* fix: adding default

* feat: adding loggings for debugging

* feat: fixing sorting logic

* feat: refactoring sorting method

* feat: adding builtin dynamo pagination

* feat: reverting changes back to original built in pagination requires more examination

* feat: returning the created thread item for smooth UX

* feat: popping uid for secruity measures

* feat: adding thread comment to retunred data without uid exposure

* feat: adding mod flag

* feat: adding backend functionality for like

* feat: passing thread id back to client

* fix: fixing like logic

* fix: fixing logic for likes

* fix: refixing the fucking likes feature

* feat: major update into main from develop

* feat: renaming actions names

* feat: adding magic command to get rid of the table

* feat: destroying table on stage dev

* fix: fixing export value

* fix: what the fuck is happening

* fix: finalizing db reset

* feat: disconnecting service

* chore: small stuff

* feat: destroying table

* fix: commenting out export value method

* feat: rebuilding tables

* feat: rebuilding table what just happened

* feat: fixing git workflows and adding environment variables to amplfi… (#321)

* feat: fixing git workflows and adding environment variables to amplfiy configurations

* fix: variable instantiation error fixed

* fix: adding some error loggings to figure out the issue

* feat: adding additional API base url for VITE for forums

* fix: fixing variable name typo

* feat: adding needed variables to github actions yaml

* fix: fixing buildspec due to git merge conflicts

* fix: fixing basepath for dev env

* fix: refixing public base path

* feat: thread comment count (#322)

* feat: added comment count to post thread

* feat: update comment count

* feat: schema update new action

* chore: empty commit

* chore: test

* chore: update count change

* feat: adding newComment flag

* chore: small changes due to git merge conflict

---------

Co-authored-by: Jason Park <[email protected]>

* fix: messed up update expressions

* feat: adding more logic to patch and get threads related to likes and comments

* feat: adding new action of comment count decrease to patch thread lambda

* chore: adding logging statements

* fix: accidently deleted handler

* feat: adding increase and decrease action to schema

* fix: fixing envvar base path for app root

* fix: is it because of the space

* feat: adding logging statements

* chore: deleting condition expression

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Renovate Bot <[email protected]>
Co-authored-by: Jason Park <[email protected]>
Co-authored-by: AustinZhu <[email protected]>
Co-authored-by: Y.H LIEN <[email protected]>
  • Loading branch information
6 people authored Sep 17, 2023
1 parent 28ae92d commit 0ba9c38
Show file tree
Hide file tree
Showing 14 changed files with 249 additions and 73 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@ env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
DEPLOY_KEY: ${{ secrets.FEEDS_DEPLOY_PRIVATE_KEY }}
MASTER_VITE_GA_ID: ${{secrets.VITE_GA_ID}}
DEV_VITE_GA_ID: ${{secrets.DEV_VITE_GA_ID}}
STAGE: dev

jobs:
Expand Down Expand Up @@ -52,7 +54,7 @@ jobs:

update_doc:
runs-on: ubuntu-latest
needs: [ deploy ]
needs: [deploy]
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -75,5 +77,5 @@ jobs:
author_email: [email protected]
add: "['./openapi/dev.yml', './openapi/prod.yml']"
branch: main
message: 'API Documentation update from GitHub Actions'
message: "API Documentation update from GitHub Actions"
push: true
2 changes: 2 additions & 0 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
DEPLOY_KEY: ${{ secrets.FEEDS_DEPLOY_PRIVATE_KEY }}
MASTER_VITE_GA_ID: ${{secrets.VITE_GA_ID}}
DEV_VITE_GA_ID: ${{secrets.DEV_VITE_GA_ID}}
STAGE: dev

jobs:
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@ env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
DEPLOY_KEY: ${{ secrets.FEEDS_DEPLOY_PRIVATE_KEY }}
MASTER_VITE_GA_ID: ${{secrets.VITE_GA_ID}}
DEV_VITE_GA_ID: ${{secrets.DEV_VITE_GA_ID}}
STAGE: dev

jobs:
Expand Down
Empty file modified .husky/commit-msg
100644 → 100755
Empty file.
Empty file modified .husky/pre-commit
100644 → 100755
Empty file.
2 changes: 2 additions & 0 deletions lib/configs/amplify/build-setting.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ import { microAppCorsHeader, securityHeaders } from './website';

export const BIT_TOKEN = process.env.BIT_TOKEN!;
export const FEEDS_DEPLOY_KEY = process.env.DEPLOY_KEY!;
export const MASTER_VITE_GA_ID = process.env.MASTER_VITE_GA_ID!;
export const DEV_VITE_GA_ID = process.env.DEV_VITE_GA_ID!;

const preBuild = {
commands: ['npm install -g pnpm', 'pnpm install --filter .'],
Expand Down
11 changes: 10 additions & 1 deletion lib/configs/api-gateway/schema.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import * as apigw from 'aws-cdk-lib/aws-apigateway';

// test
export const syllabusSchema: apigw.JsonSchema = {
schema: apigw.JsonSchemaVersion.DRAFT7,
type: apigw.JsonSchemaType.ARRAY,
Expand Down Expand Up @@ -428,6 +429,12 @@ export const forumThreadGetRespSchema: apigw.JsonSchema = {
totalLikes: {
type: apigw.JsonSchemaType.INTEGER,
},
comment_count: {
type: apigw.JsonSchemaType.INTEGER,
},
new_comment: {
type: apigw.JsonSchemaType.BOOLEAN,
},
},
required: [
'univ_id',
Expand Down Expand Up @@ -503,12 +510,14 @@ export const forumThreadPatchReqSchema: apigw.JsonSchema = {
},
action: {
type: apigw.JsonSchemaType.STRING,
enum: ['update', 'like', 'dislike'],
enum: ['update', 'like', 'dislike', 'update_incr', 'update_decr'],
},
},
required: ['data', 'action'],
};

// turn off double quotation

export const forumCommentGetRespSchema: apigw.JsonSchema = {
schema: apigw.JsonSchemaVersion.DRAFT7,
type: apigw.JsonSchemaType.OBJECT,
Expand Down
7 changes: 6 additions & 1 deletion lib/configs/route53/domain.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
export const ROOT_DOMAIN = 'wasedatime.com';

export const DEV_DOMAIN = 'dev.wasedatime.com';

export const API_DOMAIN = 'api.wasedatime.com';

export const AUTH_DOMAIN = 'auth.wasedatime.com';
Expand All @@ -15,4 +17,7 @@ export const MX_VALUES = [
{ priority: 10, hostName: 'mx2.forwardemail.net' },
];

export const EMAIL_TXT = ['v=spf1 a mx include:spf.forwardemail.net -all', '[email protected]'];
export const EMAIL_TXT = [
'v=spf1 a mx include:spf.forwardemail.net -all',
'[email protected]',
];
140 changes: 100 additions & 40 deletions lib/constructs/presentation/web-app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,14 @@ import { Construct } from 'constructs';
import {
BIT_TOKEN,
FEEDS_DEPLOY_KEY,
MASTER_VITE_GA_ID,
DEV_VITE_GA_ID,
microAppBuildSpec,
microAppDevBuildSpec,
} from '../../configs/amplify/build-setting';
import { webAppCode } from '../../configs/amplify/codebase';
import { developerAuth } from '../../configs/amplify/website';
import { ROOT_DOMAIN } from '../../configs/route53/domain';
import { ROOT_DOMAIN, DEV_DOMAIN } from '../../configs/route53/domain';

export interface WebAppProps {
apiDomain?: string;
Expand Down Expand Up @@ -36,16 +38,28 @@ export class AmplifyMonoWebApp extends AbstractWebApp {
constructor(scope: Construct, id: string, props: WebAppProps) {
super(scope, id, props);

const missingVars = [];

if (!MASTER_VITE_GA_ID) missingVars.push('MASTER_VITE_GA_ID');
if (!DEV_VITE_GA_ID) missingVars.push('DEV_VITE_GA_ID');

if (missingVars.length > 0) {
throw new Error(
`Required environment variables are missing: ${missingVars.join(', ')}`,
);
}

this.appProps = props;

this.app = new amplify.App(this, 'root-app', {
appName: 'wasedatime-web-root',
autoBranchDeletion: false,
buildSpec: microAppBuildSpec('root'),
description: 'A web app aiming to provide better campus life at Waseda University.',
description:
'A web app aiming to provide better campus life at Waseda University.',
environmentVariables: {
REACT_APP_API_BASE_URL: `https://${ props.apiDomain }/v1`,
REACT_APP_OAUTH_URL: `https://${ props.authDomain }`,
REACT_APP_API_BASE_URL: `https://${props.apiDomain}/v1`,
REACT_APP_OAUTH_URL: `https://${props.authDomain}`,
NODE_OPTIONS: '--max-old-space-size=8192',
BIT_TOKEN: BIT_TOKEN,
DEPLOY_KEY: FEEDS_DEPLOY_KEY,
Expand All @@ -61,21 +75,34 @@ export class AmplifyMonoWebApp extends AbstractWebApp {
});
this.microApps.root = this.app;

const masterBranch = this.app.addBranch('master', {
autoBuild: false,
branchName: 'master',
stage: 'PRODUCTION',
buildSpec: microAppBuildSpec('root'),
}).addEnvironment('REACT_APP_API_BASE_URL', `https://${ props.apiDomain }/v1`);
const masterBranch = this.app
.addBranch('master', {
autoBuild: false,
branchName: 'master',
stage: 'PRODUCTION',
buildSpec: microAppBuildSpec('root'),
})
.addEnvironment('REACT_APP_API_BASE_URL', `https://${props.apiDomain}/v1`)
.addEnvironment('VITE_API_BASE_URL', `https://${props.apiDomain}/v1`)
.addEnvironment('VITE_GA_ID', MASTER_VITE_GA_ID)
.addEnvironment('VITE_MF_HOME_BASE_PATH', `https://${ROOT_DOMAIN}`);
this.branches.main = masterBranch;

const devBranch = this.app.addBranch('dev', {
autoBuild: false,
basicAuth: developerAuth,
branchName: 'develop',
stage: 'DEVELOPMENT',
buildSpec: microAppDevBuildSpec('root'),
}).addEnvironment('REACT_APP_API_BASE_URL', `https://${ props.apiDomain }/staging`);
const devBranch = this.app
.addBranch('dev', {
autoBuild: false,
basicAuth: developerAuth,
branchName: 'develop',
stage: 'DEVELOPMENT',
buildSpec: microAppDevBuildSpec('root'),
})
.addEnvironment(
'REACT_APP_API_BASE_URL',
`https://${props.apiDomain}/staging`,
)
.addEnvironment('VITE_API_BASE_URL', `https://${props.apiDomain}/staging`)
.addEnvironment('VITE_GA_ID', DEV_VITE_GA_ID)
.addEnvironment('VITE_MF_HOME_BASE_PATH', `https://${DEV_DOMAIN}`);
this.branches.dev = devBranch;

this.domain = this.app.addDomain('domain', {
Expand All @@ -89,13 +116,14 @@ export class AmplifyMonoWebApp extends AbstractWebApp {
}

public addMicroApp(name: string) {
const microApp = new amplify.App(this, `${ name }-app`, {
appName: `wasedatime-web-${ name }`,
const microApp = new amplify.App(this, `${name}-app`, {
appName: `wasedatime-web-${name}`,
autoBranchDeletion: false,
buildSpec: microAppBuildSpec(name),
environmentVariables: {
REACT_APP_API_BASE_URL: `https://${ this.appProps.apiDomain }/v1`,
REACT_APP_OAUTH_URL: `https://${ this.appProps.authDomain }`,
REACT_APP_API_BASE_URL: `https://${this.appProps.apiDomain}/v1`,
VITE_API_BASE_URL: `https://${this.appProps.apiDomain}/v1`,
REACT_APP_OAUTH_URL: `https://${this.appProps.authDomain}`,
NODE_OPTIONS: '--max-old-space-size=8192',
BIT_TOKEN: BIT_TOKEN,
},
Expand All @@ -110,26 +138,58 @@ export class AmplifyMonoWebApp extends AbstractWebApp {
});
this.microApps[name] = microApp;

microApp.addBranch('master', {
autoBuild: false,
branchName: 'master',
stage: 'PRODUCTION',
buildSpec: microAppBuildSpec(name),
}).addEnvironment('REACT_APP_API_BASE_URL', `https://${ this.appProps.apiDomain }/v1`);

microApp.addBranch('dev', {
autoBuild: false,
branchName: 'develop',
stage: 'DEVELOPMENT',
buildSpec: microAppDevBuildSpec(name),
}).addEnvironment('REACT_APP_API_BASE_URL', `https://${ this.appProps.apiDomain }/staging`);
microApp
.addBranch('master', {
autoBuild: false,
branchName: 'master',
stage: 'PRODUCTION',
buildSpec: microAppBuildSpec(name),
})
.addEnvironment(
'REACT_APP_API_BASE_URL',
`https://${this.appProps.apiDomain}/v1`,
)
.addEnvironment(
'VITE_API_BASE_URL',
`https://${this.appProps.apiDomain}/v1`,
)
.addEnvironment('VITE_GA_ID', MASTER_VITE_GA_ID)
.addEnvironment(
'VITE_PUBLIC_BASE_PATH',
`https://wasedatime.com/${name}`,
);

const appDomain = this.microApps[name].defaultDomain;
this.app.addCustomRule(new amplify.CustomRule({
source: `/${ name }/<*>`,
target: `https://master.${ appDomain }/<*>`,
status: amplify.RedirectStatus.REWRITE,
}));
this.app.addEnvironment(`MF_${ name.toUpperCase() }_DOMAIN`, appDomain);
microApp
.addBranch('dev', {
autoBuild: false,
branchName: 'develop',
stage: 'DEVELOPMENT',
buildSpec: microAppDevBuildSpec(name),
})
.addEnvironment(
'REACT_APP_API_BASE_URL',
`https://${this.appProps.apiDomain}/staging`,
)
.addEnvironment(
'VITE_API_BASE_URL',
`https://${this.appProps.apiDomain}/staging`,
)
.addEnvironment('VITE_GA_ID', DEV_VITE_GA_ID)
.addEnvironment('VITE_PUBLIC_BASE_PATH', `https://develop.${appDomain}`);

this.app.addCustomRule(
new amplify.CustomRule({
source: `/${name}/<*>`,
target: `https://master.${appDomain}/<*>`,
status: amplify.RedirectStatus.REWRITE,
}),
);
this.app.addEnvironment(
`VITE_MF_${name.toUpperCase()}_BASE_PATH`,
`https://develop.${appDomain}`,
);
}
}

//
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"@types/pluralize": "0.0.29",
"@typescript-eslint/eslint-plugin": "5.59.6",
"@typescript-eslint/parser": "5.59.6",
"aws-cdk-lib": "2.74.0",
"aws-cdk-lib": "^2.74.0",
"constructs": "10.1.312",
"esbuild": "^0.17.0",
"eslint": "8.38.0",
Expand Down
2 changes: 1 addition & 1 deletion pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

50 changes: 35 additions & 15 deletions src/lambda/get-single-thread/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

@resp_handler
def get_single_thread(board_id, thread_id, uid=""):

results = table.query(
KeyConditionExpression=Key("board_id").eq(
board_id) & Key("thread_id").eq(thread_id)
Expand All @@ -14,22 +13,43 @@ def get_single_thread(board_id, thread_id, uid=""):
if not results:
raise LookupError

table.update_item(
Key={
"board_id": board_id,
"thread_id": thread_id,
},
UpdateExpression="SET #v = #v + :incr",
ExpressionAttributeNames={
'#v': 'views'
},
ExpressionAttributeValues={
":incr": 1
}
)

item = results[0]

if item["uid"] == uid:
table.update_item(
Key={
"board_id": board_id,
"thread_id": thread_id,
},
UpdateExpression="SET #v = #v + :incr, #nc = :newComment",
ConditionExpression="#uid = :uidValue",
ExpressionAttributeNames={
'#v': 'views',
'#nc': 'new_comment',
'#uid': 'uid'
},
ExpressionAttributeValues={
":incr": 1,
":newComment": False,
":uidValue": uid
}
)
else:
# Increment the view count but do not update new_comment
table.update_item(
Key={
"board_id": board_id,
"thread_id": thread_id,
},
UpdateExpression="SET #v = #v + :incr",
ExpressionAttributeNames={
'#v': 'views'
},
ExpressionAttributeValues={
":incr": 1
}
)

item["mod"] = False
if item["uid"] == uid:
item["mod"] = True
Expand Down
Loading

0 comments on commit 0ba9c38

Please sign in to comment.