aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/query2/output
Commit message (Collapse)AuthorAge
* Extract AttributeInfoProvider interface for DependencyFilters.Gravatar Dmitry Lomov2016-01-22
| | | | | | | | This is in preparation of implementing dependency filtering correctly for aspects. -- MOS_MIGRATED_REVID=112721440
* Refactor dependency filtering out of Rule class.Gravatar Dmitry Lomov2016-01-22
| | | | | -- MOS_MIGRATED_REVID=112717648
* Allow more flexibility on proto output formatter.Gravatar Miguel Alcon Pinto2016-01-21
| | | | | -- MOS_MIGRATED_REVID=112681274
* Fileset (Google internal): code cleanup.Gravatar Laszlo Csomor2016-01-19
| | | | | -- MOS_MIGRATED_REVID=112466264
* Allow to filter attributes based on the rule of the attribute.Gravatar Miguel Alcon Pinto2016-01-11
| | | | | -- MOS_MIGRATED_REVID=111854804
* Permit proto serialization of configured attribute valuesGravatar Mark Schaller2016-01-04
| | | | | | | | | This commit adds proto messages that represent configurable values, and modifies attribute value serialization code to handle those values, which are called SelectorLists. -- MOS_MIGRATED_REVID=111149272
* Minor cleanup to AttributeSerializer, ProtoOutputFormatterGravatar Mark Schaller2015-12-16
| | | | | | | | Makes "explicitlySpecified" a primitive boolean instead of a boxed Boolean. Minor formatting changes to ProtoOutputFormatter. -- MOS_MIGRATED_REVID=110360334
* Add option to read query from a file.Gravatar Janak Ramakrishnan2015-12-11
| | | | | | | RELNOTES[NEW]: Evaluate the query expression in a file by passing --query_file=<file> to query -- MOS_MIGRATED_REVID=109932769
* Allow output formatters to work in stream mode.Gravatar Miguel Alcon Pinto2015-12-10
| | | | | -- MOS_MIGRATED_REVID=109908202
* Rollback of commit 8e7da8704dba78dba47fbaa0eafce3a91c2deb13.Gravatar Peter Schmitt2015-12-01
| | | | | | | *** Reason for rollback *** -- MOS_MIGRATED_REVID=109005097
* Extract Attribute serialization logicGravatar Michajlo Matijkiw2015-11-20
| | | | | -- MOS_MIGRATED_REVID=108368348
* Allow output formatters to work in stream mode.Gravatar Miguel Alcon Pinto2015-11-19
| | | | | -- MOS_MIGRATED_REVID=108142169
* Aspect terminology update.Gravatar Dmitry Lomov2015-11-10
| | | | | | | | Aspect => ConfiguredAspect AspectWithParameters => Aspect -- MOS_MIGRATED_REVID=107375211
* Parametrize aspect definition with AspectParameters.Gravatar Dmitry Lomov2015-11-02
| | | | | -- MOS_MIGRATED_REVID=106848269
* Implement propagation along dependencies for Skylark aspects.Gravatar Dmitry Lomov2015-11-02
| | | | | -- MOS_MIGRATED_REVID=106694515
* Introduce an AspectClass: a representation of a class of aspects.Gravatar Dmitry Lomov2015-10-22
| | | | | | | For native aspects, AspectClass is a facade for Class<AspectFactory<...>>. -- MOS_MIGRATED_REVID=105986390
* Make 'blaze query --output=build' 25 times faster.Gravatar Laurent Le Brun2015-10-20
| | | | | -- MOS_MIGRATED_REVID=105854596
* Add the ability to filter out attributes when doing queries.Gravatar Miguel Alcon Pinto2015-10-09
| | | | | -- MOS_MIGRATED_REVID=104979750
* Rationalize copyright headersGravatar Damien Martin-Guillerez2015-09-25
| | | | | | | | | | | The headers were modified with `find . -type f -exec 'sed' '-Ei' 's|Copyright 201([45]) Google|Copyright 201\1 The Bazel Authors|' '{}' ';'` And manual edit for not Google owned copyright. Because of the nature of ijar, I did not modified the header of file owned by Alan Donovan. The list of authors were extracted from the git log. It is missing older Google contributors that can be added on-demand. -- MOS_MIGRATED_REVID=103938715
* Make TargetFormatter available for tests.Gravatar Janak Ramakrishnan2015-09-24
| | | | | -- MOS_MIGRATED_REVID=103798663
* Make aspect resolver and dependencyFilter transient, as they are not ↵Gravatar Miguel Alcon Pinto2015-09-23
| | | | | | | serializable. -- MOS_MIGRATED_REVID=103678330
* Move Label from the lib.syntax to the lib.cmdline package so that:Gravatar Lukacs Berki2015-09-21
| | | | | | | | | | - Label parsing can be simplified - lib.syntax is only contains the code for Skylark and is reasonably independent from the problem domain of building things This change is mostly only changes to imports declarations. The rest is reversing the dependency between :cmdline and :syntax and moving a tiny amount of code between Printer and FilesetEntry and the addition of SkylarkPrintableValue that I couldn't be bothered to separate out into its own change. -- MOS_MIGRATED_REVID=103527877
* Separate build-specific types and types inherent to Skylark.Gravatar Lukacs Berki2015-09-21
| | | | | -- MOS_MIGRATED_REVID=103374106
* Parse the label syntax "@//a:b" so that eventually we can make that the ↵Gravatar Lukacs Berki2015-09-15
| | | | | | | | | syntax that means "refer to the main repository". There isn't an overarching plan for what we are going to do with the cmdline package, which seems to be separated from the .syntax one in all sorts of awkward ways. -- MOS_MIGRATED_REVID=103088960
* Don't expose includeGlobs in PackageSerializer public interfaceGravatar Michajlo Matijkiw2015-09-11
| | | | | | | | We always set this false when calling from outside PackageSerializer. Hide it away since we don't need it and so that we don't get tempted. -- MOS_MIGRATED_REVID=102864146
* Refactor Skylark Environment-sGravatar Francois-Rene Rideau2015-09-11
| | | | | | | | | | | | | | | | | | | | Make Environment-s freezable: Introduce a class Mutability as a revokable capability to mutate objects in an Environment. For now, only Environment-s carry this capability. Make sure that every Mutability is revoked in the same function that create... This reinstates a change that previously rolled-back because it broke the serializability of SkylarkLookupValue. Bad news: serializing it succeeds for the wrong reason, because a SkylarkEnvironment was stored as a result (now an Environment.Extension) that was Serializable but inherited its bindings from an Environment (now an Environment.BaseExtension) which wasn't Serializable. Apparently, Java doesn't try to serialize the bindings then (or at least doesn't error out when it fails), because these bindings map variable names to pretty arbitrary objects, and a lot of those we find in practice aren't Serializable. Thus the current code passes the same tests as the previous code, but obviously the serialization is just as ineffective as it used to be. -- MOS_MIGRATED_REVID=102776694
* Stop serializing/deserializing Locations as part of PackagesGravatar Michajlo Matijkiw2015-09-11
| | | | | | | | | | | | They're not cheap to serialize or reconstitute and we don't really need them. This does leave some odd ends around, in particular i decided to keep deserialization context around as i can picture use for it soon. Also return non-null values from all of EmptyLocation's method since while the javadocs declare that LineAndColumn and Path can be null, there does exist code which does not take this into account, this is for another change. -- MOS_MIGRATED_REVID=102758810
* Add an attribute to proto and xml query outputs to mark packages that are in ↵Gravatar Miguel Alcon Pinto2015-09-08
| | | | | | | error. -- MOS_MIGRATED_REVID=102582717
* Rollback of commit 5a94e59f02833f9142bad9203acd72626b089535.Gravatar Janak Ramakrishnan2015-09-08
| | | | | | | | | *** Reason for rollback *** Breaks serialization of SkyValues. -- MOS_MIGRATED_REVID=102457225
* Refactor Skylark Environment-sGravatar Francois-Rene Rideau2015-09-08
| | | | | | | | | | | | | | | | | Make Environment-s freezable: Introduce a class Mutability as a revokable capability to mutate objects in an Environment. For now, only Environment-s carry this capability. Make sure that every Mutability is revoked in the same function that creates it, so no Environment is left open for modification after being created and exported; exceptions for tests, the shell and initialization contexts. Unify Environment, SkylarkEnvironment and EvaluationContext into Environment. Have a notion of Frame for the bindings + parent + mutability. Replace the updateAndPropagate mechanism by a dynamicFrame. Simplify ValidationEnvironment, that is now always deduced from the Environment. -- MOS_MIGRATED_REVID=102363438
* Fix some warnings.Gravatar Ulf Adams2015-09-04
| | | | | -- MOS_MIGRATED_REVID=102332437
* Make full location serialization for packages optionalGravatar Michajlo Matijkiw2015-08-31
| | | | | | | | | | Finding start/end line/col for locations takes some cpu work. As locations are quite common this cpu work adds up. Instead make it possible to only serialize the bare minimum location (start and end offset), the rest can be derived from the original file if necessary. -- MOS_MIGRATED_REVID=101966365
* Move PackageIdentifier to cmdlineGravatar Kristina Chodorow2015-08-31
| | | | | | | | This is necessary to have TargetResolver depend on it without making it depend on the packages target. First step of #389. -- MOS_MIGRATED_REVID=101790345
* Replace query option --order_results with --order_output, which can take ↵Gravatar Janak Ramakrishnan2015-08-26
| | | | | | | | | | | three values for a given output formatter: 'no', 'deps', or 'full'. A fourth value, 'auto', means either 'deps' or 'full' depending on the formatter. The option 'no' is equivalent to --noorder_results. 'full' means that output will be deterministically ordered, using alphabetization if necessary. 'deps' means that graph order will be preserved (where applicable), but further efforts to order the output may not be undertaken. 'auto' is equivalent to 'full' for all output formatters except for proto, minrank, maxrank, and graph, for which it is equivalent to 'deps'. The purpose of this cl is to enable genquery to force completely deterministic output, which requires that it be able to specify a total ordering on the graph that is consistent across runs. Which ordering doesn't matter very much, so depending on the output formatter, or even within the same one, there may be some groups of nodes that are ordered alphabetically, and some reverse alphabetically. -- MOS_MIGRATED_REVID=101512292
* No-op refactoring of output formatters to re-use common code.Gravatar Janak Ramakrishnan2015-08-26
| | | | | | | This will make it easier for future changes to modify this common code. -- MOS_MIGRATED_REVID=101464103
* Fix output of query --output=buildGravatar Laurent Le Brun2015-08-21
| | | | | | | Implicit attributes start with '_' to make the output parsable. -- MOS_MIGRATED_REVID=101151243
* Add --proto:default_values option for blaze query, which can be used to supressGravatar Googler2015-07-08
| | | | | | | | | including attributes not explicitly specified in the output. Works for output=proto and has same semantics as --xml:default_values has for output=xml. -- MOS_MIGRATED_REVID=97710199
* Rollback of commit 13ef26d0817a429bf214d3dc4c5551e616e403fe.Gravatar Laurent Le Brun2015-06-30
| | | | | | | | | | | | | | | | | *** Reason for rollback *** Breaks 'blaze query' *** Original change description *** Skylark: write labels readably Write a label as Label("//x:x") instead of merely "//x:x", so it can be read and evaluated back, as per the Python convention. However, the OutputFormatter for BUILD files still needs to output "//x:x". -- MOS_MIGRATED_REVID=97156166
* Skylark: write labels readablyGravatar Francois-Rene Rideau2015-06-18
| | | | | | | | | Write a label as Label("//x:x") instead of merely "//x:x", so it can be read and evaluated back, as per the Python convention. However, the OutputFormatter for BUILD files still needs to output "//x:x". -- MOS_MIGRATED_REVID=96209979
* Implement Skylark function reprGravatar Francois-Rene Rideau2015-06-15
| | | | | | | | | | | | | | | | | Move printing code from EvalUtils to Printer. Rename functions in Printer: printValue becomes str or print, prettyPrintValue becomes repr or write, formatString becomes format, makeFormattable becomes strFormattable, prettyPrintValues becomes listString. write being self-sufficient is made the reference, and print is the one that is a wrapper around write, rather than the other way around, avoiding mutual recursion. -- MOS_MIGRATED_REVID=95897834
* Switch the default of --aspect_deps to "conservative".Gravatar Lukacs Berki2015-06-11
| | | | | -- MOS_MIGRATED_REVID=95714424
* Description redacted.Gravatar Lukacs Berki2015-06-10
| | | | | -- MOS_MIGRATED_REVID=95615442
* Optimization: do not trigger the loading of directly dependent packages on ↵Gravatar Lukacs Berki2015-06-09
| | | | | | | query for aspects that do not have implicit attributes. -- MOS_MIGRATED_REVID=95507900
* Add --with_aspect_deps flag to blaze query. This flag should produce ↵Gravatar Lukacs Berki2015-06-05
| | | | | | | | | | | | | additional information about aspect dependencies when --output is set to {xml, proto}. One quirk of this CL is that if BUILD files of direct dependencies are added both under <subinclude> and <load>. Any better ideas are appreciated. As a drive-by fix, if for some reason a package reports the same label as a both subinclude and a Skylark dependency, it will only be reported once in the proto output. RELNOTES[NEW]: added --with_aspect_deps to blaze query, that prints additional information about aspects of target when --output is set to {xml, proto, record}. -- MOS_MIGRATED_REVID=95272042
* Add environment_group support for query.Gravatar Greg Estren2015-04-27
| | | | | -- MOS_MIGRATED_REVID=91997659
* Merge PackageSerializer's and ProtoOutputFormatter's duplicatedGravatar Greg Estren2015-03-25
| | | | | | | | | | | | | | | | serialization logic. Among other things, this fixes an out-of-sync bug where ProtoOutputFormatter's version knew how to handle configurable attributes while PackageSerializer's version crashed. The merged logic preserves ProtoOutputFormatter's semantics: configurable attributes work, but their values are merged together into a flattened list, so the original select structure can't be reproduced later. -- MOS_MIGRATED_REVID=89435116
* Reword documentation of --universe_scope to emphasize that it isn't ↵Gravatar Nathan Harmata2015-03-23
| | | | | | | necessarily used (it's not used when SkyQuery isn't used, e.g. when --noorder_results isn't specified). -- MOS_MIGRATED_REVID=89150192
* RELNOTES[NEW]: Added --relative_locations flag to the query command to make ↵Gravatar Damien Martin-Guillerez2015-03-13
| | | | | | | | | the locations of build files relative to the workspace root with protobuf and XML outputs Protobuf and XML outputs of query are non-deterministic. This flag is a first step to make genquery deterministic accross machine. -- MOS_MIGRATED_REVID=88428100
* Some cleanup changes.Gravatar Ulf Adams2015-03-05
| | | | | -- MOS_MIGRATED_REVID=87821306
* Add a SkyQueryEnvironment which runs queries by examining the Skyframe graph.Gravatar Janak Ramakrishnan2015-02-26
| | | | | | | | | This environment eagerly preloads the transitive closure of a specified query "universe", and so may not be as efficient as the standard query for limited-scope queries. It is activated when the universe is specified and ordered results are not requested (since it is currently unable to order results). Tests were modified/added to exercise this environment where deemed interesting. Some ugly hacks were done to add coverage in AbstractQueryTest and friends, because currently even if the full depot is loaded (using //...), individual target patterns most likely won't be present in the graph. A better way to deal with this situation, suggested by felly, is probably to extract target pattern resolution logic to an auxiliary function so that query is able to resolve target patterns without mutating the graph, and then call into the read-only graph with the resolved patterns. That may be done in a follow-up, in which case the "scope" of every query could be //... . -- MOS_MIGRATED_REVID=87257028