Skip to content
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

Feat: metadata endpoint #512

Merged
merged 3 commits into from
Jan 3, 2025
Merged

Feat: metadata endpoint #512

merged 3 commits into from
Jan 3, 2025

Conversation

thekaveman
Copy link
Member

Closes #510

Testing this PR

  1. Checkout the branch locally, open in devcontainer
  2. Reset the DB: flask drop-db then flask init-db
  3. Confirm you see a record in the metadata table in the Sqlite database code -r /tmp/test.db
  4. Launch the app with F5
  5. Hit the /metadata endpoint, confirm output is as expected

@thekaveman thekaveman requested a review from a team as a code owner December 19, 2024 00:11
@thekaveman thekaveman self-assigned this Dec 19, 2024
@thekaveman thekaveman added the enhancement New feature or request label Dec 19, 2024
Copy link

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  eligibility_server
  app.py
  eligibility_server/db
  models.py 11
  setup.py
Project Total  

This report was generated by python-coverage-comment-action

@thekaveman thekaveman marked this pull request as draft December 19, 2024 00:18
@thekaveman
Copy link
Member Author

thekaveman commented Dec 19, 2024

See #510 (comment) for why this is in Draft.

@thekaveman thekaveman marked this pull request as ready for review December 20, 2024 16:13
@thekaveman thekaveman changed the title Feat: metadata Feat: metadata endpoint Dec 20, 2024
@thekaveman
Copy link
Member Author

thekaveman commented Jan 2, 2025

Getting an error in the infra pipeline:

Error: Error acquiring the state lock
│ 
│ Error message: state blob is already locked
│ Lock Info:
│   ID:        7af48bbd-8334-3356-becd-b6fe48e7a429
│   Path:      tfstate/terraform.tfstateenv:dev
│   Operation: OperationTypePlan
│   Who:       vsts@fv-az420-271
│   Version:   1.8.5
│   Created:   2024-12-20 20:34:46.015548148 +0000 UTC

It looks like during the key rotation last month, a state lock was made that was never released.

I'm going to manually release the lock:

terraform force-unlock 7af48bbd-8334-3356-becd-b6fe48e7a429

Copy link
Member

@angela-tran angela-tran left a comment

Choose a reason for hiding this comment

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

Tested this locally, and it looks good to me 👍

@thekaveman thekaveman merged commit 4e1d6c0 into main Jan 3, 2025
7 checks passed
@thekaveman thekaveman deleted the feat/metadata branch January 3, 2025 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Store and expose the database load timestamp
2 participants