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/al2 updates #421

Open
wants to merge 44 commits into
base: master
Choose a base branch
from
Open

Feat/al2 updates #421

wants to merge 44 commits into from

Conversation

EliseCastle23
Copy link
Contributor

Improvements

adding gunicorn and nginx to sheepdog and basing off our new secure python image

Copy link

The style in this PR agrees with black. ✔️

This formatting comment was generated automatically by a script in uc-cdis/wool.

Copy link

Please find the ci env pod logs here

Copy link

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here



def pre_fork(server, worker):
time.sleep(random.uniform(0, 2))
Copy link
Contributor

Choose a reason for hiding this comment

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

can we add some comments about the reasoning for this? And is there a reason we do this here but not in other services like indexd?

pyproject.toml Outdated
requests = ">=2.31.0,<3.0.0"
simplejson = ">=3.8.1"
sqlalchemy = ">=1.3.*"
cdispyutils = ">=2.0.1"
psqlgraph = ">=3.0.1"
cdiserrors = ">=1.0.0"
cdislogging = ">=1.0.0"
gen3dictionary = ">=2.0.3"
gen3datamodel = ">=3.1.0"
gen3dictionary = {git = "https://github.com/uc-cdis/datadictionary.git", branch = "chore/add-unit-tests"}
Copy link
Contributor

Choose a reason for hiding this comment

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

this needs to move off the branch

pyproject.toml Outdated
psycopg2 = ">=2.8.4"
PyYAML = ">=5.4.1"
psycopg2-binary = ">=2.8.4"
PyYAML = "*"
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd like to keep using >= so we don't accidentally downgrade

Copy link

github-actions bot commented Nov 1, 2024

Pull Request Test Coverage Report for Build 11800882673

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 28 unchanged lines in 1 file lost coverage.
  • Overall coverage increased (+0.07%) to 61.97%

Files with Coverage Reduction New Missed Lines %
api.py 28 0.0%
Totals Coverage Status
Change from base Build 10997391416: 0.07%
Covered Lines: 2353
Relevant Lines: 3797

💛 - Coveralls

Copy link

github-actions bot commented Nov 8, 2024

Please find the ci env pod logs here

Copy link

github-actions bot commented Nov 9, 2024

Please find the ci env pod logs here

Copy link

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

Dockerfile Outdated Show resolved Hide resolved
bin/pyproject.toml Outdated Show resolved Hide resolved
bin/settings.py Show resolved Hide resolved
dockerrun.bash Outdated Show resolved Hide resolved
Copy link

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

jawadqur
jawadqur previously approved these changes Nov 18, 2024
Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#f14c4c}{\tt{failed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#666666}{\tt{0}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#f14c4c}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{6}}$$ $$\textcolor{#f14c4c}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#f14c4c}{\tt{9}}$$
$$\textcolor{#f14c4c}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{19}}$$ $$\textcolor{#f14c4c}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#f14c4c}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#f14c4c}{\tt{error}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#f14c4c}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#f14c4c}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#f14c4c}{\tt{15}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#666666}{\tt{0}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#f14c4c}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#f14c4c}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#f14c4c}{\tt{24}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

Copy link

filepath $$\textcolor{#23d18b}{\tt{passed}}$$ $$\textcolor{#ffa500}{\tt{skipped}}$$ SUBTOTAL
$$\textcolor{#ffa500}{\tt{tests/test\_graph\_submit\_and\_query.py}}$$ $$\textcolor{#23d18b}{\tt{13}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{14}}$$
$$\textcolor{#ffa500}{\tt{tests/test\_data\_upload.py}}$$ $$\textcolor{#23d18b}{\tt{8}}$$ $$\textcolor{#ffa500}{\tt{1}}$$ $$\textcolor{#ffa500}{\tt{9}}$$
$$\textcolor{#ffa500}{\tt{TOTAL}}$$ $$\textcolor{#23d18b}{\tt{21}}$$ $$\textcolor{#ffa500}{\tt{2}}$$ $$\textcolor{#ffa500}{\tt{23}}$$

Please find the detailed integration test report here

Please find the ci env pod logs here

@@ -152,10 +152,6 @@ def app_init(app):
db_init(app)
# exclude es init as it's not used yet
# es_init(app)
try:
app.secret_key = app.config["FLASK_SECRET_KEY"]
Copy link
Contributor

Choose a reason for hiding this comment

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

why are we removing this? Flask requires this to read/write session iirc.

Choose a reason for hiding this comment

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

We were removing settings from GDC, that we could not find references to in code.

Interesting that none of the unit/ integration tests cover this if this is managing sessions 🤔

Happy to put this back in if you think if we still need it.

Copy link
Contributor

Choose a reason for hiding this comment

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

It's used internally by Flask. We should not remove it. https://flask.palletsprojects.com/en/stable/quickstart/#sessions

It's possible that sheepdog doesn't use any Flask session stuff right now, but I would rather just leave this in so it's already configured if someone uses it in the future. And if there is use of this, if we remove it, the sessions will all be unreadable

Copy link

@piotrsenkow piotrsenkow left a comment

Choose a reason for hiding this comment

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

It looks good to me!

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.

5 participants