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

Change "IssueId" to long #2890

Merged
merged 3 commits into from
Feb 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@ private static async Task<ProjectCard> CreateArchivedCardHelper(IGitHubClient gi
return result;
}

private static async Task<ProjectCard> CreateIssueCardHelper(IGitHubClient githubClient, int issueId, int columnId)
private static async Task<ProjectCard> CreateIssueCardHelper(IGitHubClient githubClient, long issueId, int columnId)
{
var newCard = new NewProjectCard(issueId, ProjectCardContentType.Issue);
var result = await githubClient.Repository.Project.Card.Create(columnId, newCard);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ private static async Task<ProjectCard> CreateArchivedCardHelper(IObservableGitHu
return result;
}

private static async Task<ProjectCard> CreateIssueCardHelper(IObservableGitHubClient githubClient, int issueId, int columnId)
private static async Task<ProjectCard> CreateIssueCardHelper(IObservableGitHubClient githubClient, long issueId, int columnId)
{
var newCard = new NewProjectCard(issueId, ProjectCardContentType.Issue);
var result = await githubClient.Repository.Project.Card.Create(columnId, newCard);
Expand Down
4 changes: 2 additions & 2 deletions Octokit/Models/Request/NewPullRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public NewPullRequest(string title, string head, string baseRef)
/// <param name="issueId">The number of an existing issue to convert into a pull request.</param>
/// <param name="head">The branch (or git ref where your changes are implemented. In other words, the source branch/ref</param>
/// <param name="baseRef">The base (or git ref) reference you want your changes pulled into. In other words, the target branch/ref</param>
public NewPullRequest(int issueId, string head, string baseRef)
public NewPullRequest(long issueId, string head, string baseRef)
{
Ensure.ArgumentNotNullOrEmptyString(head, nameof(head));
Ensure.ArgumentNotNullOrEmptyString(baseRef, nameof(baseRef));
Expand All @@ -50,7 +50,7 @@ public NewPullRequest(int issueId, string head, string baseRef)
/// <summary>
/// The number of an existing issue to convert into a pull request (required if <see cref="Title"/> not provided).
/// </summary>
public int? IssueId { get; private set; }
public long? IssueId { get; private set; }

/// <summary>
/// The branch (or git ref) you want your changes pulled into (required).
Expand Down
4 changes: 2 additions & 2 deletions Octokit/Models/Response/Issue.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ public class Issue
{
public Issue() { }

public Issue(string url, string htmlUrl, string commentsUrl, string eventsUrl, int number, ItemState state, string title, string body, User closedBy, User user, IReadOnlyList<Label> labels, User assignee, IReadOnlyList<User> assignees, Milestone milestone, int comments, PullRequest pullRequest, DateTimeOffset? closedAt, DateTimeOffset createdAt, DateTimeOffset? updatedAt, int id, string nodeId, bool locked, Repository repository, ReactionSummary reactions, LockReason? activeLockReason, ItemStateReason? stateReason)
public Issue(string url, string htmlUrl, string commentsUrl, string eventsUrl, int number, ItemState state, string title, string body, User closedBy, User user, IReadOnlyList<Label> labels, User assignee, IReadOnlyList<User> assignees, Milestone milestone, int comments, PullRequest pullRequest, DateTimeOffset? closedAt, DateTimeOffset createdAt, DateTimeOffset? updatedAt, long id, string nodeId, bool locked, Repository repository, ReactionSummary reactions, LockReason? activeLockReason, ItemStateReason? stateReason)
{
Id = id;
NodeId = nodeId;
Expand Down Expand Up @@ -45,7 +45,7 @@ public Issue(string url, string htmlUrl, string commentsUrl, string eventsUrl, i
/// <summary>
/// The internal Id for this issue (not the issue number)
/// </summary>
public int Id { get; private set; }
public long Id { get; private set; }
Copy link
Contributor

@arxange1 arxange1 Feb 22, 2024

Choose a reason for hiding this comment

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

int id in the constructor to be fixed as well.

There is also NewPullRequest class with the same issue.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good catch - fixed in b1d53cc and cc2dd92


/// <summary>
/// GraphQL Node Id
Expand Down
Loading