You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+8-19
Original file line number
Diff line number
Diff line change
@@ -37,15 +37,6 @@ This is the first time IC Hack tech systems will have extensive documentation. E
37
37
38
38
## Development rules
39
39
40
-
### Working on issues
41
-
42
-
We use ClickUp to keep track of the progress of the project. To pick up an issue:
43
-
44
-
1. Assign yourself in any card from the "Backlog". This should automatically put your card under "Pending".
45
-
1. Alternatively, create an issue and add yourself as the asignee and place it in the "Pending" list.
46
-
1. Then [create a branch](#creating-a-branch) and [open a draft pr](#creating-a-pr).
47
-
1. Once the PR is approved and merged, move the card to "Completed".
48
-
49
40
### Creating a branch
50
41
51
42
No person can directly on the main branch. Hence you need to create a new branch to introduce any changes to the codebase.
@@ -58,18 +49,9 @@ No person can directly on the main branch. Hence you need to create a new branch
58
49
You should create a PR **as soon as** you create a branch.
59
50
60
51
1. If the PR is not ready, create a _Draft_ PR. This is so that others know what is being worked on and can provide some feedback before you are knee deep into the feature.
61
-
1. The actual commit messages within your PR **does not follow** any conventional naming pattern. However, your PR title must follow `type: description` format, similar to your branch name.
52
+
1. The actual commit messages within your PR **does not follow** any conventional naming pattern. However, your PR title must follow `type(scope): description` format, similar to your branch name.
62
53
1. If any of the repo admins approve your PR and you need to need to update your branch, consider rebase to avoid making another commit for the admins to review again.
63
54
64
-
#### PR <> ClickUp Integration
65
-
66
-
1. When you create a comment, in the description include the following text: `Link CU-86bzr6uwe`, you will find your taskId in the ClickUp Card you are working.
67
-
1. You can use special commit messages to change the status of your card. E.g. a commit message can be, `updated the readme #86bzr6uwe[in review]`.
68
-
1. Use `#<taskId>[in progress]` to move your card into "In Progress".
69
-
1. Use `#<taskId>[in review]` to move your card into "In Review".
70
-
1. Use `#<taskId>[blocked]` to move your card into "Blocked".
71
-
1. When merging, your commit description should include `#<taskId>[completed]` to move your card into "Completed".
72
-
73
55
## Our Team
74
56
75
57
### IC Hack '25
@@ -83,6 +65,13 @@ You should create a PR **as soon as** you create a branch.
Copy file name to clipboardExpand all lines: docs/directory-structure/server/modules/announcement.md
+2
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,8 @@ authors:
5
5
- George Decesare
6
6
---
7
7
8
+
# Announcement
9
+
8
10
The schema is quite simple. It is a table of announcements where each announcement has some information. The `pinUntil` field are those announcements which need to be scheduled at the top before the others **if and only if** the current datetime is before the datetime mentioned in `pinUntil`.
Copy file name to clipboardExpand all lines: docs/directory-structure/server/modules/index.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -3,7 +3,7 @@
3
3
Every sub-directory inside the `server/` directory is considered a **module**. A module _in this project_ contains their routes and possibly a schema.
4
4
These modules are _pluggable_ in the server code. In `src/app.ts`, you can import the module and route it with the `.route(url, app)` function by Hono.
5
5
6
-
## Modules
6
+
---
7
7
8
8
These certain modules are considered `core` since they the bare bones of what makes IC Hack. There is no special folder these but it is logical to lay them flat because _technically, then can be installed/uninstalled at will_.
Copy file name to clipboardExpand all lines: docs/directory-structure/subdomain-routing.md
+1-1
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
# Subdomain Routing
2
2
3
3
::: info
4
-
This is now deprecated
4
+
This was deprecated by [PR#163](https://github.com/icdocsoc/ichack/pull/163)
5
5
:::
6
6
7
7
The application runs in the Server-side rendering (SSR) mode. This means the HTML document is rendered on the server, and sent to the browser. The JavaScript files soon follow along and the JavaScript code then renders it again on the client side, giving the page the interactivity.
Copy file name to clipboardExpand all lines: docs/getting-started/environment-variables.md
+4
Original file line number
Diff line number
Diff line change
@@ -6,6 +6,10 @@ order: 3
6
6
7
7
Copy the `.env.template` file to `.env.local` and `.env.test` and fill in the values with the correct information. Ask the admins for credentials for staging and prod environemnts. Read [Bun's docs](https://bun.sh/docs/runtime/env) to understand the naming convention and how to force using one env file.
This page is a retrospective of everything that went well and wrong with the project.
8
+
9
+
## IC Hack '25
10
+
11
+
Nishant had a vision of the website and it become true. Well, 90% true but it was a massive achievement by the entire tech team and additional contributors. The codebase has been built to last with well-thought out design choices, placement of code, directory structure, code hygiene etc.
12
+
13
+
> The project was incomplete but it worked like fully-functioning well-oiled machine.
14
+
15
+
It was incomplete in the sense we were very time crunched that the last few commits leading upto the final deployment were shitty. But there were no tech problems at all. All raised issues during the event were human errors.
16
+
1. The Admin UI doesn't work on mobile, the Team's UI doesn't work on Mobile. The Dashboard had problems with components overflowing and not enough time to debug it.
17
+
2. There was no live-updates from the server hence we had to use 5-10 second polling.
18
+
3. We noticed a small issue where the main app would run out of memory and crash itself every 4 hours. This is a suspected memory leak in the application. An update in [Bun v1.2.2](https://bun.sh/blog/bun-v1.2.2#javascript-uses-10-30-less-memory-at-idle) suggests that there were memory issues in previous versions. This is still untested, so the exact source of the memory leak is not yet found. However, this periodic crash didn't effect any user. The system booted back up within minutes.
19
+
4. Some design choices were bad and some code hygiene started dropping a couple days before the event. There are plans to start refactoring them a few weeks before IC Hack'26 official development.
20
+
21
+
The Postgres instance was running normally however it may be a good idea to look into daily database backups upto the event and N-hourly backups during the event. We hope that future builds of the repository does not have to grind until the last moment. This repo, as it stands today, is built and designed to last
22
+
23
+
Bun started to become a bit of a pain in the ass. It is promising with an extremely fast execution and build time with great in-built features. However, since it is still new and immature, random errors kept coming up; nothing too bad to stop development for a long time. There were some dependency issues with Nuxt and Bun; however that was simply Nishant's error, corrected in [PR#184](https://github.com/icdocsoc/ichack/pull/184)
24
+
25
+
A couple of ideas we missed we:
26
+
1. Make the profile scanning at registration increment a counter. There was no way of telling which user had entered our premises from the volunteer app. We had to use the `qr` table to check how many hackers are in the event - which is not accurate since hackers don't link their QR codes immediately.
27
+
2. QR codes should contain a link instead of plain-text UUID. This way, hackers don't have to visit the website to scan their wristband (they are welcome to if needed). The volunteer app can simply extract the UUID from the url with the in-website camera to make the requests.
28
+
3. A whitelist and blacklist tag for wristband UUIDs. This is not a big problem since we have a physical restraint on the scanning it (eg volunteers are instructed not to scan a qr code not on the person's wrist, or scan any picture, etc). It is never a bad idea to be extra safe.
29
+
4. On the technical side of things, a table for meals/event check-ins/etc should be present. This table is a read access to hackers and exclusive write/read access to gods/admin/volunteers. Semantically, it makes sense to segregate this from the `profiles` table which is write/read access by the hackers.
30
+
5.`POST /auth/create` is kind of a BS route. We never implemented this feature in the admin UI. A script to directly target the database is fine and less cumbersome.
Copy file name to clipboardExpand all lines: docs/getting-started/project-timeline.md
+3-1
Original file line number
Diff line number
Diff line change
@@ -10,14 +10,16 @@ The initial development started in **July 2024** with the Hono server. Minor ref
10
10
11
11
## Second Architecture
12
12
13
-
Around **November 2024**, the codebase was completely refactored ([PR#54](https://github.com/icdocsoc/ichack/pull/54)) to support the serverless architecture of [Digital Ocean App Platform](../technologies/digital-ocean). The first architecture was a bit of a pain configuring the environment variables and on-boarding new users. This simplified the repository greatly and easier to deploy and manage.
13
+
Around **November 2024**, the codebase was completely refactored ([PR#43](https://github.com/icdocsoc/ichack/pull/43)) to support the [serverless architecture](../concepts/serverless-computing) of [Digital Ocean App Platform](../technologies/digital-ocean). The first architecture was a bit of a pain configuring the environment variables and on-boarding new users. This simplified the repository greatly and easier to deploy and manage.
14
14
15
15
As a result, we end up with the `website` application that is a single Nuxt4 application. This was connected to the Hono server with the `serverHandlers` property of `NuxtConfig`. The application smartly filtered pages and re-routed requests from `admin.ichack.org` and `my.ichack.org` accordingly from server middlewares and custom page routing defined in `apps/router.options.ts`.
16
16
17
17
The other application was `landing` that existed as a layer. We leveraged the fact that a Nuxt layer can be a stand-alone application. This app was statically generated and the files were uploaded to [Cloudflare Pages](../technologies/cloudflare) via [GitHub Actions](../technologies/github-actions).
18
18
19
19
`admin` and `my` remained as layers connected to the parent application for separation concerns. These layers extended `common` for the API requests they perform and `ui25` for the common UI components. As earlier, `admin` used [Nuxt UI v2](../technologies/nuxt-ui) and continued to do so.
20
20
21
+
Soon, we realised we were building something great and massive. We renamed the repository from ichack25 to simply ichack ([PR#54](https://github.com/icdocsoc/ichack/pull/54)) for future years to build upon this for many years to come. :tada:
22
+
21
23
### Nuxt 3 --> Nuxt 4
22
24
23
25
We decided to migrate the application to use Nuxt 4 instead. It was a bit of a migration to do so. This resulted a change in the Directory Structure.
Copy file name to clipboardExpand all lines: docs/getting-started/running-the-project.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ order: 2
8
8
9
9
This is not an exhaustive list.
10
10
11
-
-[Bun](../tech-stack/bun) v1.1.18
11
+
-[Bun](../tech-stack/bun) v1.1.44
12
12
- Node v22.2.0
13
13
-[Docker](../technologies/docker) v26.1.3
14
14
-[PostreSQL](../tech-stack/postgresql) v16.3
@@ -30,7 +30,7 @@ Execute `bun install` in the route directory.
30
30
31
31
### Setup the Database
32
32
33
-
1. If the schema has been updated and your local instance of postgres is not synced with it, you can reset this by executing `bun reset-db`.
33
+
1. If the schema has been updated and your local instance of postgres is not synced with it, you can reset this by executing `bun backend:push-schema`.
34
34
2. Seed the database with some predefined entries by executing `bun run scripts/seed.ts` while the database is running. This file contains the email and password to login as a `god`.
Copy file name to clipboardExpand all lines: docs/tech-stack/nuxt.md
+2-2
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
Follow the [Nuxt](https://nuxt.com) documentation [here](https://nuxt.com/docs/getting-started/introduction).
4
4
5
-
Nuxt is a great Vue-based meta-framework to build full stack applications. It comes with a built-in [Nitro server](https://nitro.unjs.io/) (which we largely ignore because of the lack of features and poor documentation, we use Hono instead). Nuxt's documentation, however, was good and now it's even better; so have a thorough read of it (including some complex stuff like [Layers](https://nuxt.com/docs/getting-started/layers) and [configuration](https://nuxt.com/docs/api/nuxt-config)). Here, we are going to touch upon rendering modes:
5
+
Nuxt is a great Vue-based meta-framework to build full stack applications. It comes with a built-in [Nitro server](https://nitro.unjs.io/) (which we largely ignore because of the lack of features and poor documentation, we use Hono instead). Nuxt's documentation, however, was good and now it's even better; so have a thorough read of it (including some complex stuff like [Layers](https://nuxt.com/docs/getting-started/layers) and [configuration](https://nuxt.com/docs/api/nuxt-config)).
6
6
7
7
::: warning
8
8
If you ever see an error like *"Hydration mismatch"* on your console, **DO NOT IGNORE IT AND AIM TO FIX IT ASAP!!**
@@ -23,7 +23,7 @@ Nishant and Jay worked with Nuxt 3 for IC Hack '24 and this made total sense to
23
23
Nuxt 4 is practically out at this time of writing. However, it is in beta build right now and we don't wish to experiment, especially since we were experimenting with the backend. Additionally, Nuxt 4 is not very different than Nuxt 3, apart from a few breaking changes. So it doesn't matter much anyway.
24
24
25
25
::: info
26
-
With the [2nd architecture PR](../getting-started/project-timeline), we have migrated to Nuxt4.
26
+
With the [2nd architecture PR](../getting-started/project-timeline), we migrated to Nuxt4.
0 commit comments