profile
viewpoint
Marc-Antoine Perennou Keruspe Clever Cloud Nantes http://www.imagination-land.org/ SRE @CleverCloud and @Exherbo core developer.

CleverCloud/lapin 437

AMQP client library in Rust, with a clean, futures based API

CleverCloud/amq-protocol 17

AMQP specifications

async-rs/async-global-executor 12

A global executor built on top of async-executor and smol

CleverCloud/biscuit-java 8

Java implementation of the Biscuit authentication and authorization token

Keruspe/Bomb-her-man 8

Bomberman clone written in C++

Keruspe/blog 7

Personal blog, based on hakyll

Keruspe/brainfuck.rs 5

Brainfuck parser written in rust using nom

Keruspe/Abalone 3

Abalone, in java

Kdecherf/kdecherf-exheres 2

Kdecherf's personal Exherbo repository

Bruners/exheres 1

Bruners' user repository for exherbo

issue commenttokio-rs/tokio

Replacement for Handle::current

You are using a tokio 0.3 runtime and your dependency is trying to get a handle to a tokio 0.2 runtime which is different from your tokio 0.3 runtime. You can use the compat crate to spawn your code inside of a tokio 0.2 runtime which will leave alongside your tokio 0.3 one.

Darksonn

comment created time in 17 hours

issue openedtokio-rs/tokio

macros: add a way to get the runtime from the body we launch

As said in #2965 we're now supposed to use an Arc<Runtime> and pass it around instead of calling Handle::current().

While this can be achieved when creating the Runtime manually, it's not possible when using #[tokio::main] as the Runtime isn't passed to the main body.

There should be a way to access it either through an argument, a local variable or a static one.

created time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha 9e59515168bea0e782471d9a2d04108145a538c4

add weblate link Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

issue closedKeruspe/GPaste

Translations

What is the preferred method of contributing translations? Could the project be added on Hosted Weblate or similar?

closed time in 3 days

comradekingu

issue commentKeruspe/GPaste

Translations

Pending approval but everything should be set up now!

comradekingu

comment created time in 3 days

MemberEvent

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha 17d3bde97581988cad43c9236daa0531ba0cd84e

update-po Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha 56dc75c1d009decf24eb4d352759bf047e9b0dc0

update-po, add pot Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

push eventCleverCloud/lapin

Maxim Zhiburt

commit sha 11df8c357f60a7b96d524e29a4fd156988a69cbb

