Skip to content

Conversation

@hbugdoll
Copy link
Contributor

Fixes #894.

Introduction:

Example: The default value in config.get('cli.width', 80) is ignored, if config value cli.width is empty.

Steps to reproduce:

ti config cli.width ""
ti info -t android --sdk 13.0.1.GA

Description:

  • changed return logic of TiConfig.get(key, defaultValue)
    • previously, the default value was only returned if the key didn't exist
    • a specified default value is now respected if a config value is empty (get('cli.width', 80)80)
    • if no default value is specified, it remains as before (get('cli.width')'')
  • added unit tests for empty config settings
    • therefore, added example case from above in fixture JSON

Co-authored-by: Chris Barber <chris@cb1inc.com>
@hbugdoll
Copy link
Contributor Author

hbugdoll commented Jan 14, 2026

A Windows test failed with exit code 3221226505 in

assert.strictEqual(exitCode, 1);

Copy link
Contributor

@cb1kenobi cb1kenobi left a comment

Choose a reason for hiding this comment

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

Awesome, thanks!

@cb1kenobi cb1kenobi merged commit fa83bb5 into tidev:main Jan 14, 2026
20 of 21 checks passed
@cb1kenobi
Copy link
Contributor

A Windows test failed with exit code 3221226505 in

assert.strictEqual(exitCode, 1);

Yeah, that happens on Windows sometimes. It means there's a memory issue. I think it's coming from Vitest. Oh well.

@hbugdoll hbugdoll deleted the ticonfig-get-empty-value branch January 14, 2026 23:42
@hbugdoll
Copy link
Contributor Author

Yeah, that happens on Windows sometimes. It means there's a memory issue. I think it's coming from Vitest.

Thanks for the clarification.

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.

Android: broken formatting of issue section in ti info

2 participants