Skip to content
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

Create artefact store object #301

Merged
merged 35 commits into from
Apr 25, 2024

Conversation

hiker
Copy link
Collaborator

@hiker hiker commented Apr 12, 2024

This fixes a #TODO, and prepares for #300.

hiker and others added 30 commits March 1, 2024 08:09
Minor documentation update for #277.
@hiker hiker requested a review from MatthewHambley April 12, 2024 04:45
Copy link
Collaborator

@MatthewHambley MatthewHambley left a comment

Choose a reason for hiding this comment

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

No major issues here.

I imagine our future contains a long and involved discussion about redesigning and refactoring the way artefacts are stored and managed but in the mean time this tidies up the current implementation a little.

It also starts the move away from random anonymous data structures and towards properly structured objects.

source/fab/artefacts.py Show resolved Hide resolved
source/fab/build_config.py Outdated Show resolved Hide resolved
source/fab/artefacts.py Show resolved Hide resolved
@hiker
Copy link
Collaborator Author

hiker commented Apr 23, 2024

OK, I don't know what to do about the type information, please advise ;)

@hiker
Copy link
Collaborator Author

hiker commented Apr 23, 2024

I imagine our future contains a long and involved discussion about redesigning and refactoring the way artefacts are stored and managed but in the mean time this tidies up the current implementation a little.

Hmm - not really, it seems to work :) The only question I have is in #300: for the follow-up PR, do you prefer to have methods for certain standard artefacts (e.g. all f90 files, i.e. all files to be compiled by Fortran, ...), or do you prefer to have some constants exposed and use them in the standard way?

Otherwise ready for next review.

@hiker hiker requested a review from MatthewHambley April 23, 2024 12:52
@hiker
Copy link
Collaborator Author

hiker commented Apr 23, 2024

Gee, python-specific error messages - annoying.

Copy link
Collaborator

@MatthewHambley MatthewHambley left a comment

Choose a reason for hiding this comment

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

I think we're ready to move on to the next change in the sequence.

# 3.8: ... with abstract method
# 3.12: ... without an implementation for abstract
# so we only test for the begin which is identical:
assert "Can't instantiate abstract class MyClass with" in str(err.value)
Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't mind the "belt and braces" approach here but I think the actual error message is of secondary importance. The key thing is that the exception is thrown.

source/fab/build_config.py Outdated Show resolved Hide resolved
source/fab/artefacts.py Show resolved Hide resolved
@MatthewHambley MatthewHambley merged commit 4eb9a4d into MetOffice:master Apr 25, 2024
4 checks passed
@hiker hiker deleted the create_artefact_store branch April 29, 2024 04:50
@hiker hiker mentioned this pull request Jul 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants