Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Indicate minimum version 2.1 for memchr dependency #562

Merged
merged 4 commits into from
Feb 24, 2023

Conversation

dburgener
Copy link
Contributor

The 2.0 family of memchr doesn't build in this crate. This is hard to see using cargo minimal-versions because tokio depends on memchr 2.2, which raises the dependency using minimal-versions even when tokio is disabled. This is a known issue with cargo-minimal-versions:

taiki-e/cargo-minimal-versions#6

So everything looks fine from the perspective of this crate, but consumers who use quick_xml without the optional features that enable the tokio dependency have a minimal version down to 2.0, which breaks.

To reproduce in this crate, I commented out the tokio and async_tokio lines in Cargo.toml and ran cargo minimal-versions, which produces the errors, and emulates the conditions an external user might experience.

The 2.0 family of memchr doesn't build in this crate.  This is hard to
see using cargo minimal-versions because tokio depends on memchr 2.2,
which raises the dependency using minimal-versions even when tokio is
disabled.  This is a known issue with cargo-minimal-versions:

taiki-e/cargo-minimal-versions#6

So everything looks fine from the perspective of this crate, but
consumers who use quick_xml without the optional features that enable
the tokio dependency have a minimal version down to 2.0, which breaks.

To reproduce in this crate, I commented out the tokio and async_tokio
lines in Cargo.toml and ran cargo minimal-versions, which produces the
errors, and emulates the conditions an external user might experience.
Cargo.toml Outdated Show resolved Hide resolved
@codecov-commenter
Copy link

codecov-commenter commented Feb 24, 2023

Codecov Report

Merging #562 (d7e6600) into master (f0b3420) will increase coverage by 0.00%.
The diff coverage is n/a.

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

@@           Coverage Diff           @@
##           master     #562   +/-   ##
=======================================
  Coverage   63.25%   63.26%           
=======================================
  Files          33       33           
  Lines       16479    16479           
