Skip to content

Fix: Pass through version in init=True case#254

Open
chillenzer wants to merge 1 commit intoResearchObject:masterfrom
chillenzer:fix-version-handling-in-init-mode
Open

Fix: Pass through version in init=True case#254
chillenzer wants to merge 1 commit intoResearchObject:masterfrom
chillenzer:fix-version-handling-in-init-mode

Conversation

@chillenzer
Copy link
Copy Markdown

Thanks for this great project! I've just started using it and it works quite well!

However, this tiny oversight had me scratching my head for quite a while: In init=True mode, the version parameter of ROCrate.__init__ is not passed through to __init_from_tree.

@simleo
Copy link
Copy Markdown
Collaborator

simleo commented Mar 26, 2026

Hi @chillenzer, please add a unit test to cover this case

@chillenzer
Copy link
Copy Markdown
Author

chillenzer commented Mar 27, 2026

Hi, thanks for the quick response! Sorry, if it's not best quality, just hacked it together in the browser. While looking through the tests, I've only found CLI tests. (Might have overlooked something. If so: Please point me there!) I've added a CLI test and then realized that probably the reason for this not having popped up earlier is that the CLI doesn't support this. So, I've taken the liberty to add a CLI option for this as well. You should feel warmly invited to suggest a better name (naming is hard!) or scold me for this frivolous act. I've explicitly not chosen --version as convention has it reserved for printing the software version.

@chillenzer
Copy link
Copy Markdown
Author

chillenzer commented Mar 27, 2026

Yes, I should've definitely not just hacked it in the browser. I'll do it properly next week.

@chillenzer chillenzer force-pushed the fix-version-handling-in-init-mode branch from 5ff8262 to 4c8bb49 Compare April 14, 2026 07:22
@chillenzer
Copy link
Copy Markdown
Author

Sorry for the delay. @simleo should work now.

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.

2 participants