Conversation
havok2063
left a comment
There was a problem hiding this comment.
Thanks for this! I've made some suggestions and comments in places to be addressed.
| ### fastapi and uvicorn Install | ||
| As noted above, valis uses fastapi. So first install fastapi and uvicorn. See the [fastapi tutorial](https://fastapi.tiangolo.com/tutorial/) for an introduction to fastapi. | ||
| ``` | ||
| pip install "fastapi[standard]" | ||
| pip install "uvicorn[standard]" | ||
| ``` | ||
|
|
There was a problem hiding this comment.
You don't need this section. These dependencies are installed automatically.
| pip install "uvicorn[standard]" | ||
| ``` | ||
|
|
||
| ### valis Developer Install |
There was a problem hiding this comment.
This can be renamed back to "Developer Install"
| ``` | ||
| git clone https://github.com/sdss/valis valis | ||
| cd valis | ||
| uv pip install |
There was a problem hiding this comment.
This should be
| uv pip install | |
| uv sync --python 3.12 |
| ``` | ||
| git clone git@github.com:sdss/datamodel.git | ||
| cd datamodel | ||
| pip install -e ".[test]" |
There was a problem hiding this comment.
Since this project uses uv venvs, this should be
| pip install -e ".[test]" | |
| uv pip install -e /your/path/to/sdss/datamodel/ |
Replace with your full path to the cloned datamodel project.
| ### Local Development | ||
|
|
There was a problem hiding this comment.
Please move this section back to where it was.
| ``` | ||
|
|
||
| Alternatively, if you don't want to edit your .pgpass file then set the VALIS_DB_PASS environment variable with your database password. See step 4. | ||
| If for some reason, you do not want to edit your .pgpass file then set the VALIS_DB_PASS environment variable with your database password. This is shown in step 3. |
|
|
||
| Additionally, you can set the environment variable `VALIS_DB_RESET=false` or add `db_reset: false` to `valis.yaml`. This will prevent the DB connection to be closed after a query completes and should speed up new queries. This setting should not be used in production. | ||
|
|
||
| ### Local Development |
There was a problem hiding this comment.
Move this back to where it was.
| ## Deployment | ||
|
|
||
| This section describes a variety of deployment methods. Valis uses gunicorn as its | ||
| This section describes a variety of valis deployment methods so you can skip this section if you are only interested in valis development. |
There was a problem hiding this comment.
This is a run-on. Suggest the following..
| This section describes a variety of valis deployment methods so you can skip this section if you are only interested in valis development. | |
| This section describes a variety of valis deployment methods. Skip this section if you are only interested in development. |
| ssh -L 6000:localhost:5432 pipe | ||
| ``` | ||
| 3. Update your `~/.pgpass` file with the following lines. Replace `port`, `unid`, and `password`, with your tunneled port (e.g. 6000 in step 2), Utah unid (e.g. u1234567), and db password, respectively. | ||
| 2. Update your `~/.pgpass` file with the following lines. Replace `port`, `unid`, and `password`, with your tunneled local port (e.g. 6000 in step 1), Utah unid (e.g. u1234567), and db password, respectively. |
| If for some reason, you do not want to edit your .pgpass file then set the VALIS_DB_PASS environment variable with your database password. This is shown in step 3. | ||
|
|
||
| 4. Set the following environment variables. | ||
| 3. Set the following environment variables. |
|
Hi Brian,
I have made the changes to the valis readme branch.
Thanks!
Pramod
________________________________________
From: Brian Cherinka ***@***.***>
Sent: Tuesday, May 19, 2026 7:09 AM
To: sdss/valis
Cc: Pramod Gupta; Author
Subject: Re: [sdss/valis] edit README.md (PR #92)
@havok2063 requested changes on this pull request.
Thanks for this! I've made some suggestions and comments in places to be addressed.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266769129__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0Zsvdc3R9EAmo$>:
+### fastapi and uvicorn Install
+As noted above, valis uses fastapi. So first install fastapi and uvicorn. See the [fastapi tutorial](https://fastapi.tiangolo.com/tutorial/<https://urldefense.com/v3/__https://fastapi.tiangolo.com/tutorial/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcjHhDlfw$>) for an introduction to fastapi.
+```
+pip install "fastapi[standard]"
+pip install "uvicorn[standard]"
+```
+
You don't need this section. These dependencies are installed automatically.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266772607__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcjiPzuQ4$>:
## Installation
First, follow the [uv installation instructions](https://docs.astral.sh/uv/getting-started/installation/<https://urldefense.com/v3/__https://docs.astral.sh/uv/getting-started/installation/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdctYV2pKc$>).
It is recommended to work within an isolated virtual environment like `conda` or `venv`. You can create a uv venv with `uv venv valis --python 3.12`. See [uv Environments](https://docs.astral.sh/uv/pip/environments/<https://urldefense.com/v3/__https://docs.astral.sh/uv/pip/environments/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcTJuN4EI$>) for more info.
-### Developer Install
+### fastapi and uvicorn Install
+As noted above, valis uses fastapi. So first install fastapi and uvicorn. See the [fastapi tutorial](https://fastapi.tiangolo.com/tutorial/<https://urldefense.com/v3/__https://fastapi.tiangolo.com/tutorial/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcjHhDlfw$>) for an introduction to fastapi.
+```
+pip install "fastapi[standard]"
+pip install "uvicorn[standard]"
+```
+
+### valis Developer Install
This can be renamed back to "Developer Install"
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266887233__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcFE1Y3mk$>:
## Installation
First, follow the [uv installation instructions](https://docs.astral.sh/uv/getting-started/installation/<https://urldefense.com/v3/__https://docs.astral.sh/uv/getting-started/installation/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdctYV2pKc$>).
It is recommended to work within an isolated virtual environment like `conda` or `venv`. You can create a uv venv with `uv venv valis --python 3.12`. See [uv Environments](https://docs.astral.sh/uv/pip/environments/<https://urldefense.com/v3/__https://docs.astral.sh/uv/pip/environments/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcTJuN4EI$>) for more info.
-### Developer Install
+### fastapi and uvicorn Install
+As noted above, valis uses fastapi. So first install fastapi and uvicorn. See the [fastapi tutorial](https://fastapi.tiangolo.com/tutorial/<https://urldefense.com/v3/__https://fastapi.tiangolo.com/tutorial/__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcjHhDlfw$>) for an introduction to fastapi.
+```
+pip install "fastapi[standard]"
+pip install "uvicorn[standard]"
+```
+
+### valis Developer Install
```
git clone https://github.com/sdss/valis<https://urldefense.com/v3/__https://github.com/sdss/valis__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdchHJDwNo$> valis
cd valis
uv pip install
This should be
⬇️ Suggested change
-uv pip install
+uv sync --python 3.12
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266901673__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdczxrRCjY$>:
```
git clone https://github.com/sdss/valis<https://urldefense.com/v3/__https://github.com/sdss/valis__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdchHJDwNo$> valis
cd valis
uv pip install
```
+### datamodel Developer Install
+valis uses sdss/datamodel so install it as shown below.
+```
+git clone ***@***.***:sdss/datamodel.git
+cd datamodel
+pip install -e ".[test]"
Since this project uses uv venvs, this should be
⬇️ Suggested change
-pip install -e ".[test]"
+uv pip install -e /your/path/to/sdss/datamodel/
Replace with your full path to the cloned datamodel project.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266903765__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcxBclzA4$>:
-### Local Development
-
Please move this section back to where it was.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266914792__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcWgxLfd4$>:
@@ -70,19 +75,19 @@ Host pipe
ForwardX11Trusted yes
ProxyCommand ssh -A ***@***.*** nc %h %p
```
-2. In a terminal, create an ssh tunnel to the pipelines database localhost port 5432, to a some local port. E.g. this maps the remote db localhost port 5432 to local machine on port 6000.
+1. In a terminal, create an ssh tunnel to the pipelines database localhost port 5432, to a some local port. E.g. this maps the remote db localhost port 5432 to local machine on port 6000.
This is step 2. Please keep my prior README changes.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266918030__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcRw2nRS0$>:
```
localhost:[port]:*:[unid]:[password]
host.docker.internal:[port]:*:[unid]:[password]
```
-Alternatively, if you don't want to edit your .pgpass file then set the VALIS_DB_PASS environment variable with your database password. See step 4.
+If for some reason, you do not want to edit your .pgpass file then set the VALIS_DB_PASS environment variable with your database password. This is shown in step 3.
Please keep my changes.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266919460__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0Zsvdc4MTAVLY$>:
@@ -99,9 +104,26 @@ db_user: {unid}
Additionally, you can set the environment variable `VALIS_DB_RESET=false` or add `db_reset: false` to `valis.yaml`. This will prevent the DB connection to be closed after a query completes and should speed up new queries. This setting should not be used in production.
+### Local Development
Move this back to where it was.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266925003__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcmeG71Ro$>:
## Deployment
-This section describes a variety of deployment methods. Valis uses gunicorn as its
+This section describes a variety of valis deployment methods so you can skip this section if you are only interested in valis development.
This is a run-on. Suggest the following..
⬇️ Suggested change
-This section describes a variety of valis deployment methods so you can skip this section if you are only interested in valis development.
+This section describes a variety of valis deployment methods. Skip this section if you are only interested in development.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266932150__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0Zsvdc8zjWOb4$>:
```
ssh -L 6000:localhost:5432 pipe
```
-3. Update your `~/.pgpass` file with the following lines. Replace `port`, `unid`, and `password`, with your tunneled port (e.g. 6000 in step 2), Utah unid (e.g. u1234567), and db password, respectively.
+2. Update your `~/.pgpass` file with the following lines. Replace `port`, `unid`, and `password`, with your tunneled local port (e.g. 6000 in step 1), Utah unid (e.g. u1234567), and db password, respectively.
This is step 3.
________________________________
In README.md<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*discussion_r3266933577__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcwvWsoUc$>:
-4. Set the following environment variables.
+3. Set the following environment variables.
Step 4.
—
Reply to this email directly, view it on GitHub<https://urldefense.com/v3/__https://github.com/sdss/valis/pull/92*pullrequestreview-4319522368__;Iw!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcNj31J9U$>, or unsubscribe<https://urldefense.com/v3/__https://github.com/notifications/unsubscribe-auth/AOTAX477IDGEA3RWPM3XWUL43RTI3AVCNFSM6AAAAACZBNBVA2VHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHM2DGMJZGUZDEMZWHA__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcVsUquSk$>.
Triage notifications on the go with GitHub Mobile for iOS<https://urldefense.com/v3/__https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675__;!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0Zsvdc3zaAQYk$> or Android<https://urldefense.com/v3/__https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign*3Dnotification-email*26utm_medium*3Demail*26utm_source*3Dgithub__;JSUlJSU!!K-Hz7m0Vt54!ijg5i8P1xhRTZJdrCGd4Szmf5vFsJjQnAgV_DexePhMMocYDyafxSiIX0csmczm3Yp6qlLvzkz0ZsvdcKUpF_ms$>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
| If you modify the valis code (e.g. by creating a new route) then | ||
| do the below steps to so that uvicorn uses the new valis code. | ||
| First stop uvicorn by CTRL+C and then run the above uvicorn command | ||
| to start valis. |
There was a problem hiding this comment.
This paragraph isn't needed. In development, if you run with the --reload flag, you don't need to stop the app and restart. It hot reloads on watched changes. You just refresh the browser.
| ### datamodel Developer Install | ||
| valis uses sdss/datamodel so install it as shown below. | ||
| ``` | ||
| git clone git@github.com:sdss/datamodel.git |
There was a problem hiding this comment.
| git clone git@github.com:sdss/datamodel.git | |
| git clone https://github.com/sdss/datamodel.git |
No description provided.