Comments (7)
My suspicion is that the drag was never completed and crashes when the window goes away. Do we check for this?
from xmonad.
(The ones that are caught don't include an executable name; they just print the exception as is.)
I don't think that this is true. I can reproduce the spam of
user error (Error in function getWindowAttributes)
once the window goes away, but can't reproduce the crash at all. Indeed, making the following change
diff --git a/src/XMonad/Core.hs b/src/XMonad/Core.hs
index 631f847..0c6b5a5 100644
--- a/src/XMonad/Core.hs
+++ b/src/XMonad/Core.hs
@@ -196,7 +196,7 @@ catchX job errcase = do
c <- ask
(a, s') <- io $ runX c st job `E.catch` \e -> case fromException e of
Just (_ :: ExitCode) -> throw e
- _ -> do hPrint stderr e; runX c st errcase
+ _ -> do hPrint stderr ("CAUGHT: " <> show e); runX c st errcase
put s'
return a
and going over the recipe again correctly prints
"CAUGHT: user error (Error in function getWindowAttributes)"
to stderr. These exceptions seem to be correctly caught inside of some userCode
call.
from xmonad.
Isn't that what I said about the usual ones? The point is that somewhere there's an uncaught one. I'll probably need to do a profiling build and a reproducer to spot the one that leaked.
from xmonad.
Oh sorry, my brain must have s/executable name/function name/
'd
from xmonad.
Can you consistently reproduce this with the above setup? If yes, and you think it's really the dragging, perhaps try adding an explicit userCodeDef
to the dragging code
diff --git a/src/XMonad/Operations.hs b/src/XMonad/Operations.hs
index 9101cc0..7ff44df 100644
--- a/src/XMonad/Operations.hs
+++ b/src/XMonad/Operations.hs
@@ -783,9 +783,7 @@ mouseDragCursor cursorGlyph f done = do
withDisplay $ io . flip ungrabPointer currentTime
modify $ \s -> s { dragging = Nothing }
done
- motion x y = do z <- f x y
- clearEvents pointerMotionMask
- return z
+ motion x y = userCodeDef () (f x y) >>= \z -> z <$ clearEvents pointerMotionMask
-- | Drag the window under the cursor with the mouse while it is dragged.
mouseMoveWindow :: Window -> X ()
from xmonad.
I can't reproduce it now for some reason: I get the mis-sized window, but it drags for both move and resize fine. I wonder what went wrong the first time.
from xmonad.
Curiously, I arranged for a dialog to disappear on xmonad during a drag and can't reproduce even that way. (The original circumstances I am assuming are due to some weirdness in my setup that I can't reliably reproduce and seems to be tied to something completely unrelated, so I haven't bothered to report it.)
Closing for now.
from xmonad.
Related Issues (20)
- [BUG] Mixed color with focused / unfocused borders HOT 3
- please make hackage release that's buildable with ghc-9.6.1 HOT 2
- Google Meet window sharing only lists windows from current desktop instead of all HOT 15
- Unable to install because of Prelude.chr: bad argument: 3959423081 HOT 6
- game launchers make xmonad overloaded
- Some VSTs (I think JUCE based ones? Or something) have broken popups that disappear upon hovering, and mouse clicks don't get registered. HOT 12
- Modal dialogs make xmonad's cpu usage spike up HOT 3
- CHANGES.md: `willFloat` is added in the wrong section (0.17.0 instead of 0.17.1) HOT 1
- Infelicity in `INSTALL.md`
- Confirmation prompt not appearing HOT 8
- Polybar modules title-xmonad and workspaces-xmonad not appearing
- Cite Conor's Zipper paper properly HOT 2
- Compiling XMonad fails with relocation error unless --disable-shared is added HOT 1
- ghc 9.8 `-Wx-partial` warnings HOT 1
- `borderWidth = 0` breaks workspaces with full-screen applications. HOT 3
- Recent env var changes were omitted from the changelog HOT 2
- [ISSUE (?)] Toggle Gaps + Tab layout and sublayouts spacing isuue HOT 8
- [ISSUE] Fix Tabs and Decoration spacing using a common Spacing Raw for layouts HOT 15
- Saving of extended state to file on exit is not done in default config? HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xmonad.