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

Added sto4_start_time column to be initialized on unit creation #1469

Merged
merged 10 commits into from
Sep 21, 2023

Conversation

rv0lt
Copy link
Member

@rv0lt rv0lt commented Sep 19, 2023

Read this before submitting the PR

1. Description / Summary

Now the column Sto4_Start_time will automatically be set in the Units table when the create-unit command is run. Instead of having to run the upgrade unit.

2. Jira task / GitHub issue

https://scilifelab.atlassian.net/jira/software/projects/DDS/boards/13?selectedIssue=DDS-1668

3. Type of change

What type of change(s) does the PR contain?

Check the relevant boxes below. For an explanation of the different sections, enter edit mode of this PR description template.

  • New feature
    • Breaking: Why / How? Add info here.
    • Non-breaking
  • Database change: Remember the to include a new migration version, or explain here why it's not needed.
  • Bug fix
  • Security Alert fix
  • Documentation
  • Workflow
  • Tests only

4. Additional information

5. Actions / Scans

Check the boxes when the specified checks have passed.

For information on what the different checks do and how to fix it if they're failing, enter edit mode of this description or go to the PR template.

  • Black
  • Prettier
  • Yamllint
  • Tests
  • CodeQL
  • Trivy
  • Snyk

@codecov
Copy link

codecov bot commented Sep 19, 2023

Codecov Report

Merging #1469 (ed04fab) into dev (d10dcf7) will increase coverage by 0.00%.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##              dev    #1469   +/-   ##
=======================================
  Coverage   90.15%   90.15%           
=======================================
  Files          29       29           
  Lines        4407     4408    +1     
=======================================
+ Hits         3973     3974    +1     
  Misses        434      434           
Files Changed Coverage Δ
dds_web/commands.py 80.27% <100.00%> (+0.03%) ⬆️

@rv0lt rv0lt requested review from valyo and i-oden September 19, 2023 12:52
@rv0lt rv0lt self-assigned this Sep 20, 2023
@rv0lt rv0lt marked this pull request as ready for review September 20, 2023 07:28
@rv0lt rv0lt changed the title added start time Added sto4_start_time column to be initialized on unit creation Sep 20, 2023
Copy link
Member

@i-oden i-oden left a comment

Choose a reason for hiding this comment

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

Also we'll need to change the test dds_web/tests/test_commands.py::test_create_new_unit_success so that it checks that the sto4_start_time variable is set. In this case it would be good if you checked that only all sto4* variables were set and not sto2*.

dds_web/commands.py Outdated Show resolved Hide resolved
@rv0lt
Copy link
Member Author

rv0lt commented Sep 21, 2023

@i-oden Should I also add checks for the rest of the parameters now that I am modiying this test. As right now only checks that the name was correct ?

@i-oden
Copy link
Member

i-oden commented Sep 21, 2023

@i-oden Should I also add checks for the rest of the parameters now that I am modiying this test. As right now only checks that the name was correct ?

Yeah, you can do that, thanks

@rv0lt rv0lt requested a review from i-oden September 21, 2023 13:10
tests/test_commands.py Show resolved Hide resolved
Copy link
Member

@i-oden i-oden left a comment

Choose a reason for hiding this comment

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

Looks good!

@i-oden
Copy link
Member

i-oden commented Sep 21, 2023

@rv0lt just rerun the tests, there's no actual error. We know about this bug since before, it does this sometimes

@i-oden i-oden removed the request for review from valyo September 21, 2023 13:55
@rv0lt rv0lt merged commit 042adcd into dev Sep 21, 2023
15 checks passed
@rv0lt rv0lt deleted the DDS-1668-Set-sto4_start_time-in-command-create_unit branch September 21, 2023 14:20
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