question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Incorrect error from cquery when configuration flag has the default value

See original GitHub issue

Description of the bug:

cquery produces incorrect error transition inputs [@//:flavor] do not correspond to valid settings when the flag is not set on the command line or set to the default value.

What’s the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

Minimal repro provided here: https://github.com/Bazel-snippets/cquery_transition_error

The following command demonstrates the incorrect error: bazel cquery somepath(transistor,dummy) --transitions=lite --//:flavor=opt

Error: transition inputs [@//:flavor] do not correspond to valid settings

Omiting of the flag flavoror setting it to the default value opt causes the error. Setting it to dbg avoids the error.

Using --transitions=lite and somepath query function both required to reproduce the problem.

Which operating system are you running Bazel on?

Mac, Linux, Windows

What is the output of bazel info release?

5.2

If bazel info release returns development version or (@non-git), tell us how you built Bazel.

No response

What’s the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?

No response

Have you found anything relevant by searching the web?

No response

Any other information, logs, or outputs that you want to share?

No response

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:10 (8 by maintainers)

github_iconTop GitHub Comments

2reactions
fmeumcommented, Jul 5, 2022

@sgowroji This is also missing from the original report, but you have to enclose the bazel query query in single quotes or the shell will choke on the ( in the query.

This should work:

bazel cquery 'somepath(transistor,dummy)' --transitions=lite --//:flavor=dbg
0reactions
gregestrencommented, Jul 19, 2022

Oh sorry, I didn’t see the “not a bug” tag.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Why can't a text column have a default value in MySQL?
The main reason is the flag STRICT_TRANS_TABLES for sql_mode setting. if a value is not specified in INSERT statement for TEXT datatype column...
Read more >
IJ13152: INVENTORY REORDER FLAG CANNOT HAVE A ...
IJ13152: INVENTORY REORDER FLAG CANNOT HAVE A DEFAULT VALUE OF 0 ... description: -Use Database Configuration to update the default value of INVENTORY....
Read more >
Database Engine events and errors - SQL Server
Consult this MSSQL error code list to find explanations for error messages for SQL Server database engine events.
Read more >
Field 'xxxx' doesn't have a default value - MariaDB
We are running mariadb version 10.3.27 When trying to insert a record we get the error: Field 'xxxx' doesn't have a default value....
Read more >
Joi any.ifInvalid() - Sets a default value if the original ... - GitHub
@Marsup I'm thinking of an API for Joi that would allow a default value similar to any.default() but only if the original value...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found