- Jun 24, 2019
-
-
sarsonl authored
On testing the relationships for LiteratureSource and CreationInfo, it was found that they were not one to one, although they were one to one on the schema level. An extra parameter was added to the relationships on the parent side, backref=().
-
- Jun 21, 2019
-
-
sarsonl authored
-
sarsonl authored
-
sarsonl authored
The unit tests have now been fixed to run without error and some information has been added to the readme file, but this has gaps. The app file has had an extra warning added correctly informing the user that a config file does not exist rather than the config section not existing.
-
sarsonl authored
Exploring the usage of the WS with Postgresql, it was found that the column names for flattened tables LiteratureSource etc. were too long for the character limit, and these were truncated so that the db could not be built. The >63 char limit meant that the only sensible solution was to reimplement the table structure as being nested tables. Test files have also been moved to appropriately named folders. Also some cleaning up of moved files was done.
-
sarsonl authored
The datetimes output from the schema will always be utc, with a timezone of 0, so the timestamp has been removed.
-
sarsonl authored
There is a specific case where if hydraulic query parameters are used and these filter out all the hydraulic children, then nothing was returned. We thought the expection should be that if there are no matching children, the parents should still be returned if they are valid. Validation on query parameters has also been updated in accordance with the Ramsis core code so that these match.
-
sarsonl authored
When datetime query parameters were used to filter hydraulics, The sections of the borehole would all be returned regardless of the section epoch time. Now logic has been added to also filter sections on epoch time if this does not overlap with the hydraulic search criteria. A test case was added to the populate_db_cases.py to test.
-
sarsonl authored
Previously this route would always return a list, although more than one JSON boject would never be returned.
-
sarsonl authored
Flask migrate functionality was added as this might be required in the future of using postresql. Some print statements were removed with this commit.
-
sarsonl authored
The SQLite db and the code that generates the content for this populate_db_test_cases.py has been added. Some small changes made to comments and docstrings in files. Addition of manage.py to manage migration within the postgresql db. This is not finished at present.
-
sarsonl authored
Some refactoring of code was required to make the code cleaner. Added more validation to the schema based on what input data is allowed. Centralised the column prefix m_ Added more docstrings.
-
sarsonl authored
Cross-code change to the way the schemas have been implemented and where they are used. Each fields that will be output from a schema is uniquely referenced so that the same schema can be used for validataion on deserialization and also for producing json output. Added measured_depth to the borehole level. Using a custom parser with strict validation on the input query parameters, as when using webargs, inputing a parameter that is not included in the schema would not return an error. I have added the tests for the strict.py parser file but these do not pass yet.
-
sarsonl authored
It was decided that it would be sensible if the column key closely matched to the attribute name. Previously this was deeply nested and made very long and confusing attribute names. Have also added the ability to give a different column name to the attribute name.
-
sarsonl authored
As it didn't belong in an existing file, this has been moved. The tests and the code are currently unfinished, further testing required.
-
sarsonl authored
It was decided that it was a cleaner implementation to name the ORM columns and ORM attributes differently. This is cleaner without having to reference the m_ prefix all the time, and the user should not have to know about this. To avoid having m_ prefix on the attributes but still maintaining prefix on column keys required an extra arg to be added to most functions. Also fixed the bug where if an attribute was previously called: m_literaturesource_m_literaturesource_creator_m_\ literaturesource_creator_person_givenname it would now be called: m_literaturesource_literaturesource_creator_\ literaturesource_creator_person_givenname (m_'s removed from within the name) Question raised about whether we want the attribute to be called: m_literaturesource_creator_person_givenname but on attempting to modify this, an mapping error is called.
-
sarsonl authored
-
sarsonl authored
Implemented cleaner way of doing column comparison to input query parameters. No functionality currently to do specialised filters which use joins, but this use will be added if and when required. Unit tests writen for new class.
-
- May 06, 2019
- May 05, 2019
-
-
damb authored
-
- May 03, 2019
- May 02, 2019
- Apr 30, 2019