Skip to content

Conversation

@akarki2005
Copy link
Contributor

@akarki2005 akarki2005 commented Sep 23, 2025

Proposed Changes

This PR renames the Post and PostCategory tables in the Courseography database to Program and ProgramCategory respectively.

Type of Change

(Write an X or a brief description next to the type or types that best describe your changes.)

Type Applies?
🚨 Breaking change (fix or feature that would cause existing functionality to change)
New feature (non-breaking change that adds functionality)
🐛 Bug fix (non-breaking change that fixes an issue)
🎨 User interface change (change to user interface; provide screenshots)
♻️ Refactoring (internal change to codebase, without changing functionality) X
🚦 Test update (change that only adds or modifies tests)
📦 Dependency update (change that updates a dependency)
🔧 Internal (change that only affects developers or continuous integration)

Checklist

(Complete each of the following items for your pull request. Indicate that you have completed an item by changing the [ ] into a [x] in the raw text, or by clicking on the checkbox in the rendered description on GitHub.)

Before opening your pull request:

  • I have performed a self-review of my changes.
    • Check that all changed files included in this pull request are intentional changes.
    • Check that all changes are relevant to the purpose of this pull request, as described above.
  • [N/A] I have added tests for my changes, if applicable.
    • This is required for all bug fixes and new features.
  • I have updated the project documentation, if applicable.
    • This is required for new features.
  • [N/A] If this is my first contribution, I have added myself to the list of contributors.
  • I have updated the project Changelog (this is required for all changes).

After opening your pull request:

  • I have verified that the CircleCI checks have passed.
  • I have requested a review from a project maintainer.

@akarki2005
Copy link
Contributor Author

akarki2005 commented Oct 20, 2025

Hey David, while waiting on the CI for this PR (it failed due to a time limit exceeded error), I noticed some inefficiencies in our CI config I thought could potentially be improved. Here's what i found:

  1. Our Restore Cached Dependencies (Haskell) step is fairly strict, causing a cache miss whenever courseography.cabal or stack.yaml.lock is updated. I read up on how CircleCI handles caching here and I believe that we could try using partial dependency matching to restore stack.yaml.lock dependencies when our cabal file changes but dependencies don't, and another for when the opposite happens.
  2. Inside the Resolve/Update Dependencies step, we have the line stack --no-terminal build --fast -j1 --ghc-options -Werror. Here, the -j1 flag here specifies that only one CPU core is being used during the build process, and so I think we can change this to something like -j4 to support multi-threading during the build process.

I'd be happy to explore this in seperate PRs; let me know what you think!

@david-yz-liu
Copy link
Contributor

Hi @akarki2005, thanks for the ping. I'm re-running the CI build now. You're absolutely correct that how we're handling the dependency caching is not optimal. I'd be happy for you to explore both of your suggestions in a separate PR.

@coveralls
Copy link

coveralls commented Oct 21, 2025

Pull Request Test Coverage Report for Build c1af5ae6-6501-463e-8e2b-3f62f7a4d663

Details

  • 16 of 32 (50.0%) changed or added relevant lines in 6 files are covered.
  • 16 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.04%) to 55.158%

Changes Missing Coverage Covered Lines Changed/Added Lines %
app/Database/Database.hs 8 10 80.0%
app/Controllers/Generate.hs 1 5 20.0%
app/WebParsing/PostParser.hs 0 10 0.0%
Files with Coverage Reduction New Missed Lines %
app/WebParsing/PostParser.hs 16 38.24%
Totals Coverage Status
Change from base Build 4f01acc7-ca46-45b8-bc50-95514d40c87a: 0.04%
Covered Lines: 2224
Relevant Lines: 3957

💛 - Coveralls

Copy link
Contributor

@david-yz-liu david-yz-liu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@akarki2005 nice work! I left a few comments. Sorry for taking a few days for this review. :)

@akarki2005 akarki2005 force-pushed the rename-post-table-to-program branch from 4e02bb7 to a49e6f3 Compare November 2, 2025 06:07
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.

3 participants