Wolfgang Walther and Wolfgang Walther
af2788468e
Add basic error handling to --dump-schema
2021-01-02 13:50:19 +01:00
Wolfgang Walther
cc54135bf0
Rename master branch to main; replace whiteList with isAllowed
2020-12-31 14:37:52 +01:00
Wolfgang Walther and GitHub
519550e9af
Add codecov to README.md
2020-12-30 17:52:15 +01:00
Wolfgang Walther and Remo Rechkemmer
93541035f6
Fix postgrest-coverage throwing error when installed with nix-env
2020-12-30 16:38:13 +01:00
Wolfgang Walther and Remo Rechkemmer
568477b6af
Fix io tests not collecting coverage data when using run()
...
Before, postgrest was killed after each test and no coverage data was saved.
Now the process is terminated gracefully via SIGTERM first to allow writing the .tix file.
2020-12-30 14:51:58 +01:00
Wolfgang Walther and GitHub
c7f0d42323
Add postgrest-coverage to show and upload hpc reports to codecov
2020-12-30 13:22:25 +01:00
Wolfgang Walther and GitHub
2015688312
Fix spec test concurrency issue related to tx=commit on simple_pk
2020-12-29 23:58:37 +01:00
Wolfgang Walther and Wolfgang Walther
8e02551956
Fix "unused-imports" warning for windows build
2020-12-29 16:07:07 +01:00
Remo Rechkemmer and GitHub
96478ed016
Add docs to all checked shell scripts in nix
2020-12-28 13:23:12 +01:00
Gurjeet Singh and Steve Chavez
c3ad07fcc0
Minor grammar fix
2020-12-27 10:57:46 -05:00
Remo Rechkemmer and GitHub
2425cddaed
improve io-tests
...
Tests are now run through unix socket by default allowing
parallel execution. Test setup configuration is done via
environment variables instead of config files.
2020-12-24 16:09:25 +01:00
Wolfgang Walther and Wolfgang Walther
b5185de706
nix: add "cd $rootdir" to all shell scripts via checked-shell-script
2020-12-24 14:44:01 +01:00
Wolfgang Walther and Wolfgang Walther
56557c9c40
ci: remove broken travis coverage job
2020-12-23 19:39:40 +01:00
Wolfgang Walther and Wolfgang Walther
2cbe1ba903
feat: Add --example cli option to show example config file
2020-12-23 19:39:40 +01:00
Wolfgang Walther and Wolfgang Walther
69b459e7b6
Use environment variables for configuration in developer tooling
...
Avoid the need for configuration files for temporary database connections.
2020-12-23 19:39:40 +01:00
Wolfgang Walther and Wolfgang Walther
add326a79d
ci: skip postgrest-release-dockerhubdescription for nightly builds
2020-12-23 19:39:40 +01:00
Wolfgang Walther and Wolfgang Walther
b7fc393e49
feat: Read config directly from environment variables
...
resolves #1624
2020-12-23 19:39:40 +01:00
monacoremo and Steve Chavez
f2f639e484
update stack to lts-16.26
2020-12-23 09:39:36 -05:00
monacoremo and Steve Chavez
9cfc66a6a4
upgrade nixpkgs and apply related fixes
2020-12-23 09:39:36 -05:00
Remo Rechkemmer and GitHub
bf141ca13f
feat: Added --dump-schema CLI option to dump JSON of dbStructure schema cache.
...
Added postgrest-dump-schema to nix-shell returning a YAML dump of the test fixtures.
Authored-by: monacoremo <monacoremo>
2020-12-20 10:22:52 +01:00
monacoremo and Steve Chavez
fe09637711
catch ReadTimeout in IO tests
2020-12-17 17:05:03 -05:00
Wolfgang Walther and Wolfgang Walther
dbe3c163bd
run spec tests in parallel
...
reduces time to run postgrest-test-spec-all by 20-25%
2020-12-14 00:42:03 +01:00
monacoremo and Wolfgang Walther
a52c114ff4
add test for spec idempotence
2020-12-13 22:13:05 +01:00
Remo Rechkemmer and GitHub
71fa87937b
Migrate io-tests from bash to pytest
...
Authored-by: monacoremo <monacoremo>
2020-12-13 16:19:26 +01:00
Wolfgang Walther and Wolfgang Walther
0c25f12825
fix: fix output of RPCs returning scalar values with multiple rows
...
resolves #1584
BREAKING CHANGE:
Changed output of RPCs to match return type better:
* single scalar return: value (unchanged)
* setof scalar return: array of values (new; was array of objects)
* single composite return: object (new; was array of objects)
* setof composite return: array of objects (unchanged)
* void return: nothing (new; was "null")
A single OUT column is now treated as "composite" instead of "scalar",
i.e. consistent with multiple OUT columns.
2020-12-10 19:55:42 +01:00
Wolfgang Walther
093fd3c8f6
fix: fix embedding through views with subqueries inside function calls
...
resolves #1608
Refactors the pfkSourceColumns query to use an intermediate JSON format
for parsing. This allows much more robust extraction of source columns.
2020-12-10 19:48:05 +01:00
Steve Chavez and GitHub
ebd474a7e6
fix: retry connection on failed schema cache load ( #1685 )
...
Retry the connection when the
"Failed to load the schema cache" error happens.
Also die if the schema cache query has a syntax error.
2020-12-09 14:20:00 -05:00
Joshua Taillon and Wolfgang Walther
a4fe838308
Fix outdated environment variable for docker compose
...
Also removed a deprecated `links` setting from the docker-compose, since that's not needed any more
2020-12-08 21:09:46 +01:00
steve-chavez
11d62a8010
Prepared statement for set_config
2020-12-07 20:09:18 -05:00
steve-chavez
7069bb3c01
refactor: Change SET LOCAL gucs to set_config
2020-12-07 20:09:18 -05:00
Wolfgang Walther and Wolfgang Walther
9254f119f6
fix: implement robust parsing of boolean config values
...
resolves #1572
2020-12-06 21:59:32 +01:00
Wolfgang Walther and Wolfgang Walther
ed58511de3
feat: renamed config options with prefixes; added aliases for old names
...
* secret-is-base64 -> jwt-secret-is-base64
* role-claim-key -> jwt-role-claim-key
* max-rows -> db-max-rows
* pre-request -> db-pre-request
* root-spec -> db-root-spec
* db-schema -> db-schemas
This is not a breaking change, because aliases are added as well.
refactor: sorted all config keys alphabetically where applicable
2020-12-06 21:59:03 +01:00
Wolfgang Walther
ab3375998d
ci: fix cirrus low memory error
2020-12-06 20:49:48 +01:00
Wolfgang Walther and Wolfgang Walther
8979442e27
dev: add colors to io tests
2020-12-06 13:33:25 +01:00
Wolfgang Walther and Wolfgang Walther
eb46cf2662
added: cli option --dump-config prints loaded config and exits
...
This is most useful for automated tests for upcoming configuration
features. Can also be used for debugging.
2020-12-06 13:33:25 +01:00
Wolfgang Walther and Wolfgang Walther
d218a9eaff
dev: improve postgrest-watch experience
...
* speed up io tests
* avoid infinite loop while watching io tests
* improve auto-complete with postgrest-watch postgrest-run
* detect when files are added or deleted
2020-12-05 16:47:50 +01:00
Wolfgang Walther and Wolfgang Walther
7d6d015822
improve error output for io-tests and with_tmp_db
2020-12-03 22:32:07 +01:00
Wolfgang Walther and GitHub
609c9aead8
Make transaction-rollback=true the default for test-suite ( #1663 )
...
Change test-suite to use db-tx-rollback-all = true by default
2020-12-03 18:54:33 +01:00
monacoremo and Wolfgang Walther
10a70d4e52
add autocompletion for postgrest-watch
2020-12-01 22:13:41 +01:00
Wolfgang Walther and Wolfgang Walther
de5742fc7d
Make nix the one and only dev environment; remove obsolete tooling
2020-12-01 00:42:21 +01:00
Wolfgang Walther and Wolfgang Walther
1a5f6cce46
Add docker files to run nix dev environment on Windows
2020-12-01 00:42:21 +01:00
Wolfgang Walther and GitHub
f2cb91740e
Use cabal v2-exec to run io tests, include io tests in nix-shell by default; remove obsolete ncat dependency ( #1673 )
...
Use cabal v2-exec to run io tests, include io tests in nix-shell by default; remove obsolete ncat dependency
2020-12-01 00:37:45 +01:00
07cb47e6ac
Improve dev tools in the Nix environment ( #1666 )
...
* Improve dev tools in the nix environment
Added postgrest-build, postgrest-run, postgrest-clean, postgrest-check
and postgrest-watch tools. Changed order of postgrest-test-spec-all to
run backwards from pg13 to pg9.5. Added shellcheck to lint shell scripts
in nix environment.
Co-authored-by: monacoremo <monacoremo>
2020-11-30 22:21:19 +01:00
Wolfgang Walther and Wolfgang Walther
b0ba2f709c
remove Makefile and Pipfile
2020-11-30 21:35:33 +01:00
Wolfgang Walther and Wolfgang Walther
d6caa5dae9
make docs full-width, resolves #351
2020-11-29 23:55:41 +01:00
Wolfgang Walther and Wolfgang Walther
881170b9ff
Fix build warnings to satisfy postgrest-docs-build
2020-11-29 23:54:48 +01:00
Wolfgang Walther and Wolfgang Walther
634a0c70b7
Fix spelling to satisfy postgrest-docs-spellcheck
2020-11-29 23:54:48 +01:00
Wolfgang Walther and Wolfgang Walther
84e5597091
Add postgrest-docs-dictcheck to remove obsolete words from postgrest.dict
2020-11-29 23:54:48 +01:00
Wolfgang Walther and Wolfgang Walther
b83ee94fae
Add nix-shell tools, fix circleci, resolves #322
2020-11-29 23:54:48 +01:00
Miodrag Milić and steve-chavez
ea2e166aa1
Add chocolatey installation method
...
#369
2020-11-28 18:51:25 -05:00