Skip to content

Conversation

@richfitz
Copy link
Member

@richfitz richfitz commented May 15, 2025

This repo has rotted quite poorly, which is not surprising as it dates back to some pretty old versions of the refactor and has not really been looked at since.

We have moved how parameters are referenced in ways that are causing issues - using orderly3::orderly_parameters in particular causes the metadata parse to fail in pretty bad and confusing ways:

Error:
! orderly function 'orderly_parameters' can only be used at the top level
Run `rlang::last_trace()` to see where the error occurred.

(this is because we see :: as the function call and not orderly2 as the first arg, I think). This PR fixes that but also:

  • uses the new filename (e.g., parameters/parameters.R not parameters/orderly.R
  • uses the new approach of orderly_parameters returning a list
  • removes the .outpack directory that should not have been saved here really - I think this is largely ok but have added a script to untar the previous set of data so if we do need that in tests it will be easy
  • adds a simple check script that checks that all reports added can be run, with an action to trigger this
  • updates the readme

The only use I can find on gh is in packit-deploy, so we can safely update the name here too once I have that repo passing against this

@richfitz richfitz marked this pull request as ready for review May 16, 2025 10:16
@richfitz richfitz requested a review from EmmaLRussell May 16, 2025 10:30
Copy link
Contributor

@EmmaLRussell EmmaLRussell left a comment

Choose a reason for hiding this comment

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

Works for me!

So is the idea that if you want to add a new packet to this, say, you would add it to src, and to the check script, and would then need to package it all into a new version of _outpack.tar? Might be worth mentioning this in the README - maybe even provide a pack-outpack script too?

Comment on lines +8 to +12
orderly2::orderly_init()
orderly2::orderly_run("parameters", list(a = 10, c = 30))
orderly2::orderly_run("explicit")
orderly2::orderly_run("depends")
orderly2::orderly_run("computed-resource")
Copy link
Contributor

Choose a reason for hiding this comment

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

Want to add any further checks here that expected output is produced, or can we just assume that orderly2 would have thrown if something weird happened?

Copy link
Member Author

Choose a reason for hiding this comment

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

This script would have errored with the previous version - it's just a smoke test and we can expand it if things rot. Output expectations are already pretty heavily tested in orderly2 itself

@richfitz
Copy link
Member Author

So is the idea that if you want to add a new packet to this, say, you would add it to src, and to the check script, and would then need to package it all into a new version of _outpack.tar? Might be worth mentioning this in the README - maybe even provide a pack-outpack script too?

Yes, I think so - the original set were added by Alex when the repo was created but I've not inspected the metadata to work out what was run (that should be possible). I'm not sure how much, if at all these are even used tbh, or if the use depends on specific ids. The only place that they are used at all that I can see is packit-deploy and if the packets themselves are not actually used we might just drop them from here entirely

@richfitz richfitz merged commit 532287a into main May 21, 2025
1 check passed
@david-mears-2
Copy link

david-mears-2 commented Jun 3, 2025

if the packets themselves are not actually used we might just drop them from here entirely

I've used them while developing packit-deploy, running it locally, so that I can see that the app works as expected (it needs to be initialised with some packets for me to be confident about this). But because this repo wasn't working, I mirrored it at https://github.com/david-mears-2/orderly2-demos (before this PR happened) and used that

@richfitz
Copy link
Member Author

richfitz commented Jun 3, 2025

You should be able to use the script here (scripts/unpack-outpack) to unpack these packets; if they are not working for you can we please fix this repo and document the workflow rather than having dependencies on unknown personal copies?

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.

4 participants