Update README.md (#307) tokio: Update README.md Signed-off-by: Maxim Zhiburt <zhiburt@gmail.com>

view details

Marc-Antoine Perennou

commit sha 62ab9a2d25c0931dbec601defaa0770f0af2850d

v0.2.1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 8c26f9c6cc74c494a0ce7bd43e10d91e9fb3d047

Merge branch 'lapin-1.x' * lapin-1.x: v0.2.1 Update README.md (#307)

view details

Marc-Antoine Perennou

commit sha ebef2abae78aa01c6abfc7be76bff38ef11224a4

tokio: update to 0.3.1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha dc2c0e9123d50a118d39475c0f7ef44e5999364d

gnome-shell: drop unused variable Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha de8b29ad9adeeb646b0272b3a5e39046f4d1e98b

gnome-shell: Set index to -1 for items over actual size Fixes #301 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha ed68dd31420cb019ac765f8192c0c33778e91577

gnome-shell: oops Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

pull request commentKeruspe/GPaste

fix #301

Thanks for pointing in the right direction :)

tuberry

comment created time in 3 days

PR closed Keruspe/GPaste

fix #301

A rough solution.

+7 -3

1 comment

1 changed file

tuberry

pr closed time in 3 days

pull request commentKeruspe/GPaste

fix #301

Proper fix in https://github.com/Keruspe/GPaste/commit/61aee84fd9e0eb881bb11ab7c11c1f4bcdf0afa0

tuberry

comment created time in 3 days

push eventKeruspe/GPaste

Marc-Antoine Perennou

commit sha 61aee84fd9e0eb881bb11ab7c11c1f4bcdf0afa0

gnome-shell: Set index to -1 for items over actual size Fixes #301 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 3 days

issue closedKeruspe/GPaste

JS ERROR on extension startup

I have a bunch of these printed when the shell extension is started:

avril 01 17:26:51 terence-desktop gnome-shell[2015]: JS ERROR: Gio.IOErrorEnum: GDBus.Error:org.gnome.GPaste.Error: invalid index received
                                                     setIndex/<@/usr/share/gnome-shell/extensions/GPaste@gnome-shell-extensions.gnome.org/item.js:72:37

This does not seem to affect usability.

  • gpaste 3.36.3
  • ArchLinux
  • gnome-shell 3.36.1

closed time in 3 days

terencode

pull request commentKeruspe/GPaste

Typo in manual page

Thanks

kapouer

comment created time in 3 days

push eventKeruspe/GPaste

Jérémy Lal

commit sha 48b4712e0300d3d3ac723dc3b745890304e57e3b

Typo in manual page

view details

push time in 3 days

PR merged Keruspe/GPaste

Typo in manual page
+2 -2

0 comment

1 changed file

kapouer

pr closed time in 3 days

push eventKeruspe/tokio

Marc-Antoine Perennou

commit sha 430e97430bfc161fc67973363204c7cda2a2cf86

tokio: deduplicate spawn_blocking Move common code and tracing integration into Handle Fixes #2998 Closes #3004 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 4 days

PR opened tokio-rs/tokio

tokio: deduplicate spawn_blocking

Move common code and tracing integration into Handle

Fixes #2998 Closes #3004

+27 -21

0 comment

4 changed files

pr created time in 4 days

create barnchKeruspe/tokio

branch : blocking-tracing

created branch time in 4 days

pull request commentrust-lang/rust

add system-llvm-libunwind config option

Not sure what happened with CI here

Keruspe

comment created time in 4 days

issue commentKeruspe/GPaste

Translations

@comradekingu thanks, greatly appreciated. Just added you

comradekingu

comment created time in 4 days

issue commentKeruspe/GPaste

Translations

Hi,

For now the translations have been submitted through github pull requests. I'm not really familiar with any of the translation platforms but last time I checked those were pretty expensive, and GPaste is definitely not a commercial product nor backed by any company so... But I'm fuly open to any platform which would be free for open source projects

comradekingu

comment created time in 4 days

Pull request review commenttokio-rs/mio

tests: use our own TcpSocket instead of socket2

 fn hup() {  #[cfg(windows)] fn set_linger_zero(socket: &TcpStream) {-    use socket2::Socket;+    use mio::net::TcpSocket;     use std::os::windows::io::{AsRawSocket, FromRawSocket}; -    let s = unsafe { Socket::from_raw_socket(socket.as_raw_socket()) };+    let s = unsafe { TcpSocket::from_raw_socket(socket.as_raw_socket()) };

Done

Keruspe

comment created time in 4 days

PullRequestReviewEvent

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 878e17a6b88f33cc92883810d901308dc3fc11c0

tests: cleanup set_linger_zero Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 4 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 133e5db43e7c4a4d0ef19249bbe0949e01f6a16e

tests: rename, add comment Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Thomas de Zeeuw

commit sha 52fa1a33ac339f0379bb4b5cdbc967cee511244f

Remove RUST_TEST_THREADS: "1" from CI

view details

push time in 5 days

Pull request review commenttokio-rs/tokio

tokio: add tracing to Runtime::spawn_blocking

 where     F: FnOnce() -> R + Send + 'static,     R: Send + 'static, {-    #[cfg(feature = "tracing")]-    let f = {-        let span = tracing::trace_span!(-            target: "tokio::task",-            "task",-            kind = %"blocking",-            function = %std::any::type_name::<F>(),-        );-        move || {-            let _g = span.enter();-            f()-        }-    };     crate::runtime::spawn_blocking(f)

crate::runtime::Runtime::spawn_blocking is basically a copy of crate::runtime::blocking::pool::spawn_blocking, except the former is already inside a Runtime, so it uses its internal handle, whilst the latter gets the current handle and uses it. We could avoid the duplication by implementing this on Handle directly.

Moving the tracing integration around isn't the right call here though. We should either copy it or move that into Handle

bahildebrand

comment created time in 5 days

PullRequestReviewEvent

Pull request review commenttokio-rs/tokio

tokio: add tracing to Runtime::spawn_blocking

 where     F: FnOnce() -> R + Send + 'static,     R: Send + 'static, {-    #[cfg(feature = "tracing")]-    let f = {-        let span = tracing::trace_span!(-            target: "tokio::task",-            "task",-            kind = %"blocking",-            function = %std::any::type_name::<F>(),-        );-        move || {-            let _g = span.enter();-            f()-        }-    };     crate::runtime::spawn_blocking(f)

crate::runtime::spawn_blocking is a reexport for crate::runtime::blocking::pool::spawn_blocking which is basically crate::task::spawn_blocking, yes. It's not crate::runtime::Runtime::spawn_blocking

bahildebrand

comment created time in 5 days

PullRequestReviewEvent

PR opened tokio-rs/mio

tests: use our own TcpSocket instead of socket2

Alternative for part of #1372

+4 -5

0 comment

2 changed files

pr created time in 5 days

create barnchKeruspe/mio

branch : no-socket2

created branch time in 5 days

push eventKeruspe/rust

Marc-Antoine Perennou

commit sha c498b03c88ad2f707c5400b2a71c681177765337

add config::LlvmLibunwind enum Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 5 days

Pull request review commentrust-lang/rust

add system-llvm-libunwind config option

 impl Build {     fn std_features(&self) -> String {         let mut features = "panic-unwind".to_string(); -        if self.config.llvm_libunwind {-            features.push_str(" llvm-libunwind");+        match self.config.llvm_libunwind.as_deref() {+            Some("in-tree") => features.push_str(" llvm-libunwind"),+            Some("system") => features.push_str(" system-llvm-libunwind"),+            Some("no") | None => {}+            Some(invalid) => {+                panic!("Invalid value '{}' for rust.llvm-libunwind config.", invalid);

Done

Keruspe

comment created time in 5 days

PullRequestReviewEvent

push eventKeruspe/rust

Marc-Antoine Perennou

commit sha 73210ab8ea22b1f08d2f54056278d98098f3006c

add config::LlvmLibunwind enum Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 5 days

Pull request review commentrust-lang/rust

add system-llvm-libunwind config option

 changelog-seen = 1 #test-compare-mode = false  # Use LLVM libunwind as the implementation for Rust's unwinder.-#llvm-libunwind = false+# Accepted values are 'in-tree' (formerly true) or 'system'.+# Any other value is ignored (formerly false).

Went with "no" so that it's obvious that a string is expected and not a bool. Not sure if there's a cleaner way to reject an invalid config value right now, I don't think there is such a validation for other fields

Keruspe

comment created time in 5 days

PullRequestReviewEvent

push eventKeruspe/rust

Marc-Antoine Perennou

commit sha c7e313c1e833397d98e254921e55ac71bbcfd83b

llvm-libunwind: reject invalid values Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 5 days

Pull request review commenthsablonniere/hsablonniere.com

article: add "Once upon a blog..."

+---+title: Once upon a blog...+date: 2020-10-20+tags: article+layout: article.njk+---++<style>+h3 img {+  margin-right: 0.25rem;+  vertical-align: middle;+  width: 1.5rem;+}+</style>++🎉 The date is October 16, 2020 and I can officially say: **I have a blog now!**

s/16/20/ ?

hsablonniere

comment created time in 5 days

PullRequestReviewEvent

pull request commenthsablonniere/hsablonniere.com

article: add "Once upon a blog..."

👀

hsablonniere

comment created time in 5 days

created tagCleverCloud/lapin

tagtokio-amqp-0.2.1

AMQP client library in Rust, with a clean, futures based API

created time in 6 days

push eventCleverCloud/lapin

Maxim Zhiburt

commit sha 11df8c357f60a7b96d524e29a4fd156988a69cbb

Update README.md (#307) tokio: Update README.md Signed-off-by: Maxim Zhiburt <zhiburt@gmail.com>

view details

Marc-Antoine Perennou

commit sha 62ab9a2d25c0931dbec601defaa0770f0af2850d

v0.2.1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 6 days

pull request commentCleverCloud/lapin

Update README.md

Thanks

zhiburt

comment created time in 6 days

push eventCleverCloud/lapin

Maxim Zhiburt

commit sha c624d6f5786ab79ce97345d5bba3a0b5990a7220

Update README.md (#307) tokio: Update README.md Signed-off-by: Maxim Zhiburt <zhiburt@gmail.com>

view details

push time in 6 days

PR merged CleverCloud/lapin

Update README.md

I am not sure if any other runtimes need to be update README

+9 -3

1 comment

1 changed file

zhiburt

pr closed time in 6 days

pull request commentCleverCloud/lapin

Update README.md

Heh, indeed. It should be the only one.

Could you leave the comment though?

zhiburt

comment created time in 6 days

created tagasync-rs/async-global-executor

tagv1.4.2

A global executor built on top of async-executor and smol

created time in 6 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha 734625a254d6ebb73bdb60a6ab81f68fbc58844d

drop avoidable Arc Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 583469072fdf43bbc39e4c9f4f3f5e9a651100a5

v1.4.2 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 6 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha f8bd46f9be7a624802c99d85a17b2282fe25a7fa

simplify block_on Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 6 days

created tagasync-rs/async-global-executor

tagv1.4.1

A global executor built on top of async-executor and smol

created time in 6 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha eb9caf2b5bb5bef080a054892823b116ed2fe1a3

tokio02: drop async-compat Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 8997a42048be19cbe6b9f85ec78560f9ee611731

v1.4.1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 6 days

Pull request review commentasync-rs/async-std

Update dependencies

 use async_std::task; -fn main() -> Result<(), surf::Exception> {+fn main() -> Result<(), http_types::Error> {

Indeed, fixed!

Keruspe

comment created time in 6 days

PullRequestReviewEvent

push eventKeruspe/async-std

Marc-Antoine Perennou

commit sha f0c8a8b4e9a2e7d130a494f4fb5c00d82c2c5c97

update surf Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 6 days

PR opened async-rs/async-std

Update dependencies
+8 -12

0 comment

2 changed files

pr created time in 7 days

create barnchKeruspe/async-std

branch : deps

created branch time in 7 days

push eventCleverCloud/amq-protocol

Marc-Antoine Perennou

commit sha 19ccc560b9c934aa4317c0288b2a9218a9709df8

update to nom 6.0.0-beta1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 7 days

pull request commentrust-lang/rust

add system-llvm-libunwind config option

@Mark-Simulacrum Did some more testing on some of my systems and I think this is good to go now?

Keruspe

comment created time in 7 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha 3f0d6ce7d68ac6a57c72bbf2909a51d44668a777

typo Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 7 days

create barnchKeruspe/tokio

branch : blocking

created branch time in 8 days

PR opened tokio-rs/tokio

tokio: add Runtime::spawn_blocking

This allows writing

rt.spawn_blocking(f);

instead of

let _enter = rt.enter();
tokio::task::spawn_blocking(f);
+26 -0

0 comment

1 changed file

pr created time in 8 days

pull request commentrusty-celery/rusty-celery

Update tokio requirement from 0.2.13 to 0.3.0

@epwalsh just published tokio-amqp 0.2 which uses tokio 0.3

dependabot[bot]

comment created time in 8 days

push eventCleverCloud/lapin

Marc-Antoine Perennou

commit sha e3b4834b27df8357a435b2c57e2df9e57e01fda8

consumer: dont cancel when converting to iterator Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 28c184685b5ea0290a2709c9c9c74dc104087645

v1.4.1 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 786ed5014fa50337939a4f90e5c6f44e4727fe1a

Merge branch 'lapin-1.x' into master * lapin-1.x: v1.4.1 consumer: dont cancel when converting to iterator

view details

Marc-Antoine Perennou

commit sha f119dba7e335941ec1eb23e3d0a910308b0ddb31

consumer: drop iterator we're full async now Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha d6c147dfb39edcc4dc4413369fe34cb3322ea621

rework internal RPC handling Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 5680cad9f8a8ef70caebd9c3658e84d26cf37087

wakers: clone less Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha ab1cf54e1750e7fd06e54f440ea71a86612d6926

fix doc url Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 703482a8ff126de813cb3c4d53b01794e3d5e317

async-amqp: v0.1.7 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 09f185423a17ea7262752de26db2fd2605baf484

tokio-amqp: update to tokio 0.3 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 9e00142ece4a516b2ae392b0665a22a11eee2c29

update deps Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 55f55774bbc41dcde081955cd12035545dd87557

v1.4.2 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 9313ea1041994d806fbb01c1aba4625506a2de82

Merge branch 'lapin-1.x' * lapin-1.x: v1.4.2 update deps tokio-amqp: update to tokio 0.3 async-amqp: v0.1.7 fix doc url

view details

push time in 8 days

push eventCleverCloud/lapin

Marc-Antoine Perennou

commit sha ab1cf54e1750e7fd06e54f440ea71a86612d6926

fix doc url Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 703482a8ff126de813cb3c4d53b01794e3d5e317

async-amqp: v0.1.7 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 09f185423a17ea7262752de26db2fd2605baf484

tokio-amqp: update to tokio 0.3 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 9e00142ece4a516b2ae392b0665a22a11eee2c29

update deps Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 55f55774bbc41dcde081955cd12035545dd87557

v1.4.2 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 8 days

issue commenttokio-rs/tokio

Replacement for Handle::current

Also, when using the tokio macro #[tokio::main] there is no way of accesssing the Arc<Runtime> unless I missed something?

Darksonn

comment created time in 8 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha b9e483d0d9dfcbfe12b3e65a15a4ecd862dbfc47

missing CHANGELOG entry Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 9 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha 3a72be2a6a5eb5d603168ab5fa76ed08d1c03fd3

rustfmt Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 9 days

PR opened async-rs/async-std

add tokio03 feature

Similar to the tokio02 one

+2 -1

0 comment

1 changed file

pr created time in 9 days

create barnchKeruspe/async-std

branch : tokio03

created branch time in 9 days

created tagasync-rs/async-global-executor

tagv1.4.0

A global executor built on top of async-executor and smol

created time in 9 days

push eventasync-rs/async-global-executor

Marc-Antoine Perennou

commit sha f06cebbff1bf77f1f34649d848a63675b1884cdd

rename tokio dev-dependency Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 0b450898f0a32f8e31dc603e0bdba9bf09b529df

add tokio03 compatibility Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 6ab6ec6f075b27815ded6004a6f49a2f44bcf7c4

v1.4.0 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 9 days

issue openedstjepang/async-compat

Update for tokio 0.3

tokio 0.3 has been released, it would be nice to have async-compat follow this

created time in 9 days

issue commentCleverCloud/lapin

Help: How to debug connectionReset/ConnectionAborted issue

Would you happen to have some kind of minimal reproducer?

dovreshef

comment created time in 9 days

PullRequestReviewEvent

Pull request review commenttokio-rs/mio

Drop net2 dev-dependency

 pub(crate) fn set_reuseaddr(socket: TcpSocket, reuseaddr: bool) -> io::Result<()     } } +pub(crate) fn set_linger(socket: TcpSocket, dur: Option<Duration>) -> io::Result<()> {+    use winapi::ctypes::{c_char, c_int, c_ushort};+    use winapi::um::winsock2::{linger, setsockopt, SOCKET_ERROR, SO_LINGER, SOL_SOCKET};+    use std::mem::size_of;++    let val: linger = linger {+        l_onoff: if dur.is_some() { 1 } else { 0 },+        l_linger: dur.map(|dur| dur.as_secs() as c_ushort).unwrap_or_default(),+    };++    match unsafe { setsockopt(+        socket,+        SOL_SOCKET,+        SO_LINGER,+        &val as *const _ as *const c_char,+        size_of::<linger>() as c_int,+    ) } {+        0 => Ok(()),+        SOCKET_ERROR => Err(io::Error::last_os_error()),+        _ => panic!("unexpected return value"),

Done

Keruspe

comment created time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 0a0c03f0203eead3c8f90367055cf1a2174a2353

TcpSocket: add set_linger method inspired by how it was done in net2 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha e626148bfee16186a412c4bb82416e567001807e

tests: drop net2 usage Use our own TcpSocket instead Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 9fcac6aab859cfce0b8b5d176d35f281d46278a4

tests: don't restrict connection_reset_by_peer to unix Now that we use our own TcpSocket, we can run this on windows too Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 3cdef54bf0c52c458c1e8a59c0d4ab6d4796f104

silence clippy warning Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha dff6f3ae2ca6866e024a074e1fab0d128db66f2b

TcpSocket: formatting nits Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 0e971349e33cd3fc712837469bffe9a337ed7a4e

TcpSocket: don't panic on windows Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

pull request commenttokio-rs/mio

Drop net2 dev-dependency

Fixed the nits, and fixed them in set_reuseaddr too while at it

Keruspe

comment created time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 55e1fea9370c5a4f68ea8e2770eaa7d58da4b80f

TcpSocket: don't panic on windows Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

Pull request review commenttokio-rs/mio

Drop net2 dev-dependency

 pub(crate) fn set_reuseaddr(socket: TcpSocket, reuseaddr: bool) -> io::Result<()     } } +pub(crate) fn set_linger(socket: TcpSocket, dur: Option<Duration>) -> io::Result<()> {+    use winapi::ctypes::{c_char, c_int, c_ushort};+    use winapi::um::winsock2::{linger, setsockopt, SOCKET_ERROR, SO_LINGER, SOL_SOCKET};+    use std::mem::size_of;++    let val: linger = linger {+        l_onoff: if dur.is_some() { 1 } else { 0 },+        l_linger: dur.map(|dur| dur.as_secs() as c_ushort).unwrap_or_default(),+    };++    match unsafe { setsockopt(+        socket,+        SOL_SOCKET,+        SO_LINGER,+        &val as *const _ as *const c_char,+        size_of::<linger>() as c_int,+    ) } {+        0 => Ok(()),+        SOCKET_ERROR => Err(io::Error::last_os_error()),+        _ => panic!("unexpected return value"),

This is what set_reuseaddr does too just above

Keruspe

comment created time in 11 days

PullRequestReviewEvent

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 31e0e9b9de0eb2b1268baff2f12f3c12a1e336c5

TcpSocket: formatting nits Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha d4c518e73c1fbabd384bb10c95226ef5d80c233d

TcpSocket: fix typo in set_linger Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

pull request commenttokio-rs/mio

Drop net2 dependency

And once tokio 0.3 is out, it will definitely stop, yep :+1:

Keruspe

comment created time in 11 days

pull request commenttokio-rs/mio

Drop net2 dependency

@Thomasdezeeuw It just adds TcpSocket::set_linger and replaces the use of net2 in tests by TcpSocket now that we have it, yep.

I know net2 is only a dev-dependency in mio 0.7, but if we even remove the dev-dependency, requests to add socket2 instead might stop, since it won't be listed at all in master?

Keruspe

comment created time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 542df028c6dbd21d2ef6a5a3cbb979275ebf2cb8

actually drop the net2 dependency Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha bc5d94189fa6162faaf677694c3be119afaf7b23

silence clippy warning Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha 56067746d2aebf0b2cebbda1a0564dd42b38f452

silence clippy warning Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha f97c72683d618be5f54cae3d30e7c872ea77a2dc

tests: don't restrict connection_reset_by_peer to unix Now that we use our own TcpSocket, we can run this on windows too Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

pull request commenttokio-rs/mio

Drop net2 dependency

Clippy failure is unrelated (and probably requires updating the MSRV to "fix")

Keruspe

comment created time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha eb51319cfac43175e896776ea4e365edcaefc58b

tests: drop net2 usage Use our own TcpSocket instead Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

pull request commenttokio-rs/mio

Drop net2 dependency

Oops, there were some stale commits in my local clone, dropped those.

Keruspe

comment created time in 11 days

push eventKeruspe/mio

Marc-Antoine Perennou

commit sha e07e0877c50e9c63d82bd599bf94058ac706f5eb

TcpSocket: add set_linger method inspired by how it was done in net2 Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

Marc-Antoine Perennou

commit sha 3cf1f34986111b9c0f6f0569daa3802384c77ef2

tests: drop net2 usage Use our own TcpSocket instead Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>

view details

push time in 11 days

PR opened tokio-rs/mio

Drop net2 dependency

Now that we have out own TcpSocket builder inside of mio, just add a set_linger method to it and switch away from net2.

This doesn't bring socket2 in and hopefully will stop all the recurring "please switch from net2 to socket2" reports

+114 -11

0 comment

7 changed files

pr created time in 11 days

create barnchKeruspe/mio

branch : no-net2

created branch time in 11 days

more