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

Migration chokes on .d.ts files #55

Open
MonstraG opened this issue Jun 19, 2024 · 0 comments
Open

Migration chokes on .d.ts files #55

MonstraG opened this issue Jun 19, 2024 · 0 comments

Comments

@MonstraG
Copy link

MonstraG commented Jun 19, 2024

Environment

just npx @sentry/migr8@latest,
sentry right now:
"@sentry/nextjs": "7.117.0",

Steps to Reproduce

  1. have a project with .d.ts file:
declare namespace NodeJS {
	interface ProcessEnv {
		readonly FOO: string;
	}
}

Expected Result

I can migrate to v8

Actual Result

migration dies with

/index.d.ts Transformation error (A 'const' initializer in an ambient context must be a string or numeric literal or literal enum reference

I tried running it like so:
npx @sentry/migr8@latest --ingoreFilePatterns ["**/*.d.ts"]
npx @sentry/migr8@latest --ingoreFilePatterns "**/*.d.ts"
npx @sentry/migr8@latest --ingoreFilePatterns **/*.d.ts
but these broke in the same way

Also, every time I run it, I have to look at the intro messages for half a minute, can they be skipped?

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

No branches or pull requests

1 participant