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

H-1978, H-1979, H-2013, H-2014: Update type icons, labels, dataTypes #5982

Draft
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

CiaranMn
Copy link
Member

🌟 What is the purpose of this PR?

This PR contains a list of changes to:

  1. Entity type icons
  2. Entity type pluralTitle and inverse titles
  3. Expected data type for some data types (e.g. replace Text with URI or DateTime where appropriate)
  4. Rename a couple of types (Image -> Image File, Quick Note –> Note)
  5. Default provenance information for entities that might not have it

It also contains the necessary TS type changes and where we specify a dataTypeId to make sure it is correct.

The list of changes in the two files is intended for conversion into a migration script to overwrite types in the production db directly, to avoid the migration effort involved in updating all of these types to new versions (which would be significantly more complicated, given the dependency graph).

apps/hash-api/src/graph/ensure-system-graph-is-initialized/labels-icons-data-types.ts
apps/hash-api/src/graph/ensure-system-graph-is-initialized/provenance-defaults.ts

Deployment of this requires discussion as we need to coordinate the deployment of the Node API and frontend with the changes to types in the prod db, particurlarly due to:

  1. Renaming entity types: the entity types in the db need to match the types being specified by the clients
  2. Changing expected data type for some properties: the dataTypeId specified by the clients needs to match that expected by the API

🚫 Blocked by

  • H-3847: discuss coordination
  • H-3848: Merging this PR is blocked by a new eslint error created by an update to json-schema-to-typescript which is generating data type enums differently

Pre-Merge Checklist 🚀

🚢 Has this modified a publishable library?

This PR:

  • does not modify any publishable blocks or libraries, or modifications do not need publishing

📜 Does this require a change to the docs?

The changes in this PR:

  • are internal and do not require a docs change

🕸️ Does this require a change to the Turbo Graph?

The changes in this PR:

  • do not affect the execution graph

🐾 Next steps

Discuss coordination of changes.

@github-actions github-actions bot added area/apps > hash* Affects HASH (a `hash-*` app) area/infra Relates to version control, CI, CD or IaC (area) area/apps > hash-api Affects the HASH API (app) area/libs Relates to first-party libraries/crates/packages (area) type/eng > frontend Owned by the @frontend team type/eng > backend Owned by the @backend team area/tests New or updated tests area/tests > integration New or updated integration tests area/apps labels Dec 20, 2024
Copy link

codecov bot commented Dec 20, 2024

Codecov Report

Attention: Patch coverage is 0% with 19 lines in your changes missing coverage. Please review.

Project coverage is 21.71%. Comparing base (c523277) to head (e660c5e).

Files with missing lines Patch % Lines
...system-graph-is-initialized/provenance-defaults.ts 0.00% 8 Missing ⚠️
...em-graph-is-initialized/labels-icons-data-types.ts 0.00% 5 Missing ⚠️
.../hash-api/src/graph/knowledge/system-types/file.ts 0.00% 4 Missing ⚠️
...w-activities/shared/create-file-entity-from-url.ts 0.00% 1 Missing ⚠️
.../019-add-doc-company-and-person-types.migration.ts 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5982      +/-   ##
==========================================
- Coverage   21.72%   21.71%   -0.02%     
==========================================
  Files         566      568       +2     
  Lines       19157    19170      +13     
  Branches     2755     2755              
==========================================
  Hits         4162     4162              
- Misses      14943    14956      +13     
  Partials       52       52              
Flag Coverage Δ
apps.hash-ai-worker-ts 1.32% <0.00%> (ø)
apps.hash-api 1.15% <0.00%> (-0.01%) ⬇️
local.hash-backend-utils 8.81% <ø> (ø)
local.hash-isomorphic-utils 0.98% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/apps > hash* Affects HASH (a `hash-*` app) area/apps > hash-api Affects the HASH API (app) area/apps area/infra Relates to version control, CI, CD or IaC (area) area/libs Relates to first-party libraries/crates/packages (area) area/tests > integration New or updated integration tests area/tests New or updated tests type/eng > backend Owned by the @backend team type/eng > frontend Owned by the @frontend team
Development

Successfully merging this pull request may close these issues.

1 participant