-
Notifications
You must be signed in to change notification settings - Fork 8
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
Feature: Add SemanticArtefactCatalog model #183
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## development #183 +/- ##
===============================================
+ Coverage 82.44% 82.77% +0.33%
===============================================
Files 103 106 +3
Lines 6834 7211 +377
===============================================
+ Hits 5634 5969 +335
- Misses 1200 1242 +42
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
add link to resolved issue. and a description of the changes.
lib/ontologies_linked_data/models/mod/semantic_artefact_catalog.rb
Outdated
Show resolved
Hide resolved
lib/ontologies_linked_data/models/mod/semantic_artefact_catalog.rb
Outdated
Show resolved
Hide resolved
lib/ontologies_linked_data/models/mod/semantic_artefact_catalog.rb
Outdated
Show resolved
Hide resolved
bbd132c
to
194fcfb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tests are red
|
||
def calculate_attr_from_metrics(attr) | ||
attr_to_get = attr.to_sym | ||
submissions = LinkedData::Models::OntologySubmission.where.include(OntologySubmission.goo_attrs_to_load([attr_to_get])) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this code will be really slow, and sum all the submissions not only the latest.
why no just just do. LinkedData::Models::Metric.where.include(...things_you_want...).all
it is faster, from that you need to filter the latest IDs only
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@imadbourouche can you open an issue about this, I merged the PR forgot I said this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes i'll fix this in another pull request before closing the main issue for catalog
Context
What's new
This is the model that represent the portal and it's configurations
semantic_artefact_catalog.rb
: is the main model that will define the attributes and the methods that the model needsemantic_artefact_catalog.yml
: is the yaml file that defines the scheme of the modelReferences