Skip to content

Commit 25dead5

Browse files
quark-zjufacebook-github-bot
authored andcommitted
revisionstore: fix GitHub build (#46)
Summary: Pull Request resolved: #46 See https://github.com/facebookexperimental/eden/runs/1034006668: error: unused import: `env::set_var` --> src/lfs.rs:1539:15 | 1539 | use std::{env::set_var, str::FromStr}; | ^^^^^^^^^^^^ | note: the lint level is defined here --> src/lib.rs:125:9 | 125 | #![deny(warnings)] | ^^^^^^^^ = note: `#[deny(unused_imports)]` implied by `#[deny(warnings)]` error: unnecessary braces around method argument --> src/lfs.rs:2439:36 | 2439 | remote.batch_upload(&objs, { move |sha256| local_lfs.blobs.get(&sha256) })?; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove these braces | note: the lint level is defined here --> src/lib.rs:125:9 | 125 | #![deny(warnings)] | ^^^^^^^^ = note: `#[deny(unused_braces)]` implied by `#[deny(warnings)]` error: aborting due to 2 previous errors error: could not compile `revisionstore`. I dropped `#![deny(warnings)]` as I don't think warnings like the above ones should break the build. (denying specific warnings that we care about explicitly might be a better approach) Reviewed By: singhsrb Differential Revision: D23362178 fbshipit-source-id: 8ea6ce83191190cbe2b013c5eed2f0f86628ff21
1 parent d60e807 commit 25dead5

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

eden/scm/lib/revisionstore/src/lfs.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1536,7 +1536,7 @@ impl LocalStore for LfsFallbackRemoteStore {
15361536
mod tests {
15371537
use super::*;
15381538

1539-
use std::{env::set_var, str::FromStr};
1539+
use std::str::FromStr;
15401540

15411541
use quickcheck::quickcheck;
15421542
use tempfile::TempDir;
@@ -2088,6 +2088,7 @@ mod tests {
20882088
#[cfg(feature = "fb")]
20892089
mod fb_test {
20902090
use super::*;
2091+
use std::env::set_var;
20912092

20922093
#[test]
20932094
fn test_lfs_non_present() -> Result<()> {
@@ -2436,7 +2437,7 @@ mod tests {
24362437
.iter()
24372438
.cloned()
24382439
.collect::<HashSet<_>>();
2439-
remote.batch_upload(&objs, { move |sha256| local_lfs.blobs.get(&sha256) })?;
2440+
remote.batch_upload(&objs, move |sha256| local_lfs.blobs.get(&sha256))?;
24402441

24412442
assert_eq!(remote_lfs_file_store.get(&blob1.0)?, Some(blob1.2));
24422443
assert_eq!(remote_lfs_file_store.get(&blob2.0)?, Some(blob2.2));

eden/scm/lib/revisionstore/types/lib.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,6 @@
55
* GNU General Public License version 2.
66
*/
77

8-
#![deny(warnings)]
9-
108
//! revisionstore_types - Data types used by the revisionstore crate
119
1210
mod datastore;

0 commit comments

Comments
 (0)