-
Notifications
You must be signed in to change notification settings - Fork 2
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
Manage development.ini and test.ini outside of source control #1727
Conversation
…escribed in cgap-portal PR 637 (and a fix from cgap-portal PR 642).
@@ -88,6 +88,7 @@ build-after-poetry: # continuation of build after poetry install | |||
make npm-setup-if-needed | |||
poetry run python setup_eb.py develop | |||
make fix-dist-info | |||
poetry run prepare-local-dev |
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.
You might want to ensure inserts are loaded when this is run
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.
I'm not sure I understand why inserts are relevant to this. This is just about setting up details that need to be user-specific, like the indexing prefix. Can you elaborate on your concern?
Yes, this is a very old PR. I was surprised it was never merged, but it fortunately seems not to have gotten stale, so I'm trying to revive it.
Local testing results:
|
I've also deployed this branch to |
This PR is conceptually identical to cgap-portal PR 637 but with the fix already incorporated that we later ended up needing as cgap-portal PR 642.
This change is intended only to affect developers who are doing local testing (e.g.,
make test
or a call topytest
) that would usetest.ini
or who are doing local deploys (e.g.,make deploy1
) that would usedevelopment.ini
.This is technically a breaking change, in that it may affect developer scripts, but this should not affect production builds or GA, so we've agreed to only bump the minor version, not the major version. Nevertheless, you should report problems in production, GA, or docker management if you see them.**
Prior to this change,
development.ini
andtest.ini
were in source control. This PR changes this so that what's in source control isdevelopment.ini.template
andtest.ini.template
. There is a command introduced,prepare-local-dev
that you can run to create adevelopment.ini
andtest.ini
. Once the file exists, theprepare-local-dev
command will not touch it, so you can do other edits as well without concern that they will get checked in. The primary change that this command does is to make a local environment offourfront-devlocal-<yourusername>
orfourfront-test-<yourusername>
so that testing and debugging that you do locally will be in an environment that does not collide with other users. You can give a--env
argument toprepare-local-dev
to use a different name, though it's probably easier to just edit the resulting file.Note to reviewers (especially @willronchetti): The
test.ini
case is a little weird because some things in that file are ignored. We might want to make it so thatconftest_settings.py
somehow pulls data from there or is consistent with there or figure out why they diverge and how to describe when to use one or the other.