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

fixed dm and Makefile #105

Closed
wants to merge 0 commits into from
Closed

fixed dm and Makefile #105

wants to merge 0 commits into from

Conversation

richl9
Copy link
Contributor

@richl9 richl9 commented Sep 18, 2024

No description provided.

@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Sep 18, 2024
Copy link
Member

@brenns10 brenns10 left a comment

Choose a reason for hiding this comment

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

A few things in addition to the two comments:

  1. Can you file an (Oracle) bug for this change? And can you say whether the dm fix should be backported to v1? If so, let's file both bugs for that.
  2. I see the merge commit in there, I try to avoid merge commits wherever possible. Could you get rid of that?
  3. Would you mind splitting out the dm.py change and the Makefile commits into their own separate commits? I don't mind them being in the same pull request, but they are logically different changes and shouldn't live in the same commit.

Makefile Outdated
rsync -avz --exclude "__pycache__" --exclude ".git" --exclude ".mypy_cache" ./drgn_tools $(TARGET):drgn_tools/
rsync -avz --exclude "__pycache__" --exclude ".git" --exclude ".mypy_cache" ./drgn_tools $(TARGET)
Copy link
Member

Choose a reason for hiding this comment

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

To ensure that this doesn't break any existing users who may already have TARGET set and expect it to go to TARGET:drgn_tools/, would you please go ahead and add the following code into the Makefile? Directly beneath the -include config.mk directive would be best.

# The TARGET variable could be either a hostname or a hostname:path. Previously
# the makefile expected just a hostname, and it always placed the resulting
# directory at $TARGET:drgn_tools/. But it's nice to have flexibility to change
# the target directory, so we only add that default path if there's not already
# a path specified.
ifneq (,$(TARGET))
ifeq (,$(findstring :,$(TARGET)))
override TARGET := $(TARGET):drgn_tools/
else
endif
endif

drgn_tools/dm.py Outdated
Comment on lines 36 to 44
yield hc.md, hc.name.string_().decode(), hc.uuid.string_().decode()
uuid = ""
if hc.uuid:
uuid = hc.uuid.string_().decode()

yield hc.md, hc.name.string_().decode(), uuid
Copy link
Member

Choose a reason for hiding this comment

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

The fixes look good, but the commit message doesn't contain any context for why they are necessary. Was there a change that made the uuid field nullable, or has it always been and we just didn't handle it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants