Skip to content

Fixed repository_compare examples#282

Merged
gpocentek merged 2 commits intopython-gitlab:masterfrom
aronpammer:docs_typo
Jul 10, 2017
Merged

Fixed repository_compare examples#282
gpocentek merged 2 commits intopython-gitlab:masterfrom
aronpammer:docs_typo

Conversation

@aronpammer
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown
Contributor

@gpocentek gpocentek left a comment

Choose a reason for hiding this comment

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

Nice catch, thank you!

Could you fix the 2 problems?

# get the commits
for i in commit:
print(result.commits)
for commit in result.commits:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

result is a dict, so you need result['commits'] here.


# get the diffs
for file_diff in commit.diffs:
for file_diff in result.diffs:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Same here for diffs.

@aronpammer
Copy link
Copy Markdown
Author

You are right, I fixed them.

@gpocentek
Copy link
Copy Markdown
Contributor

Looks good, thank you for the quick update!

@gpocentek gpocentek merged commit e87835f into python-gitlab:master Jul 10, 2017
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