- Apr 02, 2021
-
-
vlorentz authored
There were some typos in the factory's documentation, and the instances were not documented at all.
-
- Mar 26, 2021
- Mar 03, 2021
-
-
Antoine Lambert authored
Ensure tests can be executed using hypothesis >= 6 by suppressing the function_scoped_fixture health check on test that uses a function scope fixture in combination with @given that does not need to be reset between individual hypothesis examples.
-
- Feb 16, 2021
-
- Jan 20, 2021
-
-
Antoine R. Dumont authored
This fixes build [1] [1] https://jenkins.softwareheritage.org/view/swh%20master/job/DCORE/job/tests/1183/console
-
- Dec 11, 2020
-
-
Antoine Lambert authored
It exists cases where a custom exception type cannot be rebuilt from its serialized form. As a fallback, build a base Exception with the message of the serialized exception.
-
David Douard authored
decoding custom format is still supported for backward compat. Note that this revision modifies the exception type raised when attempting to encode a naive datetime object for both formats (json amd msgpack): it now raises a TypeError instead of a ValueError.
-
David Douard authored
to make it clear which codecs are specific to the json format.
-
David Douard authored
instead of json.dumps(..., cls=SWHJSONEncoder) and so. This simplify a bit the code and make sure the json_dumps/loads functions are actually tested.
-
- Dec 08, 2020
-
-
David Douard authored
it should not be used anymore.
-
David Douard authored
we should be free of them by now. The journal has been recreated from scratch since then.
-
- Nov 27, 2020
-
-
Nicolas Dandrimont authored
This allows users to pass multiple --log-level values to the swh cli, to allow finer grained configuration of the logging of some modules, without having to resort to a full-fledged, very verbose log config file. Close T2819.
-
Nicolas Dandrimont authored
We now match the command line output per section, in a fuzzier way than before.
-
- Nov 26, 2020
-
-
Thibault Allançon authored
-
- Nov 24, 2020
-
-
Nicolas Dandrimont authored
The previous implementation would always append extra_encoders to the main ENCODERS list. Refactor encoder and decoder extensions both with a common getter which doesn't mutate the global variable.
-
Nicolas Dandrimont authored
This is to support some of the metadata imported from npm package.jsons in revisions.
-
- Nov 23, 2020
-
-
Antoine R. Dumont authored
Those db utilities were only used within swh.core. By dropping those, we can then stop installing pifpaf within tox for the db tests. The tests are now probably faster than before as well.
-
Antoine Lambert authored
-
Antoine Lambert authored
-
- Nov 20, 2020
-
-
Antoine R. Dumont authored
This renames the test file to test_pytest_plugin which is clearer since it relates to the actual module being tested. This also moves the tests into its own dedicated arborescence because that's a different module now.
-
Antoine R. Dumont authored
This drops the pytest-postgresql from requirements-db.txt. This is not a required dependency for the swh.core.db module itself. It's a requirement for the swh.core.db.pytest_plugin. This module should become its own module as a test requirements for other swh modules (including swh.core.db but not limited to it). So this commit adds a dedicated requirements-db-pytestplugin.txt file with such dependency. This opens the db-pytestplugin key within the setup.py and then references that test dependency for the swh.core.db modules (as it's needed for tests of the module). Related to T2746
-
Antoine Lambert authored
Reraising exceptions in RPCClient was not honored anymore due to a mistake introduced in last commit.
-
Antoine Lambert authored
An exception can be constructed with another exception argument so handle that special case by adding a dedicated encoder and decoder to avoid remote exception serialization error.
-
- Nov 19, 2020
-
-
Antoine Lambert authored
-
- Oct 30, 2020
-
-
Antoine R. Dumont authored
This explicitely checks the different scenario possible with the current subcommands (create, init-admin, init). Using a subset of sql schema representation we have in our existing datasets. Closes T2741
-
- Oct 29, 2020
-
-
Tenma authored
Both requests.Request and _pytest.FixtureRequest objects are passed to test fixtures as argument 'request'. This hurts readability. Adding typing annotations makes it clear which one is meant.
-
- Oct 28, 2020
-
-
Antoine R. Dumont authored
In staging, the db is already created by puppet, the current create database stanza forced within the create-db cannot work. Ths subsequent steps of postgresql extensions installation is required though. This will allow it. Related to T2736
-
- Oct 23, 2020
-
-
Antoine R. Dumont authored
Fixes build [1] [1] https://jenkins.softwareheritage.org/job/DENV/job/tests/lastBuild/artifact/swh-core.log
-
- Oct 22, 2020
-
-
Antoine R. Dumont authored
-
Antoine R. Dumont authored
-
Antoine R. Dumont authored
This also adds more tests around the instantiation of such servers.
-
Antoine R. Dumont authored
Defining 'pytest_plugins' in a non-top-level conftest is no longer supported because it affects the entire directory tree in a non-explicit way.
-
Antoine R. Dumont authored
This will allow to align the Vault's client/server code with the other rpc servers. And start adding one typed interface with more consistent checks in between implementations.
-
- Oct 21, 2020
-
-
Antoine R. Dumont authored
This moves the SWHDatabaseJanitor from swh.storage to swh.core. This also adds tests to it. This will allow to share the behavior on other swh services with postgres backends (vault, scheduler, etc...).
-
- Oct 19, 2020
-
-
Antoine R. Dumont authored
-
- Oct 07, 2020
-
-
Antoine R. Dumont authored
All clients of this (loader, lister, indexer...) have migrated to use `load_from_envvar` or some derivative (pre-load_from_envvar) of it (deposit) instead. Related to T1532
-
- Oct 02, 2020
-
-
Antoine R. Dumont authored
That new function declares exactly what happens today during our configuration loading (for loader/lister/indexer/... and rpc services in general not for the CLIs which will be dealt with later). Loads and parses the yaml configuration file out of the SWH_CONFIG_FILENAME environment variable. Allowing eventual dict enrichment with default configuration if provided. Related to T1532
-
- Sep 30, 2020
-
-
vlorentz authored
A class should only inherit from UserList if the type of data it presents is the same as the data in the 'data' attribute, which isn't true here. This means, for example, that SortedList.__contains__ checked if the value is in self.data, which always returns False (unless unlucky, but then it returns True while it shouldn't). By removing this inheritance, methods that are no longer implemented no longer default to a buggy implementation.
-
- Sep 25, 2020
-
-
Nicolas Dandrimont authored
We used to log all task arguments, which was a bit too much for the logging pipeline to handle. Now that a lot of tasks arguments have been "canonicalized", we can go back to logging some specific arguments directly. Use the opportunity to drop an unused argument and improve the documentation of these logging-related functions.
-