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

Edkrepo: Added support for listing PatchSet in repo source #75

Closed
wants to merge 1 commit into from

Conversation

hrsh25
Copy link
Contributor

@hrsh25 hrsh25 commented Jul 14, 2022

Solves issue #74
Signed-off-by: Harsh Vora harsh.vora@intel.com

@@ -26,7 +26,7 @@
RepoHook = namedtuple('RepoHook', ['source', 'dest_path', 'dest_file', 'remote_url'])
Combination = namedtuple('Combination', ['name', 'description'])
RepoSource = namedtuple('RepoSource', ['root', 'remote_name', 'remote_url', 'branch', 'commit', 'sparse',
'enable_submodule', 'tag'])
'enable_submodule', 'tag', 'patchSet'])
Copy link
Contributor

Choose a reason for hiding this comment

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

To keep with the precedent set in this file please change patchSet to patch_set

@@ -48,6 +48,7 @@
COMB_INVALIDINPUT_ERROR = "Invalid input: {} not found in 'combinations' property"
COMB_UNKOWN_ERROR = "Could not find a Combination named '{}' in '{}'"
ATTRIBUTE_MISSING_ERROR = "Missing required attribute. Must specify either 'branch' or 'commit' for each <Source>."
INVALID_ATTRIBUTE_ERROR = "Can not specify branch or commit or tag along with patchSet"
Copy link
Contributor

Choose a reason for hiding this comment

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

The name of this error string is a little two generic can we change it to INVALID_COMBO_DEFINITION_ERROR

try:
self.patchSet = element.attrib['patchSet']
except Exception:
self.patchSet = None
Copy link
Contributor

Choose a reason for hiding this comment

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

To keep with the style precedent set elsewhere in this file please change self.patchSet to self.patch_set

# except (TypeError, ValueError):
# print('{} is an invalid Index.xml file or an invalid xml file.'.format(args.InputFile))
# if args.verbose:
# traceback.print_exc()
Copy link
Contributor

Choose a reason for hiding this comment

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

Please uncomment this code. This looks like it was done while testing.

-Added support of listing a PatchSet in the section of Combinations and
return the name of the patch set in the repo source tuple
-Added PatchSet parameter in the RepoSource tuple
-Added mutual exclusivity among branch/commit/tag and pacthSets

Signed-off-by: Harsh Vora <harsh.vora@intel.com>
@hrsh25 hrsh25 closed this Dec 6, 2022
@hrsh25 hrsh25 deleted the patchset_support branch December 6, 2022 19:08
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.

None yet

2 participants