Skip to content

Commit 93c45f3

Browse files
authored
Merge pull request #675 from TimelyDataflow/master-next
Integrate master-next into master
2 parents 2ccc792 + 63f3684 commit 93c45f3

140 files changed

Lines changed: 1678 additions & 1480 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/deploy.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,15 @@ on:
55
branches:
66
- master
77

8+
concurrency:
9+
group: deploy
10+
811
jobs:
912
deploy:
10-
runs-on: ubuntu-24.04
13+
runs-on: ubuntu-latest
1114
steps:
1215
- uses: actions/checkout@v6
13-
- run: cargo install mdbook --version 0.4.44
16+
- run: cargo install mdbook --version 0.5.2
1417
- name: Patch sample Cargo.toml versions
1518
run: |
1619
export DIFFERENTIAL_VERSION=$(cargo metadata --format-version 1 | jq -r '.packages[] | select(.name == "differential-dataflow") | .version')

.github/workflows/release-plz.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,9 @@ on:
99
branches:
1010
- master
1111

12+
concurrency:
13+
group: release-plz
14+
1215
jobs:
1316
release-plz:
1417
name: Release-plz

.github/workflows/test-timely-master.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636

3737
notify:
3838
name: Notify failed build
39-
if: failure() && github.event.pull_request == null
39+
if: failure() && github.repository == 'TimelyDataflow/differential-dataflow'
4040
needs: [tests]
4141
permissions:
4242
contents: read

.github/workflows/test.yml

Lines changed: 28 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,28 @@ on:
66
pull_request:
77

88
jobs:
9+
msrv:
10+
name: Determine MSRV
11+
runs-on: ubuntu-latest
12+
outputs:
13+
msrv: ${{ steps.msrv.outputs.msrv }}
14+
steps:
15+
- uses: actions/checkout@v6
16+
- id: msrv
17+
run: echo "msrv=$(grep '^rust-version' Cargo.toml | sed 's/.*"\(.*\)"/\1/')" >> "$GITHUB_OUTPUT"
18+
919
test:
20+
needs: msrv
1021
strategy:
1122
matrix:
1223
os:
1324
- ubuntu
1425
- macos
15-
# - windows
26+
# Linking fails on Windows.
27+
# - windows
1628
toolchain:
1729
- stable
18-
- 1.79
30+
- ${{ needs.msrv.outputs.msrv }}
1931
name: cargo test on ${{ matrix.os }}, rust ${{ matrix.toolchain }}
2032
runs-on: ${{ matrix.os }}-latest
2133
steps:
@@ -27,3 +39,17 @@ jobs:
2739
run: cargo test --workspace --all-targets
2840
- name: Cargo doc test
2941
run: cargo test --doc
42+
43+
# Check for clippy warnings
44+
clippy:
45+
name: Cargo clippy
46+
runs-on: ubuntu-latest
47+
steps:
48+
- uses: actions/checkout@v6
49+
- uses: actions-rust-lang/setup-rust-toolchain@v1
50+
with:
51+
components: clippy
52+
- name: Cargo clippy
53+
run: cargo clippy --workspace --all-targets
54+
env:
55+
RUSTFLAGS: "" # Don't make test fail on clippy

Cargo.toml

Lines changed: 67 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,85 @@ members = [
1111
"server/dataflows/random_graph",
1212
"server/dataflows/reachability",
1313
#"tpchlike",
14-
"doop",
14+
#"doop",
1515
"mdbook",
1616
]
1717
resolver = "2"
1818

1919
[workspace.package]
2020
edition = "2021"
21+
rust-version = "1.86"
2122

2223
[workspace.dependencies]
2324
differential-dataflow = { path = "differential-dataflow", default-features = false, version = "0.19.1" }
24-
timely = { version = "0.26", default-features = false }
25+
timely = { version = "0.27", default-features = false }
2526
columnar = { version = "0.11", default-features = false }
27+
#timely = { git = "https://github.com/TimelyDataflow/timely-dataflow" }
2628
#timely = { path = "../timely-dataflow/timely/", default-features = false }
2729

30+
[workspace.lints.clippy]
31+
type_complexity = "allow"
32+
option_map_unit_fn = "allow"
33+
wrong_self_convention = "allow"
34+
should_implement_trait = "allow"
35+
module_inception = "allow"
36+
37+
#as_conversions = "warn"
38+
bool_comparison = "warn"
39+
borrow_interior_mutable_const = "warn"
40+
borrowed_box = "warn"
41+
builtin_type_shadow = "warn"
42+
clone_on_ref_ptr = "warn"
43+
crosspointer_transmute = "warn"
44+
dbg_macro = "warn"
45+
deref_addrof = "warn"
46+
disallowed_macros = "warn"
47+
disallowed_methods = "warn"
48+
disallowed_types = "warn"
49+
double_must_use = "warn"
50+
double_parens = "warn"
51+
duplicate_underscore_argument = "warn"
52+
excessive_precision = "warn"
53+
extra_unused_lifetimes = "warn"
54+
from_over_into = "warn"
55+
match_overlapping_arm = "warn"
56+
must_use_unit = "warn"
57+
mut_mutex_lock = "warn"
58+
needless_borrow = "warn"
59+
needless_pass_by_ref_mut = "warn"
60+
needless_question_mark = "warn"
61+
needless_return = "warn"
62+
no_effect = "warn"
63+
panicking_overflow_checks = "warn"
64+
partialeq_ne_impl = "warn"
65+
print_literal = "warn"
66+
redundant_closure = "warn"
67+
redundant_closure_call = "warn"
68+
redundant_field_names = "warn"
69+
redundant_pattern = "warn"
70+
redundant_slicing = "warn"
71+
redundant_static_lifetimes = "warn"
72+
same_item_push = "warn"
73+
shadow_unrelated = "warn"
74+
single_component_path_imports = "warn"
75+
suspicious_assignment_formatting = "warn"
76+
suspicious_else_formatting = "warn"
77+
suspicious_unary_op_formatting = "warn"
78+
todo = "warn"
79+
transmutes_expressible_as_ptr_casts = "warn"
80+
unnecessary_cast = "warn"
81+
unnecessary_lazy_evaluations = "warn"
82+
unnecessary_mut_passed = "warn"
83+
unnecessary_unwrap = "warn"
84+
unused_async = "warn"
85+
useless_asref = "warn"
86+
useless_conversion = "warn"
87+
useless_format = "warn"
88+
wildcard_in_or_patterns = "warn"
89+
write_literal = "warn"
90+
zero_divided_by_zero = "warn"
91+
zero_prefixed_literal = "warn"
92+
2893
[profile.release]
2994
opt-level = 3
3095
debug = true

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ Alternately, here is a fragment that computes the set of nodes reachable from a
2121