=======================================
+ Hits        10424    10425    +1     
+ Misses       6055     6054    -1     
Flag Coverage Δ
unittests 63.26% <ø> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/de/map.rs 83.59% <0.00%> (-0.53%) ⬇️
src/lib.rs 13.37% <0.00%> (+0.06%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Collaborator

@Mingun Mingun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you provide instructions and the output of failing message? Because for me cargo minimal-versions check is working with memchr = "2.0" even when I comment tokio, tokio-derive dependencies and asinc-tokio feature.

Cargo.toml Outdated Show resolved Hide resolved
@dburgener
Copy link
Contributor Author

Interesting that you're not reproducing. I suppose it's possible it's something weird about my environment. Here's my exact steps, with output:

$ git diff
diff --git a/Cargo.toml b/Cargo.toml
index 872da6b..285a980 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -17,7 +17,7 @@ include = ["src/*", "LICENSE-MIT.md", "README.md"]
 document-features = { version = "0.2", optional = true }
 encoding_rs = { version = "0.8", optional = true }
 serde = { version = "1.0.100", optional = true }
-tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
+#tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
 memchr = "2.0"

 [dev-dependencies]
@@ -49,7 +49,7 @@ default = []
 ## [reading events] from types implementing [`tokio::io::AsyncBufRead`].
 ##
 ## [reading events]: crate::reader::Reader::read_event_into_async
-async-tokio = ["tokio"]
+#async-tokio = ["tokio"]

 ## Enables support of non-UTF-8 encoded documents. Encoding will be inferred from
 ## the XML declaration if it will be found, otherwise UTF-8 is assumed.
$ cargo minimal-versions check
info: running `rustup run nightly cargo update -Z minimal-versions`
    Updating crates.io index
    Removing aho-corasick v0.7.20
    Removing anes v0.1.6
    Removing async-stream v0.3.4
    Removing async-stream-impl v0.3.4
    Removing atty v0.2.14
    Removing autocfg v1.1.0
    Removing bitflags v1.3.2
    Removing bumpalo v3.12.0
    Removing bytes v1.4.0
    Removing cast v0.3.0
    Updating cfg-if v1.0.0 -> v0.1.0
    Removing ciborium v0.2.0
    Removing ciborium-io v0.2.0
    Removing ciborium-ll v0.2.0
    Removing clap v3.2.23
    Removing clap_lex v0.2.4
    Removing criterion v0.4.0
    Removing criterion-plot v0.5.0
    Removing crossbeam-channel v0.5.6
    Removing crossbeam-deque v0.8.2
    Removing crossbeam-epoch v0.9.13
    Removing crossbeam-utils v0.8.14
    Removing ctor v0.1.26
    Removing diff v0.1.13
    Updating document-features v0.2.7 -> v0.2.0
    Removing either v1.8.1
    Updating encoding_rs v0.8.32 -> v0.8.0
    Removing futures-core v0.3.26
    Removing half v1.8.2
    Removing hashbrown v0.12.3
    Removing hermit-abi v0.1.19
    Removing hermit-abi v0.2.6
    Removing indexmap v1.9.2
    Removing itertools v0.10.5
    Removing itoa v1.0.5
    Removing js-sys v0.3.61
    Removing lazy_static v1.4.0
    Updating libc v0.2.139 -> v0.2.18
    Removing litrs v0.2.3
    Removing log v0.4.17
    Updating memchr v2.5.0 -> v2.0.0
    Removing memoffset v0.7.1
    Removing num-traits v0.2.15
    Removing num_cpus v1.15.0
    Removing once_cell v1.17.1
    Removing oorandom v11.1.3
    Removing ordered-float v2.10.0
    Removing os_str_bytes v6.4.1
    Removing output_vt100 v0.1.3
    Removing pin-project-lite v0.2.9
    Removing plotters v0.3.4
    Removing plotters-backend v0.3.4
    Removing plotters-svg v0.3.3
    Removing pretty_assertions v1.3.0
    Removing proc-macro2 v1.0.51
    Updating quote v1.0.23 -> v0.3.8
    Removing rayon v1.6.1
    Removing rayon-core v1.10.2
    Removing regex v1.7.1
    Removing regex-syntax v0.6.28
    Removing ryu v1.0.12
    Removing same-file v1.0.6
    Removing scopeguard v1.1.0
    Updating serde v1.0.152 -> v1.0.100
    Removing serde-value v0.7.0
    Updating serde_derive v1.0.152 -> v1.0.0
      Adding serde_derive_internals v0.15.0
    Removing serde_json v1.0.93
    Updating syn v1.0.108 -> v0.11.10
      Adding synom v0.11.0
    Removing textwrap v0.16.0
    Removing tinytemplate v1.2.1
    Removing tokio v1.25.0
    Removing tokio-macros v1.8.2
    Removing tokio-stream v0.1.12
    Removing tokio-test v0.4.2
    Removing unicode-ident v1.0.6
      Adding unicode-xid v0.0.4
    Removing walkdir v2.3.2
    Removing wasm-bindgen v0.2.84
    Removing wasm-bindgen-backend v0.2.84
    Removing wasm-bindgen-macro v0.2.84
    Removing wasm-bindgen-macro-support v0.2.84
    Removing wasm-bindgen-shared v0.2.84
    Removing web-sys v0.3.61
    Removing winapi v0.3.9
    Removing winapi-i686-pc-windows-gnu v0.4.0
    Removing winapi-util v0.1.5
    Removing winapi-x86_64-pc-windows-gnu v0.4.0
    Removing windows-sys v0.42.0
    Removing windows_aarch64_gnullvm v0.42.1
    Removing windows_aarch64_msvc v0.42.1
    Removing windows_i686_gnu v0.42.1
    Removing windows_i686_msvc v0.42.1
    Removing windows_x86_64_gnu v0.42.1
    Removing windows_x86_64_gnullvm v0.42.1
    Removing windows_x86_64_msvc v0.42.1
    Removing yansi v0.5.1
info: running `cargo hack check`
info: running `cargo check` on quick-xml (1/1)
    Checking quick-xml v0.27.1 (/home/dburgener/quick-xml)
error[E0432]: unresolved import `memchr::memchr2_iter`
 --> src/escapei.rs:3:5
  |
3 | use memchr::memchr2_iter;
  |     ^^^^^^^^^^^^^^^^^^^^ no `memchr2_iter` in the root

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
  --> src/reader/parser.rs:96:46
   |
96 |                     if let Some(p) = memchr::memchr_iter(b'-', &buf[3..len - 2])
   |                                              ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
   --> src/reader/mod.rs:773:26
    |
773 |         for i in memchr::memchr_iter(b'>', chunk) {
    |                          ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr2_iter` in crate `memchr`
   --> src/reader/mod.rs:815:43
    |
815 |                     let balance = memchr::memchr2_iter(b'<', b'>', content)
    |                                           ^^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr3_iter` in crate `memchr`
   --> src/reader/mod.rs:853:26
    |
853 |         for i in memchr::memchr3_iter(b'>', b'\'', b'"', chunk) {
    |                          ^^^^^^^^^^^^ not found in `memchr`

Some errors have detailed explanations: E0425, E0432.
For more information about an error, try `rustc --explain E0425`.
error: could not compile `quick-xml` due to 5 previous errors
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/cargo check --manifest-path Cargo.toml` (exit status: 101)
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/cargo hack check` (exit status: 1)

Co-authored-by: Mingun <Alexander_Sergey@mail.ru>
@dburgener
Copy link
Contributor Author

I also tried with the dev dependencies commented out as it seems that you did, but I still get the same memchr compile errors:

$ git diff
diff --git a/Cargo.toml b/Cargo.toml
index 872da6b..7611b27 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -17,7 +17,7 @@ include = ["src/*", "LICENSE-MIT.md", "README.md"]
 document-features = { version = "0.2", optional = true }
 encoding_rs = { version = "0.8", optional = true }
 serde = { version = "1.0.100", optional = true }
-tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
+#tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
 memchr = "2.0"

 [dev-dependencies]
@@ -26,8 +26,8 @@ pretty_assertions = "1.3"
 regex = "1"
 serde = { version = "1.0", features = ["derive"] }
 serde-value = "0.7"
-tokio = { version = "1.21", default-features = false, features = ["macros", "rt"] }
-tokio-test = "0.4"
+#tokio = { version = "1.21", default-features = false, features = ["macros", "rt"] }
+#tokio-test = "0.4"

 [lib]
 bench = false
@@ -49,7 +49,7 @@ default = []
 ## [reading events] from types implementing [`tokio::io::AsyncBufRead`].
 ##
 ## [reading events]: crate::reader::Reader::read_event_into_async
-async-tokio = ["tokio"]
+#async-tokio = ["tokio"]

 ## Enables support of non-UTF-8 encoded documents. Encoding will be inferred from
 ## the XML declaration if it will be found, otherwise UTF-8 is assumed.
$ cargo minimal-versions check
info: running `rustup run nightly cargo update -Z minimal-versions`
    Updating crates.io index
    Removing aho-corasick v0.7.20
    Removing anes v0.1.6
    Removing async-stream v0.3.4
    Removing async-stream-impl v0.3.4
    Removing atty v0.2.14
    Removing autocfg v1.1.0
    Removing bitflags v1.3.2
    Removing bumpalo v3.12.0
    Removing bytes v1.4.0
    Removing cast v0.3.0
    Updating cfg-if v1.0.0 -> v0.1.0
    Removing ciborium v0.2.0
    Removing ciborium-io v0.2.0
    Removing ciborium-ll v0.2.0
    Removing clap v3.2.23
    Removing clap_lex v0.2.4
    Removing criterion v0.4.0
    Removing criterion-plot v0.5.0
    Removing crossbeam-channel v0.5.6
    Removing crossbeam-deque v0.8.2
    Removing crossbeam-epoch v0.9.13
    Removing crossbeam-utils v0.8.14
    Removing ctor v0.1.26
    Removing diff v0.1.13
    Updating document-features v0.2.7 -> v0.2.0
    Removing either v1.8.1
    Updating encoding_rs v0.8.32 -> v0.8.0
    Removing futures-core v0.3.26
    Removing half v1.8.2
    Removing hashbrown v0.12.3
    Removing hermit-abi v0.1.19
    Removing hermit-abi v0.2.6
    Removing indexmap v1.9.2
    Removing itertools v0.10.5
    Removing itoa v1.0.5
    Removing js-sys v0.3.61
    Removing lazy_static v1.4.0
    Updating libc v0.2.139 -> v0.2.18
    Removing litrs v0.2.3
    Removing log v0.4.17
    Updating memchr v2.5.0 -> v2.0.0
    Removing memoffset v0.7.1
    Removing num-traits v0.2.15
    Removing num_cpus v1.15.0
    Removing once_cell v1.17.1
    Removing oorandom v11.1.3
    Removing ordered-float v2.10.0
    Removing os_str_bytes v6.4.1
    Removing output_vt100 v0.1.3
    Removing pin-project-lite v0.2.9
    Removing plotters v0.3.4
    Removing plotters-backend v0.3.4
    Removing plotters-svg v0.3.3
    Removing pretty_assertions v1.3.0
    Removing proc-macro2 v1.0.51
    Updating quote v1.0.23 -> v0.3.8
    Removing rayon v1.6.1
    Removing rayon-core v1.10.2
    Removing regex v1.7.1
    Removing regex-syntax v0.6.28
    Removing ryu v1.0.12
    Removing same-file v1.0.6
    Removing scopeguard v1.1.0
    Updating serde v1.0.152 -> v1.0.100
    Removing serde-value v0.7.0
    Updating serde_derive v1.0.152 -> v1.0.0
      Adding serde_derive_internals v0.15.0
    Removing serde_json v1.0.93
    Updating syn v1.0.108 -> v0.11.10
      Adding synom v0.11.0
    Removing textwrap v0.16.0
    Removing tinytemplate v1.2.1
    Removing tokio v1.25.0
    Removing tokio-macros v1.8.2
    Removing tokio-stream v0.1.12
    Removing tokio-test v0.4.2
    Removing unicode-ident v1.0.6
      Adding unicode-xid v0.0.4
    Removing walkdir v2.3.2
    Removing wasm-bindgen v0.2.84
    Removing wasm-bindgen-backend v0.2.84
    Removing wasm-bindgen-macro v0.2.84
    Removing wasm-bindgen-macro-support v0.2.84
    Removing wasm-bindgen-shared v0.2.84
    Removing web-sys v0.3.61
    Removing winapi v0.3.9
    Removing winapi-i686-pc-windows-gnu v0.4.0
    Removing winapi-util v0.1.5
    Removing winapi-x86_64-pc-windows-gnu v0.4.0
    Removing windows-sys v0.42.0
    Removing windows_aarch64_gnullvm v0.42.1
    Removing windows_aarch64_msvc v0.42.1
    Removing windows_i686_gnu v0.42.1
    Removing windows_i686_msvc v0.42.1
    Removing windows_x86_64_gnu v0.42.1
    Removing windows_x86_64_gnullvm v0.42.1
    Removing windows_x86_64_msvc v0.42.1
    Removing yansi v0.5.1
info: running `cargo hack check`
info: running `cargo check` on quick-xml (1/1)
    Checking quick-xml v0.27.1 (/home/dburgener/quick-xml)
error[E0432]: unresolved import `memchr::memchr2_iter`
 --> src/escapei.rs:3:5
  |
3 | use memchr::memchr2_iter;
  |     ^^^^^^^^^^^^^^^^^^^^ no `memchr2_iter` in the root

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
  --> src/reader/parser.rs:96:46
   |
96 |                     if let Some(p) = memchr::memchr_iter(b'-', &buf[3..len - 2])
   |                                              ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
   --> src/reader/mod.rs:773:26
    |
773 |         for i in memchr::memchr_iter(b'>', chunk) {
    |                          ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr2_iter` in crate `memchr`
   --> src/reader/mod.rs:815:43
    |
815 |                     let balance = memchr::memchr2_iter(b'<', b'>', content)
    |                                           ^^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr3_iter` in crate `memchr`
   --> src/reader/mod.rs:853:26
    |
853 |         for i in memchr::memchr3_iter(b'>', b'\'', b'"', chunk) {
    |                          ^^^^^^^^^^^^ not found in `memchr`

Some errors have detailed explanations: E0425, E0432.
For more information about an error, try `rustc --explain E0425`.
error: could not compile `quick-xml` due to 5 previous errors
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/cargo check --manifest-path Cargo.toml` (exit status: 101)
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/stable-x86_64-unknown-linux-gnu/bin/cargo hack check` (exit status: 1)

@dburgener
Copy link
Contributor Author

dburgener commented Feb 24, 2023

As far as I can tell, memchr*_iter() were all added in this memchr commit: BurntSushi/memchr@3120980, which first was in memchr 2.1, so although it is very confusing to me how it is not reproducing on your end, I do think that 2.1 seems like the correct minimum version for this dependency.

@Mingun
Copy link
Collaborator

Mingun commented Feb 24, 2023

Hm, it seems for me cargo somehow taken the lib from the cache. Could you add a change log entry and then we can merge.

@dburgener
Copy link
Contributor Author

Could you add a change log entry and then we can merge.

Yes, done.

Changelog.md Show resolved Hide resolved
@Mingun
Copy link
Collaborator

Mingun commented Feb 24, 2023

Ok, at least I understand how I get the false positive result. cargo minimal-versions check does not see any problems, but cargo minimal-versions test found the problems. Very strange behavior.

@Mingun Mingun merged commit 05b754b into tafia:master Feb 24, 2023
@dburgener dburgener deleted the memchr-min-version branch February 24, 2023 15:31
@dburgener
Copy link
Contributor Author

Very strange. I didn't try cargo minimal-versions test. It does seem to me as though there are some weird corner cases around optional dependencies in minimal-versions that aren't fully sorted out, so this is likely an aspect of that. In theory, the commenting around Cargo.toml shouldn't be necessary at all, and just running cargo minimal-versions check --no-default-features (or --each-feature) should catch this case consistently and cleanly, but that isn't the case.

What's strange to me is that based on the output here it looks like you were getting down to memchr 2.0, which shouldn't have compiled:

Updating memchr v2.5.0 -> v2.0.0

Unless that changed once you got the issue you were mentioning at that link sorted out?

@Mingun
Copy link
Collaborator

Mingun commented Feb 24, 2023

Maybe this is the nightly regression in cargo? I use nightly cargo with a GNU toolchain and due to inability to install MSVC tools cannot check on stable, because cargo minimum-versions tried to switch to nightly which on Windows assumes nightly-x86_64-pc-windows-msvc which I cannot install...

I filled a bug in cargo for that.

@dburgener
Copy link
Contributor Author

I think I can repro on nightly as well:

$ git diff
diff --git a/Cargo.toml b/Cargo.toml
index 872da6b..7611b27 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -17,7 +17,7 @@ include = ["src/*", "LICENSE-MIT.md", "README.md"]
 document-features = { version = "0.2", optional = true }
 encoding_rs = { version = "0.8", optional = true }
 serde = { version = "1.0.100", optional = true }
-tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
+#tokio = { version = "1.0", optional = true, default-features = false, features = ["io-util"] }
 memchr = "2.0"

 [dev-dependencies]
@@ -26,8 +26,8 @@ pretty_assertions = "1.3"
 regex = "1"
 serde = { version = "1.0", features = ["derive"] }
 serde-value = "0.7"
-tokio = { version = "1.21", default-features = false, features = ["macros", "rt"] }
-tokio-test = "0.4"
+#tokio = { version = "1.21", default-features = false, features = ["macros", "rt"] }
+#tokio-test = "0.4"

 [lib]
 bench = false
@@ -49,7 +49,7 @@ default = []
 ## [reading events] from types implementing [`tokio::io::AsyncBufRead`].
 ##
 ## [reading events]: crate::reader::Reader::read_event_into_async
-async-tokio = ["tokio"]
+#async-tokio = ["tokio"]

 ## Enables support of non-UTF-8 encoded documents. Encoding will be inferred from
 ## the XML declaration if it will be found, otherwise UTF-8 is assumed.
$ rustup run nightly cargo minimal-versions check
info: running `cargo update -Z minimal-versions`
    Updating crates.io index
    Removing aho-corasick v0.7.20
    Removing anes v0.1.6
    Removing async-stream v0.3.4
    Removing async-stream-impl v0.3.4
    Removing atty v0.2.14
    Removing autocfg v1.1.0
    Removing bitflags v1.3.2
    Removing bumpalo v3.12.0
    Removing bytes v1.4.0
    Removing cast v0.3.0
    Updating cfg-if v1.0.0 -> v0.1.0
    Removing ciborium v0.2.0
    Removing ciborium-io v0.2.0
    Removing ciborium-ll v0.2.0
    Removing clap v3.2.23
    Removing clap_lex v0.2.4
    Removing criterion v0.4.0
    Removing criterion-plot v0.5.0
    Removing crossbeam-channel v0.5.6
    Removing crossbeam-deque v0.8.2
    Removing crossbeam-epoch v0.9.13
    Removing crossbeam-utils v0.8.14
    Removing ctor v0.1.26
    Removing diff v0.1.13
    Updating document-features v0.2.7 -> v0.2.0
    Removing either v1.8.1
    Updating encoding_rs v0.8.32 -> v0.8.0
    Removing futures-core v0.3.26
    Removing half v1.8.2
    Removing hashbrown v0.12.3
    Removing hermit-abi v0.1.19
    Removing hermit-abi v0.2.6
    Removing indexmap v1.9.2
    Removing itertools v0.10.5
    Removing itoa v1.0.5
    Removing js-sys v0.3.61
    Removing lazy_static v1.4.0
    Updating libc v0.2.139 -> v0.2.18
    Removing litrs v0.2.3
    Removing log v0.4.17
    Updating memchr v2.5.0 -> v2.0.0
    Removing memoffset v0.7.1
    Removing num-traits v0.2.15
    Removing num_cpus v1.15.0
    Removing once_cell v1.17.1
    Removing oorandom v11.1.3
    Removing ordered-float v2.10.0
    Removing os_str_bytes v6.4.1
    Removing output_vt100 v0.1.3
    Removing pin-project-lite v0.2.9
    Removing plotters v0.3.4
    Removing plotters-backend v0.3.4
    Removing plotters-svg v0.3.3
    Removing pretty_assertions v1.3.0
    Removing proc-macro2 v1.0.51
    Updating quote v1.0.23 -> v0.3.8
    Removing rayon v1.6.1
    Removing rayon-core v1.10.2
    Removing regex v1.7.1
    Removing regex-syntax v0.6.28
    Removing ryu v1.0.12
    Removing same-file v1.0.6
    Removing scopeguard v1.1.0
    Updating serde v1.0.152 -> v1.0.100
    Removing serde-value v0.7.0
    Updating serde_derive v1.0.152 -> v1.0.0
      Adding serde_derive_internals v0.15.0
    Removing serde_json v1.0.93
    Updating syn v1.0.108 -> v0.11.10
      Adding synom v0.11.0
    Removing textwrap v0.16.0
    Removing tinytemplate v1.2.1
    Removing tokio v1.25.0
    Removing tokio-macros v1.8.2
    Removing tokio-stream v0.1.12
    Removing tokio-test v0.4.2
    Removing unicode-ident v1.0.6
      Adding unicode-xid v0.0.4
    Removing walkdir v2.3.2
    Removing wasm-bindgen v0.2.84
    Removing wasm-bindgen-backend v0.2.84
    Removing wasm-bindgen-macro v0.2.84
    Removing wasm-bindgen-macro-support v0.2.84
    Removing wasm-bindgen-shared v0.2.84
    Removing web-sys v0.3.61
    Removing winapi v0.3.9
    Removing winapi-i686-pc-windows-gnu v0.4.0
    Removing winapi-util v0.1.5
    Removing winapi-x86_64-pc-windows-gnu v0.4.0
    Removing windows-sys v0.42.0
    Removing windows_aarch64_gnullvm v0.42.1
    Removing windows_aarch64_msvc v0.42.1
    Removing windows_i686_gnu v0.42.1
    Removing windows_i686_msvc v0.42.1
    Removing windows_x86_64_gnu v0.42.1
    Removing windows_x86_64_gnullvm v0.42.1
    Removing windows_x86_64_msvc v0.42.1
    Removing yansi v0.5.1
info: running `cargo hack check`
info: running `cargo check` on quick-xml (1/1)
    Checking libc v0.2.18
    Checking memchr v2.0.0
    Checking quick-xml v0.27.1 (/home/dburgener/quick-xml)
error[E0432]: unresolved import `memchr::memchr2_iter`
 --> src/escapei.rs:3:5
  |
3 | use memchr::memchr2_iter;
  |     ^^^^^^^^^^^^^^^^^^^^ no `memchr2_iter` in the root

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
  --> src/reader/parser.rs:96:46
   |
96 |                     if let Some(p) = memchr::memchr_iter(b'-', &buf[3..len - 2])
   |                                              ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr_iter` in crate `memchr`
   --> src/reader/mod.rs:773:26
    |
773 |         for i in memchr::memchr_iter(b'>', chunk) {
    |                          ^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr2_iter` in crate `memchr`
   --> src/reader/mod.rs:815:43
    |
815 |                     let balance = memchr::memchr2_iter(b'<', b'>', content)
    |                                           ^^^^^^^^^^^^ not found in `memchr`

error[E0425]: cannot find function `memchr3_iter` in crate `memchr`
   --> src/reader/mod.rs:853:26
    |
853 |         for i in memchr::memchr3_iter(b'>', b'\'', b'"', chunk) {
    |                          ^^^^^^^^^^^^ not found in `memchr`

Some errors have detailed explanations: E0425, E0432.
For more information about an error, try `rustc --explain E0425`.
error: could not compile `quick-xml` due to 5 previous errors
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo check --manifest-path Cargo.toml` (exit status: 101)
error: process didn't exit successfully: `/home/dburgener/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/bin/cargo hack check` (exit status: 1)

@Mingun
Copy link
Collaborator

Mingun commented Feb 24, 2023

It seems that VSCode with rust-analyzer is guilty (RA updates Cargo.lock to latest versions after downgrading versions but before actual check).

crapStone added a commit to Calciumdibromid/CaBr2 that referenced this pull request Mar 16, 2023
This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
| [quick-xml](https://github.com/tafia/quick-xml) | dependencies | minor | `0.27.1` -> `0.28.0` |

---

### Release Notes

<details>
<summary>tafia/quick-xml</summary>

### [`v0.28.0`](https://github.com/tafia/quick-xml/blob/HEAD/Changelog.md#&#8203;0280----2023-03-13)

[Compare Source](tafia/quick-xml@v0.27.1...v0.28.0)

##### New Features

-   [#&#8203;541]: (De)serialize specially named `$text` enum variant in [externally tagged]
    enums to / from textual content
-   [#&#8203;556]: `to_writer` and `to_string` now accept `?Sized` types
-   [#&#8203;556]: Add new `to_writer_with_root` and `to_string_with_root` helper functions
-   [#&#8203;520]: Add methods `BytesText::inplace_trim_start` and `BytesText::inplace_trim_end`
    to trim leading and trailing spaces from text events
-   [#&#8203;565]: Allow deserialize special field names `$value` and `$text` into borrowed
    fields when use serde deserializer
-   [#&#8203;568]: Rename `Writter::inner` into `Writter::get_mut`
-   [#&#8203;568]: Add method `Writter::get_ref`
-   [#&#8203;569]: Rewrite the `Reader::read_event_into_async` as an async fn, making the future `Send` if possible.
-   [#&#8203;571]: Borrow element names (`<element>`) when deserialize with serde.
    This change allow to deserialize into `HashMap<&str, T>`, for example
-   [#&#8203;573]: Add basic support for async byte writers via tokio's `AsyncWrite`.

##### Bug Fixes

-   [#&#8203;537]: Restore ability to deserialize attributes that represents XML namespace
    mappings (`xmlns:xxx`) that was broken since [#&#8203;490]
-   [#&#8203;510]: Fix an error of deserialization of `Option<T>` fields where `T` is some
    sequence type (for example, `Vec` or tuple)
-   [#&#8203;540]: Fix a compilation error (probably a rustc bug) in some circumstances.
    `Serializer::new` and `Serializer::with_root` now accepts only references to `Write`r.
-   [#&#8203;520]: Merge consequent (delimited only by comments and processing instructions)
    texts and CDATA when deserialize using serde deserializer. `DeEvent::Text` and
    `DeEvent::CData` events was replaced by `DeEvent::Text` with merged content.
    The same behavior for the `Reader` does not implemented (yet?) and should be
    implemented manually
-   [#&#8203;562]: Correctly set minimum required version of memchr dependency to 2.1
-   [#&#8203;565]: Correctly set minimum required version of tokio dependency to 1.10
-   [#&#8203;565]: Fix compilation error when build with serde <1.0.139

[externally tagged]: https://serde.rs/enum-representations.html#externally-tagged

[#&#8203;490]: tafia/quick-xml#490

[#&#8203;510]: tafia/quick-xml#510

[#&#8203;520]: tafia/quick-xml#520

[#&#8203;537]: tafia/quick-xml#537

[#&#8203;540]: tafia/quick-xml#540

[#&#8203;541]: tafia/quick-xml#541

[#&#8203;556]: tafia/quick-xml#556

[#&#8203;562]: tafia/quick-xml#562

[#&#8203;565]: tafia/quick-xml#565

[#&#8203;568]: tafia/quick-xml#568

[#&#8203;569]: tafia/quick-xml#569

[#&#8203;571]: tafia/quick-xml#571

[#&#8203;573]: tafia/quick-xml#573

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [Renovate Bot](https://github.com/renovatebot/renovate).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNS42LjAiLCJ1cGRhdGVkSW5WZXIiOiIzNS42LjAifQ==-->

Co-authored-by: cabr2-bot <cabr2.help@gmail.com>
Co-authored-by: crapStone <crapstone01@gmail.com>
Reviewed-on: https://codeberg.org/Calciumdibromid/CaBr2/pulls/1818
Reviewed-by: crapStone <crapstone@noreply.codeberg.org>
Co-authored-by: Calciumdibromid Bot <cabr2_bot@noreply.codeberg.org>
Co-committed-by: Calciumdibromid Bot <cabr2_bot@noreply.codeberg.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants