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

Not the greatest error message on bad dotted-key insertion #252

Closed
epage opened this issue Nov 16, 2021 · 0 comments
Closed

Not the greatest error message on bad dotted-key insertion #252

epage opened this issue Nov 16, 2021 · 0 comments
Labels
C-enhancement Category: Raise on the bar on expectations

Comments

@epage
Copy link
Member

epage commented Nov 16, 2021

This is a regression compared to toml-rs found by cargo's tests

For the following document

[http]
ssl-version = 'tlsv1.1'
ssl-version.min = 'tlsv1.2'
ssl-version.max = 'tlsv1.3'
---- config::config_get_ssl_version_both_forms_configured stdout ----                                                                              
thread 'config::config_get_ssl_version_both_forms_configured' panicked at '                                                                        
                                                                                                                                                   
error: output did not match:                                                                                                                       
1   1     could not load Cargo configuration                                                                                                       
2   2                                                                                                                                              
3   3     Caused by:                                                                                                                               
4   4       could not parse TOML configuration in `[..]/.cargo/config`                                                                             
5   5                                                                                                                                              
6   6     Caused by:                                                                                                                               
7   7       could not parse input as TOML                                                                                                          
8   8                                                                                                                                              
9   9     Caused by:                                                                                                                               
10       -  dotted key attempted to extend non-table type at line 2 column 15                                                                      
    10   +  TOML parse error at line 3, column 1                                                                                                   
    11   +  |                                                                                                                                      
    12   +3 | ssl-version.min = 'tlsv1.2'                                                                                                          
    13   +  | ^                                                                                                                                    
    14   +Duplicate key `ssl-version` in `[]` table                                                                                                
    15   +                                                                                                                                         
@epage epage added C-enhancement Category: Raise on the bar on expectations cargo labels Nov 16, 2021
epage added a commit to epage/toml_edit that referenced this issue Dec 29, 2021
@epage epage closed this as completed in fe79d63 Dec 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-enhancement Category: Raise on the bar on expectations
Projects
None yet
Development

No branches or pull requests

1 participant