Skip to content
This repository has been archived by the owner on Oct 3, 2024. It is now read-only.

Improve documentation & add shell script #8

Merged
merged 6 commits into from
Sep 30, 2024

Conversation

vberezhnev
Copy link
Contributor

No description provided.

@ichorid ichorid requested a review from automainint September 24, 2024 07:25
@ichorid ichorid marked this pull request as draft September 24, 2024 07:25
@ichorid ichorid marked this pull request as ready for review September 24, 2024 07:26
@automainint
Copy link
Collaborator

Thanks!

  • "See also" section is probably not relevant anymore and can be deleted.

  • "Env variables" section seems to me less readable now.

Basically it's just a copy from Dockerfile files without any additional info, like that default recv timeout is 10 seconds.
Maybe just put there links to Dockerfile instead.
I personally find it less cognitively heavy when I read the convenient value equivalent in seconds instead of ms.
But this is just style and not really important.

  • I see the lack of "Dev setup for manual testing" section.

This section is important, because it contains non-trivial information about dev environment.
Testing within docker containers is too slow, which is why I create dev environment manually and why this information can be helpful.
Also, this information explains how the building and testing works, e.g. it is important that tests must be run sequentially.
If this info to be removed from the README, it has to be present somewhere else (e.g. in comments for the code). But then it may be harder to find.

  • The section "How to launch project within Docker" seems to just explain basics of docker, while also lacking some details.

If someone already know how to deal with docker containers, it won't be helpful.
If someone doesn't know that, it probably should be a lot more detailed.
E.g. make a fully functional shell script that should work without modification (I see that in the current version it's not obvious why are there folders meritrank-service-rust and meritrank-psql-connector).
And add some explanations, e.g. why -e POSTGRES_PASSWORD=postgres is required.

  • In the "PSQL" section, this line now doesn't make sense:
DROP EXTENSION pgmer2; CREATE EXTENSION pgmer2;

In a new docker image we don't have to recreate the psql extension.
This is only required when we test iterative changes to the code. If we just rebuild the code, pgrx won't update the extension automatically. Maybe it's a good idea to add this explanation to the README.

Copy link
Collaborator

@automainint automainint left a comment

Choose a reason for hiding this comment

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

Thanks for the contribution!

See my previous comment.
Also, I suggest to always write some motivation for the changes in the PR description, and appropriate PR name.

@vberezhnev vberezhnev changed the title Update README.md Improve documentation & add shell script Sep 26, 2024
@vberezhnev
Copy link
Contributor Author

vberezhnev commented Sep 26, 2024

Thanks for the contribution!

See my previous comment. Also, I suggest to always write some motivation for the changes in the PR description, and appropriate PR name.

Thanks a ton for your specific recommendations on improving the documentation! I really appreciate your insights. I've made the updates based on your advice, but I thought it might be best to add the shell script a bit later. This way, you can take a look at the updated documentation while I work on the script in parallel. What do you think?

@automainint
Copy link
Collaborator

automainint commented Sep 26, 2024

This looks good

I think, it's best to insert shell scripts directly into README, since it's not a part of the source code and required just for convenience.
E.g. at the end of each top section add something like "Now, here's all the steps together: ..."

In the "How to launch manually" section, add an explanation that incremental code changes will require to reinstall the extension to test it manually with the command DROP EXTENSION pgmer2; CREATE EXTENSION pgmer2;

As I explained here, the primary development branch is dev, so I suggest to always merge into dev for future PRs.

@vberezhnev vberezhnev changed the base branch from main to dev September 27, 2024 10:57
@automainint automainint merged commit 8045961 into Intersubjective:dev Sep 30, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants