GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Add showConfig tsc flag for debugging configs by weswigham · Pull Request #27353 · microsoft/TypeScript

Conversation

@weswigham

@weswigham Wesley Wigham (weswigham) commented Sep 25, 2018

Copy link
Copy Markdown
Member

Fixes #15213

I happened to be in the area today, saw the issue while looking through something else, and though it'd actually be a somewhat useful utility to have.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

huafu, jdanbrown, ulrichb, SlurpTheo, and anbraten reacted with thumbs up emoji
All reactions
  • 👍 5 reactions
@weswigham
Wesley Wigham (weswigham) requested review from a user, Ryan Cavanaugh (RyanCavanaugh) and Sheetal Nandi (sheetalkamat) September 25, 2018 23:00
@weswigham
Add showConfig tsc flag for debugging configs
4544aa6
@weswigham
Wesley Wigham (weswigham) force-pushed the show-config-compiler-flag branch from 164000b to 4544aa6 Compare September 25, 2018 23:02
Wesley Wigham (weswigham) added 5 commits September 25, 2018 16:19
@weswigham
Merge branch 'master' into show-config-compiler-flag
4b34031
@weswigham
Merge branch 'master' into show-config-compiler-flag
1d6b0eb
@weswigham
Merge showConfig implementation with init implementation, add basic u…
4287349
…nit tests
@weswigham
Fix lint
b3d2d68
@weswigham
Add missing semicolon
169dc07
@weswigham Wesley Wigham (weswigham) added this to the TypeScript 3.2 milestone Oct 5, 2018
@weswigham
Merge branch 'master' into show-config-compiler-flag
69e360d
@weswigham

Wesley Wigham (weswigham) commented Oct 22, 2018

Copy link
Copy Markdown
Member Author

Ping Sheetal Nandi (@sheetalkamat) - would be nice to get this reviewed, too;

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

sheetalkamat
Sheetal Nandi (sheetalkamat) reviewed Oct 23, 2018
View reviewed changes
Comment thread src/tsc/tsc.ts
const commandLineOptions = commandLine.options;
if (configFileName) {
const configParseResult = parseConfigFileWithSystem(configFileName, commandLineOptions, sys, reportDiagnostic)!; // TODO: GH#18217
if (commandLineOptions.showConfig) {

@sheetalkamat Sheetal Nandi (sheetalkamat) Oct 23, 2018

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Interesting. Should we intentionally be ignoring this in --b mode? Should it error when invoked without tsconfig file?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@weswigham Wesley Wigham (weswigham) Oct 23, 2018 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I think it could be fine without a config file - serves as a fine way to convert a response file or other command line args to a tsconfig.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

sheetalkamat reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

@weswigham Wesley Wigham (weswigham) Oct 23, 2018

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Afaik it is ignored in -b mode; iirc that bails out way early on in the command line parser, since it has its own subset of args.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@sheetalkamat Sheetal Nandi (sheetalkamat) Oct 23, 2018

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

I think we could have this even in --b just like how we have eg (list files, list emitted files) could be good information I think. Especially in verbose mode?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@weswigham
showConfig when theres no config file
979cb3d
@weswigham

Wesley Wigham (weswigham) commented Oct 31, 2018 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member Author

Sheetal Nandi (@sheetalkamat) I've updated this to support showing a config when there's no config file, but didn't enable it in --b; it just doesn't make much sense there. The only options --b respects are a handful that it takes on the command line only; and if the intent was to question the contents of the configs --b reads to actually perform builds, since it reads more than 1 config, it still doesn't make too much sense (since the point of the flag is to print the config instead of actually running the build the config configures). The functions for pretty printing the options, however, are here if you determine that such output would be useful in the builder's verbose logs.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

sheetalkamat
Sheetal Nandi (sheetalkamat) approved these changes Oct 31, 2018
View reviewed changes
@weswigham
Wesley Wigham (weswigham) merged commit a4a1bed into microsoft:master Oct 31, 2018
@weswigham
Wesley Wigham (weswigham) deleted the show-config-compiler-flag branch October 31, 2018 22:57
@vvakame Masahiro Wakame (vvakame) mentioned this pull request Nov 19, 2018
--showConfig is ignoring missing extends file #28598
Closed
@shabbyrobe

Blake Williams (shabbyrobe) commented Jan 14, 2019

Copy link
Copy Markdown

I tried to use this today but ran into a couple of issues. The first one's simple --showConfig doesn't appear in tsc --help as it should.

The second is that the PR doesn't appear to implement the feature as requested in #15213. I could be using it incorrectly, but my output only shows compilerOptions I've explicitly set myself in my tsconfig.json. I interpret "effective config" to mean "show me everything that's about to be used to compile, regardless of whether or not I set it", but that's not what I see.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@weswigham

Wesley Wigham (weswigham) commented Jan 14, 2019

Copy link
Copy Markdown
Member Author

Hmm, as is it contains everything less some things that are implied defaults/equivalent to their defaults. I suppose in that respect it makes more of a minimal config. But not doing that would be... Unfortunate. Because then we'd have to list every option. And there's a lot of options.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@shabbyrobe

Blake Williams (shabbyrobe) commented Jan 14, 2019 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown

And there's a lot of options.

It's true, but that's exactly what I want to see. I'm not sure how else to easily discover what those defaults actually are. I could be off base here, but it looks to me like the documentation for tsconfig.json shows the implied default, but not the resolved one. I might want to extend something that has implied default values when unset, like typeRoots, but retain the existing values. Or I might want to diff my effective config to the effective config of a previous version to track down which new compiler options have influenced my program (I've had to do this the hard way before; it involved a lot of rather nasty console.log() calls in the TypeScript source). A diff can show me that in five seconds flat.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@weswigham

Wesley Wigham (weswigham) commented Jan 14, 2019

Copy link
Copy Markdown
Member Author

tsc --init prints with a ton of commented out defaults and help text.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Peter Souter (petems) added a commit to petems/github-pr-review-mcp-server that referenced this pull request Sep 22, 2025
@petems @claude
fix(tests): resolve integration test timeouts with stable GitHub PR
4ad3f9a
Replace unreliable octocat/Hello-World#1 test case with stable microsoft/TypeScript#27353 PR that has verified review comments. Add fallback repositories for PR resolution testing and implement proper timeout safety limits.

- Use microsoft/TypeScript#27353 for PR fetch testing (stable, closed PR with comments)
- Add multiple fallback repositories for PR resolution testing
- Set max_pages=2 and max_comments=10 to prevent timeouts
- Improve error handling to gracefully skip instead of failing
- All 83 tests now pass without timeout issues

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Peter Souter (petems) added a commit to petems/github-pr-review-mcp-server that referenced this pull request Oct 5, 2025
@petems @claude
fix(tests): resolve integration test timeouts with stable GitHub PR
31a90a9
Replace unreliable octocat/Hello-World#1 test case with stable microsoft/TypeScript#27353 PR that has verified review comments. Add fallback repositories for PR resolution testing and implement proper timeout safety limits.

- Use microsoft/TypeScript#27353 for PR fetch testing (stable, closed PR with comments)
- Add multiple fallback repositories for PR resolution testing
- Set max_pages=2 and max_comments=10 to prevent timeouts
- Improve error handling to gracefully skip instead of failing
- All 83 tests now pass without timeout issues

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
Peter Souter (petems) added a commit to petems/github-pr-review-mcp-server that referenced this pull request Oct 5, 2025
@petems @claude @coderabbitai
feat(server): improve pagination logic and integer validation (#16)
e3d3a90
- Replace unreliable test case with stable microsoft/TypeScript#27353
- Add fallback repositories and timeout safety (max_pages=2, max_comments=10)
- Tighten integer validation to reject floats and prevent silent truncation
- Improve exception handling specificity (ValueError, TypeError vs Exception)
- Add comprehensive test coverage, achieving 100% (403/403 statements)
- Add docstrings and refactor _validate_int for clarity
- All 83 tests pass without timeout issues.

Co-Authored-By: Claude <[email protected]>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@petems Peter Souter (petems) mentioned this pull request Oct 16, 2025
test: enable integration tests to load GITHUB_TOKEN from .env petems/github-pr-review-mcp-server#40
Merged
@microsoft Microsoft (microsoft) locked as resolved and limited conversation to collaborators Oct 21, 2025
@typescript-bot TypeScript Bot (typescript-bot) assigned Wesley Wigham (weswigham) Oct 21, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

@sheetalkamat Sheetal Nandi (sheetalkamat) sheetalkamat approved these changes
@RyanCavanaugh Ryan Cavanaugh (RyanCavanaugh) Awaiting requested review from RyanCavanaugh

Uh oh!

There was an error while loading. Please reload this page.

Assignees

@weswigham Wesley Wigham (weswigham)

Labels

None yet

Projects

None yet

Milestone

TypeScript 3.2

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@weswigham @shabbyrobe @sheetalkamat
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.