node-gitlab-2-github icon indicating copy to clipboard operation
node-gitlab-2-github copied to clipboard

Unable to import issues

Open aman00323 opened this issue 3 years ago • 6 comments

settings.ts

import Settings from './src/settings';

export default {
  gitlab: {
    url: 'https://gitlab.com',
    token: 'glpat-_asdasdasdasdqweqwe',
    projectId: 1111111,
    sessionCookie: 'token',
  },
  github: {
    baseUrl: 'https://github.com',
    // apiUrl: 'https//api.github.mycompany.com',
    owner: 'aman00323',
    token: 'asdasdasdasdadasdasd',
    token_owner: 'aman00323',
    repo: 'asdasdasd-asdas',
    recreateRepo: true,
  },
  s3: {
    accessKeyId: '{{accessKeyId}}',
    secretAccessKey: '{{secretAccessKey}}',
    bucket: 'my-gitlab-bucket',
  },
  usermap: {
  },
  projectmap: {
  },
  conversion: {
    useLowerCaseLabels: true,
  },
  transfer: {
    description: false,
    milestones: false,
    labels: false,
    issues: true,
    mergeRequests: false,
    releases: false,
  },
  debug: true,
  useIssueImportAPI: true,
  usePlaceholderMilestonesForMissingMilestones: true,
  usePlaceholderIssuesForMissingIssues: true,
  useReplacementIssuesForCreationFails: true,
  useIssuesForAllMergeRequests: false,
  filterByLabel: null,
  skipMergeRequestStates: [],
  skipMatchingComments: [],
  mergeRequests: {
    logFile: './merge-requests.json',
    log: true,
  },
} as Settings;

Error

Error during transfer:
TypeError: issues.sort is not a function
    at /home/aman/Desktop/node-gitlab-2-github/src/index.ts:397:19
    at step (/home/aman/Desktop/node-gitlab-2-github/src/index.ts:52:23)
    at Object.next (/home/aman/Desktop/node-gitlab-2-github/src/index.ts:33:53)
    at fulfilled (/home/aman/Desktop/node-gitlab-2-github/src/index.ts:24:58)
    at processTicksAndRejections (internal/process/task_queues.js:97:5)


Transfer complete!

aman00323 avatar Aug 30 '22 14:08 aman00323

Hi @aman00323 I have the same problem here. Do you have any updates about this case? Thank you!

vmucury avatar May 19 '23 21:05 vmucury

@aman00323 @vmucury

What version of TypeScript are you using?

ddavyMRS avatar May 31 '23 14:05 ddavyMRS

Hi @mrs-electronics

Im using:

[email protected] │ └── [email protected] deduped └── [email protected]

vmucury avatar May 31 '23 15:05 vmucury

What happens if you run npm i -g --save-dev ?

ddavyMRS avatar May 31 '23 15:05 ddavyMRS

I run this cmd and the output is: added 1 package in 180ms

vmucury avatar May 31 '23 22:05 vmucury

I had this problem as well! There is a whole list of packages versions gitlab-2-github requires. It is much easier to use docker to do that, as they already have a docker container for that.

Just follow the usage steps "Docker": https://github.com/piceaTech/node-gitlab-2-github?tab=readme-ov-file#docker or "Docker with bind mounts": https://github.com/piceaTech/node-gitlab-2-github?tab=readme-ov-file#docker-with-bind-mounts in the README.

VictorrLiu avatar Mar 20 '24 01:03 VictorrLiu