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

feat(trace): more trace fixes #9474

Merged
merged 3 commits into from
Nov 20, 2024
Merged

Conversation

NicholasLYang
Copy link
Contributor

@NicholasLYang NicholasLYang commented Nov 20, 2024

Description

A couple small fixes for tracing:

  • Add more extensions for support
  • Add more files to look at for a main file (module is non-standard but common)
  • Try resolving @types/<package> if <package> fails to resolve

Testing Instructions

Added tests for new extensions, for module field, and for importing types from foo that really come from @types/foo

Copy link

vercel bot commented Nov 20, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
examples-nonmonorepo ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 20, 2024 8:22pm
8 Skipped Deployments
Name Status Preview Comments Updated (UTC)
examples-basic-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-designsystem-docs ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-gatsby-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-kitchensink-blog ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-native-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-svelte-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-tailwind-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm
examples-vite-web ⬜️ Ignored (Inspect) Visit Preview Nov 20, 2024 8:22pm

Copy link

New dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@types/d3-scale@4.0.8 None +1 166 kB types

View full report↗︎

@NicholasLYang NicholasLYang enabled auto-merge (squash) November 20, 2024 20:33
@@ -316,7 +328,14 @@ impl Tracer {
.with_force_extension(EnforceExtension::Disabled)
.with_extension(".ts")
.with_extension(".tsx")
.with_module(self.cwd.join_component("node_modules").to_string())
Copy link
Member

Choose a reason for hiding this comment

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

Confirming we no longer want to consider working directory's node_modules

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah turns out this is built into oxc-resolver so we don't need to do this

@@ -5,6 +5,7 @@
"maybefails": "exit 4"
},
"dependencies": {
"utils": "*"
"utils": "*",
"@types/d3-scale": "^4.0.2"
Copy link
Member

Choose a reason for hiding this comment

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

Can we make this an exact version to prevent this getting bumped and behaving unexpectedly.

Suggested change
"@types/d3-scale": "^4.0.2"
"@types/d3-scale": "4.0.2"

@NicholasLYang NicholasLYang merged commit 52779f1 into main Nov 20, 2024
40 checks passed
@NicholasLYang NicholasLYang deleted the nicholasyang/more-trace-fixes branch November 20, 2024 20:57
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.

3 participants