Race condition with multiple source generators in a multi module project
See original GitHub issueI’m a bit at a loss tracking this one down (time constraints) but have created a simple project to replicate the problem:
https://github.com/nefilim/sbtrace
Running compile (on a clean tree) will almost always result in:
[error] source file 'sbtrace/child/target/scala-2.10/src_managed/main/sbt-buildinfo/BuildInfo.scala' could not be found
In larger project I sometimes see a different missing file but it’s usually this generated file (by sbt-buildinfo plugin).
running compile again will complete successfully. In this sample project, disabling the scalabuff generator (by excluding the scalabuffSettings from the child project settings) will prevent this problem from happening, similarly if multi module projects are collapsed to a single project.
Included in the Build.scala are some workarounds I tried but were unsuccessful.
Issue Analytics
- State:
- Created 9 years ago
- Comments:10 (4 by maintainers)
Top Results From Across the Web
Race condition - Wikipedia
A race condition or race hazard is the condition of an electronics, software, or other system where the system's substantive behavior is dependent...
Read more >Use multiple project in c# source generator - Stack Overflow
I'm trying to build a C# source generator where I need to reference source files (.cs) that are in another project in the...
Read more >US9396245B2 - Race condition handling in a system which ...
Techniques are disclosed for race condition handling in a system which incrementally updates clients with what occurred in a cloud-enabled platform.
Read more >Generating Random Numbers for Cryptographic Modules Using ...
... Recently, racing conditions in multi-core environments have also been explored as sources of entropy. Both CPU [16,17] and GPU [18] [19] [20] ......
Read more >The safety system in the C# Job System - Unity - Manual
When a race condition does cause a bug, it can be hard to find the source of the problem because it depends on...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
For those that find this issue thread searching for a way to get sbt-protoc & sbt-buildinfo to play nice:
@DustinChaloupka I think generating source into a completely different source like
src/main/protobuf-generated
usually fixed the issue.