Support tags in CLI create-order command#193
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for optional tags in the CLI create-order command, allowing users to attach metadata to orders for tracking or categorization purposes.
- Added
tagparameter to both the CLI interface and underlying create-order function - Updated function signatures and parameter passing to support the new tag functionality
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/frequenz/client/electricity_trading/cli/main.py | Added click option for tag parameter and passed it through to the async function call |
| src/frequenz/client/electricity_trading/cli/etrading.py | Added tag parameter to create_order function signature and passed it to the order creation |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| @click.option("--currency", default="EUR", type=str) | ||
| @click.option("--duration", default=900, type=int) | ||
| @click.option("--sign_secret", default=None, type=str) | ||
| @click.option("--tag", default=None, type=str) |
There was a problem hiding this comment.
The click option for --tag is missing a help description. Consider adding a help parameter to explain what the tag is used for, similar to other options in the function.
Suggested change
| @click.option("--tag", default=None, type=str) | |
| @click.option("--tag", default=None, type=str, help="An optional tag to identify or group the order.") |
Signed-off-by: cwasicki <126617870+cwasicki@users.noreply.github.com>
Signed-off-by: cwasicki <126617870+cwasicki@users.noreply.github.com>
Signed-off-by: cwasicki <126617870+cwasicki@users.noreply.github.com>
matthias-wende-frequenz
approved these changes
Sep 22, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.