Suitable HTTP response for "not authorized" but without giving a...
I am writing a HTTP service. I want the status codes to distinguish between two states:user is not logged-inuser is logged-in but may not perform a given actionIt seems like HTTP 403 Forbidden...
View ArticleIs there a unicode dash without padding? [closed]
Here is a list of unicode dash characters: https://www.compart.com/en/unicode/category/PdAre any of these specified to have zero padding -- as in if I were to have two of them consecutively, a...
View ArticleIgnore changes to .gitignored files which were force-added
I want to add a certain file to my git repository, but ignore any subsequent changes.In my .gitignore I havepath/to/ignored_filesAnd I had to$> git add -f path/to/ignored_files/footo add these...
View Article.vim/syntax/sql.vim: Error detected while processing BufRead Autocommands for...
I tried saving this vim syntax file for sql but when I open a sql file in vim I get lots and lots of stuff like this:Error detected while processing BufRead Autocommands for "*.sql"..function...
View Articleonclick not firing on td when outside element has focus
I have a <input> which performs a search in Javascript when onchange, onkeydown etc fires. This builds a <table> of results which is displayed below the <input> using position:...
View Articleunexpected implicit "DEFAULT NULL" on non-null columns when `INSERT IGNORE`...
I just ran this on MySql 8 using InnoDBCREATE TABLE TuneName( id BIGINT NOT NULL AUTO_INCREMENT PRIMARY KEY, tune_id BIGINT NOT NULL, name VARCHAR (100) NOT NULL, norm VARCHAR (100) NOT NULL,...
View ArticleHow should mysql.connector be shared correctly with threads in Django...
This concerns a potential solution to my earlier question in which I was getting commands out of sync; you can't run this command now after wrapping mysql cursors in __enter__ and __exit__.I have read...
View ArticleWhen can I expect multiple "choices" in an OpenAI response?
For a simple OpenAI api call in pythonresponse = openai.ChatCompletion.create( model="gpt-4", messages=[ {"role": "system", "content": instructions}, {"role": "user", "content": my_input} ])I get...
View ArticleAnswer by spraff for "Column X cannot be null" happening when that column is...
This was caused by a trigger, which needed an IFNULL(...,0) to prevent it inserting a NULL when data was missing.
View ArticleWhy isn't my Qt eventFilter picking up mouse events on a QTreeWidget?
I have basically this code to intercept certain QTreeWidget events.MyWidget :: MyWidget (){ m_tree = new QTreeWidget (); // ... m_tree -> installEventFilter (this);}bool MyWidget :: eventFilter...
View ArticleOpenSSL as a CA without touching the certs/crl/index/etc environment
I think I have the right OpenSSL command to sign a certificate but I've gotten stuck and the tutorials I've found use a different argument format (I'm using OpenSSL 0.9.8o 01 Jun 2010).openssl ca -cert...
View Articledocker-compose --abort-on-container-exit doesn't stop tor services [closed]
I use a tor docker service, which is working in my docker-compose fileservices: tor: image: dockurr/tor my_task: image: ...I run this with docker-compose up --abort-on-container-exit and when my_task...
View ArticleJavascript backtrace
How to I get a backtrace in Javascript?Ideal features:entry function name, or some meaningful identifier for anonymous functions,argument list at each level,line numbers.Can this be done in standard...
View ArticleCan I enter password once for multiple mysql command line invocations, where...
You can avoid re-entering mysql command line password by putting the queries into a file.In my case, the later queries are not determined until after the first queries have finished.This happens in a...
View ArticleComment by spraff on How to render svg to pdf at a given physical...
I'm really looking for a command like svg_to_pdf -i foo.svg -o foo.pdf --width=15cm --height=15cm --margin-left=2cm --margin-top=2cm and note that the particular svg in the question is just an example
View ArticleComment by spraff on Why is text not showing along this svg textPath?
The intent is for the renderer to select a size suitable for making the text fit into whatever path I give it without me giving the font size explicitly. Is this possible?
View ArticleWhat svg filters could make this noise look more like water?
I am experimenting with svg to generate an impression of water waves.Here's my initial attempt:<filter id='water' x='0%' y='0%' width='100%' height='100%'><feTurbulence baseFrequency="0.01...
View ArticleWhy is this svg filter producing content outside of the polygon which uses it?
This svg<?xml version="1.0" encoding="UTF-8"?><svg xmlns="http://www.w3.org/2000/svg" viewBox="-1 -1 2 2" width="100" height="100"><filter id='water' x='0%' y='0%' width='100%'...
View ArticleWhy is text not showing along this svg textPath?
Similarly to this I am trying to render svg text such that it fits into a given space (auto sized, I do not give font size explicitly).Here is my test image<?xml version="1.0"...
View ArticleWhy is the image in my svg pattern not tiling?
Here's my test svg<?xml version="1.0" encoding="UTF-8"?><svg version="1.1" viewBox="-1 -1 2 2" width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="img1"...
View Article