2222
```rust
2323
let reachable =
24-
roots.iterate(|reach|
25-
edges.enter(&reach.scope())
24+
roots.iterate(|scope, reach|
25+
edges.enter(&scope)
2626
.semijoin(reach)
2727
.map(|(src, dst)| dst)
2828
.concat(reach)
@@ -328,7 +328,7 @@ Here is a direct implementation, in which we repeatedly take determine the set o
328328
let k = 5;
329329

330330
// iteratively thin edges.
331-
edges.iterate(|inner| {
331+
edges.iterate(|scope, inner| {
332332

333333
// determine the active vertices /-- this is a lie --\
334334
let active = inner.flat_map(|(src,dst)| [src,dst].into_iter())
@@ -337,7 +337,7 @@ edges.iterate(|inner| {
337337
.map(|(node,_)| node);
338338

339339
// keep edges between active vertices
340-
edges.enter(&inner.scope())
340+
edges.enter(&scope)
341341
.semijoin(active)
342342
.map(|(src,dst)| (dst,src))
343343
.semijoin(active)

advent_of_code_2017/Cargo.toml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@ name = "advent_of_code_2017"
33
version = "0.1.0"
44
authors = ["Frank McSherry <fmcsherry@me.com>"]
55
publish = false
6+
edition.workspace = true
7+
rust-version.workspace = true
8+
9+
[lints]
10+
workspace = true
611

712
[dependencies]
813
differential-dataflow = { workspace = true }

advent_of_code_2017/src/bin/day_01.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ fn main() {
1616
let index = worker.index();
1717
let peers = worker.peers();
1818

19-
let worker_input =
19+
let worker_input =
2020
input
2121
.iter()
2222
.map(|digit| digit - b'0')
@@ -28,17 +28,17 @@ fn main() {
2828

2929
let digits = scope.new_collection_from(worker_input).1;
3030

31-
// The two parts ask to line up elements with the next one in the sequence (part 1) and
32-
// the one half way around the sequence (part 2). To find matches, we will shift the
33-
// associated position field while keeping the part identifier as a field (`1` or `2`
31+
// The two parts ask to line up elements with the next one in the sequence (part 1) and
32+
// the one half way around the sequence (part 2). To find matches, we will shift the
33+
// associated position field while keeping the part identifier as a field (`1` or `2`
3434
// respectively). We then restrict both by the original `digits` to find matches.
3535

3636
let part1 = digits.map(move |(digit, position)| ((digit, (position + 1) % length), 1));
3737
let part2 = digits.map(move |(digit, position)| ((digit, (position + length/2) % length), 2));
3838

3939
part1
40-
.concat(&part2) // merge collections.
41-
.semijoin(&digits) // restrict to matches.
40+
.concat(part2) // merge collections.
41+
.semijoin(digits) // restrict to matches.
4242
.explode(|((digit, _pos), part)| Some((part, digit as isize))) // `part` with weight `digit`.
4343
.consolidate() // consolidate weights by `part`.
4444
.inspect(|elt| println!("part {} accumulation: {:?}", elt.0, elt.2)); // check out answers.

advent_of_code_2017/src/bin/day_03.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@ fn main() {
1616
//
1717
// The next odd square is arrived at by following four edges, each of which has length
1818
// equal to the even number between the odd numbers. To determine the position of any
19-
// given number, we can subtract the largest odd square from it and then subtract the
19+
// given number, we can subtract the largest odd square from it and then subtract the
2020
// multiples of the even length, at which point we have a distance along an edge, from
2121
// which we can determine coordinates.
22-
//
22+
//
2323
// Similarly, we can determine the sequence number from the coordinates, by determining
2424
// which layer the point is in, adding the appropriate squared odd number, and then some
2525
// cases to figure out where the point is in the sequence along that layer.
@@ -40,7 +40,7 @@ fn main() {
4040

4141
values
4242
.map(|_val| ((0, 0), (1, 1)))
43-
.iterate(|inner| {
43+
.iterate(|_scope, inner| {
4444

4545
inner
4646
.filter(move |&(_, (_, val))| val < input) // stop working when we've gotten enough
@@ -90,7 +90,7 @@ fn sequence(input: (isize, isize)) -> isize {
9090
if -input.1 > layer { layer = -input.1; }
9191

9292
// input exists in layer from ((2 * layer - 1)^2, (2 * layer + 1)^2].
93-
// note: excludes first number, includes last number.
93+
// note: excludes first number, includes last number.
9494

9595
let base = (2 * layer - 1) * (2 * layer - 1);
9696

advent_of_code_2017/src/bin/day_05.rs

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use differential_dataflow::operators::iterate::Variable;
1111

1212
fn main() {
1313

14-
let input =
14+
let input =
1515
"2
1616
0
1717
0
@@ -1051,7 +1051,7 @@ fn main() {
10511051
let index = worker.index();
10521052
let peers = worker.peers();
10531053

1054-
let worker_input =
1054+
let worker_input =
10551055
input
10561056
.split('\n')
10571057
.map(|phrase| phrase.parse::<isize>().unwrap())
@@ -1070,27 +1070,27 @@ fn main() {
10701070
let address = Variable::from(address.enter(nested));
10711071

10721072
// (addr, jump, steps)
1073-
let instruction = program.join(&address);
1073+
let instruction = program.join(address);
10741074

10751075
fn part1(jump: isize) -> isize { jump+1 }
10761076
// fn part2(jump: isize) -> isize { if jump >= 3 { jump-1 } else { jump+1 } }
10771077

1078-
let new_program =
1078+
let new_program =
10791079
instruction
10801080
.map(move |(addr, jump, _)| (addr, part1(jump)))
1081-
.concat(&instruction.map(|(addr, jump, _)| (addr, jump)).negate())
1082-
.concat(&program)
1081+
.concat(instruction.map(|(addr, jump, _)| (addr, jump)).negate())
1082+
.concat(program)
10831083
.consolidate();
10841084

1085-
let new_address =
1085+
let new_address =
10861086
instruction
10871087
.map(|(addr, jump, steps)| (addr + jump, steps + 1))
1088-
.concat(&instruction.map(|(addr, _, steps)| (addr, steps)).negate())
1089-
.concat(&address)
1088+
.concat(instruction.map(|(addr, _, steps)| (addr, steps)).negate())
1089+
.concat(address)
10901090
.consolidate();
10911091

1092-
program.set(&new_program);
1093-
address.set(&new_address)
1092+
program.set(new_program);
1093+
address.set(new_address)
10941094
.leave()
10951095
})
10961096
.consolidate()

0 commit comments

Comments
 (0)