Skip to content

Database Model #5 - #15

Merged
tdruez merged 26 commits into
developfrom
models_db
Jul 14, 2017
Merged

Database Model #5#15
tdruez merged 26 commits into
developfrom
models_db

Conversation

@kartiksibal

Copy link
Copy Markdown
Contributor

What's Present:

  1. Basic layout
  2. Helptexts

kartiksibal and others added 11 commits July 7, 2017 09:35
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Comment thread app/vulncode_app/models.py Outdated
class ImpactedPackage(models.Model):
vulnerability_id = models.ForeignKey('Vulnerability')
package_id = models.ForeignKey('Package')
vulnerability_id = models.ForeignKey('Vulnerability')

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

As you did for VulnerabilityReference.vulnerability, you should remove the _id suffix. For both fields vulnerability_id and package_id

Comment thread app/vulncode_app/models.py Outdated
class ResolvedPackage(models.Model):
vulnerability_id = models.ForeignKey('Vulnerability')
package_id = models.ForeignKey('Package')
vulnerability_id = models.ForeignKey('Vulnerability')

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Same comment about the _id suffix.

version = models.CharField(max_length=50, help_text="Pacakge version")


class PackageReference(models.Model):

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

We are missing a FK to the Package model.

tdruez and others added 15 commits July 11, 2017 10:48
Signed-off-by: Thomas Druez <tdruez@nexb.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
Signed-off-by: Kartik Sibal <kartiksibal@gmail.com>
- Add tests runner in the travis config
- Cleanup

Signed-off-by: Thomas Druez <tdruez@nexb.com>
Signed-off-by: Thomas Druez <tdruez@nexb.com>
Signed-off-by: Thomas Druez <tdruez@nexb.com>
@tdruez
tdruez merged commit 26d5f6a into develop Jul 14, 2017
@tdruez
tdruez deleted the models_db branch July 14, 2017 00:28
pombredanne added a commit that referenced this pull request Apr 2, 2025
Update .gitignore to ignore Jupyter temp files
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.

2 participants