Skip Navigation
The best use of QR codes
  • Consider florida, where if you are caught with shrooms that are wet, freshly picked, they cannot convict you for carrying contraband because you do not necessarily know what you picked.

    Laws are often based on intent. In some cases, penalties vary depending on intent. It would be an unacceptably brutally harsh law to judge someone under a presumption of harmful intent for something they might have no awareness of.

    QR codes can have icons on them. Certainly if I created such a t-shirt, I would put some cool looking icon in the center of it. Someone being dragged through the system might argue “i did not know that qr code was real.. i just liked the cat in the middle of it”.

  • Rock star died before I could publish his latest work in a liberated way due to CreativeCommons dependency on Cloudflare
  • It depends on which license you look at. E.g. from https://creativecommons.org/licenses/by-sa/4.0/legalcode.txt:

    c. BY-SA Compatible License means a license listed at creativecommons.org/compatiblelicenses, approved by Creative Commons as essentially the equivalent of this Public License.

    It was a while since I looked at this but IIRC the BY license was fine in its early versions but none of the others were. Then I vaguely recall seeing links in later versions of the BY license as well (but that may have been hasty reading on my part since i'm not seeing it in the BY 4.0 ATM). Anyway, it’s a mess.

  • Rock star died before I could publish his latest work in a liberated way due to CreativeCommons dependency on Cloudflare
  • That doesn’t really work. The URL is an inherent part of the CC license. Archive.org might do link replacement but that does not change the license.. it merely corrupts/misrepresents the license. Users of CC-licensed work are still bound by the actual text of the license. IIRC the URL was to refer to something that changes over time, thus making the license dynamic when archive.org works off of snapshots.

  • Rock star died before I could publish his latest work in a liberated way due to CreativeCommons dependency on Cloudflare
  • I vaguely recall Richard Stallman bad-mouthing public domain in favor of free licensing. I don’t recall the details but I imagine the artist would at least want attribution, which I doubt the public domain ensures.

    Of course if we could have predicted his death there are many trivial ways we could have ensured his will is expressed and executed. But it may not be a lost cause.. whoever controls the estate would likely know or believe that he wanted to liberate his work.

  • US Law (local/state/federal) @lemmy.sdf.org LibreMonk @linkage.ds8.zone
    Rock star died before I could publish his latest work in a liberated way due to CreativeCommons dependency on Cloudflare

    A rock star (who shall remain unnamed) told me he wanted to give away his latest work to the public domain. I helped him get the work in open non-proprietary formats.

    I told him in principle that Creative Commons licensing would be what he is after, but that it has problems. Creative Commons license text contains links to the creative commons website which then hooks in more licensing terms. There is nothing wrong with the terms but the CC website is jailed in Cloudflare’s walled garden and the URL is part of the licensing text.

    I told the artist he would be liberating his work but at the same time he would be technically subjecting users to a bullying US tech giant who makes content arbitrarily exclusive by shutting out some demographics of people and also abusing the privacy of those who are privileged to obtain access to the license text.

    I suggested modifying the CC license to remove the CC URL and exclude Cloudflare from being a license gatekeeper, noting of course the big pitfall: if the work is not exactly CC, then it cannot use the CC name, thus the work cannot simply be treated as such by platforms which depend on the easy cookie-cutter CC license. The work cannot simply be copied to a platform that is designed for CC works.

    But by rebelling he could perhaps make a splash by casting a spotlight on suppression by Cloudflare. The burden/encumberance of his unique license would trigger a discussion that might get Creative Commons to gain some wisdom and nix the hypocrisy of Cloudflare-dependent licensing.

    The artist is a rebel at heart and so he agreed. But I did not act fast. Then he died unexpectedly. All of our discussions were verbal, so his will in this regard is undocumented and thus non-existent from a legal standpoint. I think this means the naturally copyrighted work in question is forever all rights reserved and cannot be liberated, correct?

    Or is it a matter of tracking down who in his will inherits the rights to the works in his estate and seeing if they concur with a liberated release?

    7
    (pdfpages) How to write code that only affects some select pages of a PDF document
  • One annoying limitation is that the last page and a penultimate page cannot have different behavior in the picturecommand option. I thought I was fucked for ½ a day. But hacked around that by using the pagecommand and nesting \ifthenelse{\AM@page = (penultimate page №)}{\begin{picture}(0,0)\put(50,-50){…}… inside the pagecommand. Makes me wonder what’s the point of having the picturecommand. There is a picturecommand* which only executes on the 1st page, and apparently no equivalent for pagecommand -- but we can test the internal variable anyway.

  • (pdfpages) How to write code that only affects some select pages of a PDF document

    Suppose you feed a multi-page PDF into \includepdf. If you only want pagecommand or picturecommand to take effect on some pages, you normally must split the construct up into multiple invocations. E.g. \includepdf[pages=1], pagecommand={\doStuffOnPageOne}]{file.pdf} \includepdf[pages=2-], pagecommand={\doStuffOnPagesAfterOne}]{file.pdf} It gets ugly fast when there are some commands you want performed on every page, and some on select pages, because then you must write and maintain redundant code.

    Fuck that. So here’s a demonstration of how to write code inside pagecommand and picturecommand that is page-specific: ``` \documentclass{article}

    % Demonstrates use of the pdfpages package with page-by-page actions that are specific to select pages.

    \usepackage{mwe} % furnishes example-image-a4-numbered.pdf \usepackage{pdfpages} \usepackage{pdfcomment} \usepackage{ocgx2} % furnishes the ocg environment (PDF layers, but not really needed for this demo) \usepackage{fancybox} % furnishes oval box \usepackage{fontawesome} % furnishes \faWarning

    \begin{document}

    \makeatletter \includepdf[pages=1-,pagecommand={% % \makeatletter ← ⚠ does not work in this scope; must wrap the whole includepdf construct \pdfcomment[icon=Note, hoffset=0.5\textwidth, voffset=5em]{% (inside pagecommand, executing on every page)\textLF\textLF \texttt{\textbackslash AM@page} variable: \AM@page\textLF\textLF Side-note: the voffset option has no effect when the value is positive (5em in this case)% }% \ifthenelse{\AM@page = 1 \OR \AM@page = 2 \OR \AM@page = 12}{% \pdfcomment[icon=Insert, hoffset=0.5\textwidth, voffset=-6em]{% (inside pagecommand, affecting only pages 1, 2, and 12)\textLF\textLF \texttt{\textbackslash AM@page} variable: \AM@page\textLF\textLF Strangely, the voffset option only works if it is negative.% }% }{} % \makeatother }, picturecommand={% \put(50,715){Inside the picture environment:} \put(50,700){% \begin{tabular}[t]{llp{0.6\textwidth}} internal \texttt{\textbackslash @tempcnta} variable (useless): &\the\@tempcnta&\\ internal \texttt{\textbackslash @tempcntb} variable (useless): &\the\@tempcntb&\\ internal \texttt{\textbackslash AM@pagecnt} variable (useless): &\the\AM@pagecnt&\\ internal \texttt{\textbackslash AM@abs@page} variable (useless): &\AM@abs@page&\\ internal \texttt{\textbackslash AM@page} variable (interesting): &\AM@page & \faWarning Inside picturecommand, this number is 1 higher than the actual page number! But it’s correct inside pagecommand (see the annotation note to check).\\ internal \texttt{\textbackslash AM@pagecount} variable (interesting): &\AM@pagecount&\\% \end{tabular} % lastpage: \AM@lastpage% broken \ifAM@firstpage We might expect this to trigger on the 1st page, but it never does. Likely because the page counter is incremented before picturecommand is invoked. It would perhaps work in the pagecommand construct. \fi } \put(500,770){% The ocg environment is irrelevant and unnecessary.. just here to demo PDF layers. \begin{ocg}{section labels}{sl1}{on}\color{blue} \Large\rotatebox{-45}{\setlength{\fboxsep}{6pt}\Ovalbox{Section~A}} \end{ocg}}}]% {example-image-a4-numbered.pdf} \makeatother \end{document} ```

    1
    Paperless office; document/image processing @sopuli.xyz LibreMonk @linkage.ds8.zone
    Expats: when you receive documents that are not in your language, how do you handle them? (PDF vs DjVu, Tesseract, Argos, etc)

    When I receive a non-English document, I scan it and run OCR (Tesseract). Then use pdftotext to dump the text to a text file and run Argos Translate (a locally installed translation app). That gives me the text in English without a cloud dependency. What next?

    Up until now, I save the file as (original basename)_en.txt. Then when I want to read the doc in the future I open that text file in emacs. But that’s not enough. I still want to see the original letter, so I open the PDF (or DjVu) file anyway.

    That workflow is a bit cumbersome. So another option: use pdfjam --no-tidy to import the PDF into the skeleton of LaTeX code, then modify the LaTeX to add a \pdfcomment which then puts the English text in an annotation. Then the PDF merely needs to be opened and mousing over the annotation icon shows the English. This is labor intensive up front but it can be scripted.

    Works great until pdf2djvu runs on it. Both evince and djview render the document with annotation icons showing, but there is no way to open the annotation to read the text.

    Okular supports adding new annotations to DjVu files, but Okular is also apparently incapable of opening the text associated to pre-existing annotations. This command seems to prove the annotation icons are fake props: djvused annotatedpdf.djvu -e 'select 1; print-ant' No output.

    When Okular creates a new annotation, it is not part of the DjVu file (according to a comment 10 years ago). WTF? #DjVu’s man page says the format includes “annotation chunks”, so why would Okular not use that construct?

    It’s theoretically possible to add an annotation to a DjVu file using this command: djvused -e set-ant annotation-file.txt book.djvu But the format of the annotations input file is undocumented. Anyone have the secret recipe?

    0
    Is it possible to read a boolean value from a parent pkg? (answer: yes)

    It would sometimes be useful to write conditional code that depends on boolean values defined in a parent package. E.g. the \pdfcomment package has the boolean “final”, which disables all PDF annotations in the document (\usepackage[final]{pdfcomment}). There is some other logic in my document that should also be disabled when that boolean is true. I tried simply using:

    \ifpc@gopt@final\else% …code that should not run when final is true… \fi pdflatex gives: “Undefined control sequence”

    More generally, many draft options are often useful for controlling logic within the document for which a parent uses a draft option. Also when defining a custom letterhead in the scrlttr2 class there are booleans for many items that may or may not be wanted in the letterhead.

    Has anyone managed to read a parent boolean?

    (update) This thread gives useful options for many situations. But it does not completely answer the question because there are non-draft related booleans.

    SOLVED

    The \ifpc@gopt@final is reachable but only inside a \makeatletter stanza. Thus: \makeatletter \ifpc@gopt@final\else% …code that should not run when final is true… \fi \makeatother

    0
    making a PDF annotation/comment from text file input (but code is ugly as fuck)
  • Someone tells me “look into \scantokens instead of rewriting to a file”. After a brief look, I have to say: No. Fucking. Way. That looks like a rabbit hole that leads to the center of the planet. No thanks.. I don’t need to spend weeks more on this digging through (what looks like) the most raw low-level code that makes assembly languages look like tinker toys.

    Low level TeX code really seems like a strange beast. Something you should learn in your early teens while the brain is still highly plastic. I wish I learnt it because I would better understand all the bizarre and obscure glitches I run into with LaTeX. But I think I might be past the point where benefit outweighs the pain.

  • making a PDF annotation/comment from text file input (but code is ugly as fuck)

    Some might find it useful to import a text file and put the contents into a PDF annotation. E.g. a PDF is in language A and you want to make a translation available in language B, in a PDF annotation.

    Here’s how:

    ``` \documentclass{article}

    \usepackage{mwe} \usepackage{pdfpages} \usepackage{pdfcomment} \usepackage{newfile} \usepackage{xstring} \usepackage{catchfile}

    % heredoc holding text that normally breaks the \pdfcomment command: \begin{filecontents*}{\jobname_sample.txt} line one

    line two tricky symbols: _&% \end{filecontents*}

    % normally the above file is whatever you supply to be imported into the PDF annotation. The heredoc is just to provide a self-contained sample.

    % Create \pdfcommentfile, which is a version of \pdfcomment that can read from a file: \makeatletter \gdef\pdfcommentfile#1{% \begingroup \everyeof{\noexpand}% \long\edef\temp{\noexpand\pdfcomment{\@@input{#1}}}% \temp \endgroup }% \makeatother

    \CatchFileDef{\cfile}{\jobname_sample.txt}{} % side-effects: replaces blank lines with “\par” and drops percent symbols

    % Replace blank lines with \textLF and replace special symbols with those that are safe for \pdfcomment. Warning: this is probably not a complete list of all constructs that break \pdfcomment! \StrSubstitute{\cfile}{\par}{\string\noexpand\string\textLF\ }[\pdfannotationtxt] % the hard space is after textLF is a bit unfortunate; not sure how to do a normal space there \StrSubstitute{\pdfannotationtxt}{\%}{\string\noexpand\string\%}[\pdfannotationtxt] \StrSubstitute{\pdfannotationtxt}{}{\string\noexpand\string\}[\pdfannotationtxt] \StrSubstitute{\pdfannotationtxt}{&}{\string\noexpand\string\&}[\pdfannotationtxt]

    % the \pdfcomment command cannot directly handle the above substitutions (nor can it handle the original unsubstituted version). So we write the new version to another file:

    \newoutputstream{filteredresult} \openoutputfile{\jobname_filtered.txt}{filteredresult} \addtostream{filteredresult}{\pdfannotationtxt} \closeoutputstream{filteredresult}

    \begin{document} \pdfcommentfile{\jobname_filtered.txt} \includepdf{example-image-a.pdf} \end{document} ``` There should be a way to substitute the special characters and blank lines then feed it directly to \pdfcomment, but I’ve exhausted that effort. I’ve been in this LaTeX rabbit hole for days now trying to do something that should be simple. So this is as far as I go. The code above works but it’s ugly as fuck that we have to write the filtered text to file then read the file back in. The file i/o slows down compilation much more than what I consider reasonable.

    1
    bizarre output by \StrSubstitute when replacing &, %, _, and \newline

    cross-posted from: https://linkage.ds8.zone/post/363360

    > I am trying to do some simple character replacements on an input file and writing it to a file. The output produced by \StrSubstitute is quite bizarre. Here is a MWE: > > \documentclass{article} > > \usepackage{newfile} % furnishes \newoutputstream > \usepackage{catchfile} % furnishes \CatchFileDef > \usepackage{xstring} % furnishes \StrSubstitute > \usepackage{stringstrings}% furnishes \convertword (a \StrSubstitute alternative) > > % heredoc that creates source input file > \begin{filecontents*}{\jobname_sample.txt} > line one > > line two > tricky symbols: _&% > \end{filecontents*} > > \CatchFileDef{\cfile}{\jobname_sample.txt}{} > > \begin{document} > > % Replacements needed: > % & → \& > % % → \% > % _ → \_ > % \newline\newline → \textLF (replace blank lines) > % > \StrSubstitute{\cfile}{&}{\&}[\mystring] > \StrSubstitute{\mystring}{\%}{\%}[\mystring] > \StrSubstitute{\mystring}{_}{\_}[\mystring] > \StrSubstitute{\mystring}{\newline\newline}{\\textLF}[\mystring] > > \newwrite\myoutput > \immediate\openout\myoutput=\jobname_filtered_native.txt > \immediate\write\myoutput{\mystring} > \immediate\closeout\myoutput > > \newoutputstream{filtered} > \openoutputfile{\jobname_filtered_newfile.txt}{filtered} > \addtostream{filtered}{\mystring} > \closeoutputstream{filtered} > > \noindent\textbf{filtered catchfile}:\\ > \mystring > > \noindent\textbf{filtered catchfile (2nd attempt)}:\\ > \convertword{\mystring}{\newline\newline}{\noexpand\textLF} > > \end{document} > > That uses two different techniques to write to a file, and both give slightly different yet wildly unexpected output: > > $ cat sample_code_filtered_native.txt > line one \par line two tricky symbols: \protect \global \let \OT1\textunderscore \unhbox \voidb@x \kern .06em\vbox {\hrule width.3em}\OT1\textunderscore \& > $ cat sample_code_filtered_newfile.txt > line one \par line two tricky symbols: \global\let \OT1\textunderscore \unhbox \voidb@x \kern .06em\vbox {\hrule width.3em}\OT1\textunderscore \& > > What triggered all that garbage to be created? This is what the output [b]should[/b] be: > > > line one\textLF > > line two > > tricky symbols: \_\&\% > > I also tried a 3rd way to write \mystring to a file, as follows: > > \begin{filecontents*}{\jobname_myvar.txt} > \mystring > \end{filecontents*} > > That approach literally writes the string “\mystring” to a file, which is useless in this case. > > (update) apparently a \string needs to prefix the substituted strings.

    0
    It's 2024 and I'm posting this from a text console.
  • For the same reason, I suppose you would love text adventure games like Hitchhiker’s Guide to the Galaxy, where you have to come up with your action, as opposed to getting visual aids which come like a loaded question, steering you and somewhat robbing you of control.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • There was a story about a German guy insisting on paying his radio licensing fees in cash. He setup an escrow account and paid his invoices into that, so that the state could not claim he was just using cash refusal as an excuse not to pay. I don’t think I ever heard what came of the legal case.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • I heard postbank was eliminated in Germany but post office banking is still an option in other countries. I doubt any post office banks stand on their own. The one I’m aware of is just a proxy for another crappy bank.

    Many elderly people can’t use a smartphone so smartphone only options definitely sound like a no go.

    It’s somewhat convenient that tech illiterates are in the same boat with the streetwise (who are tech saavy enough to distrust commercial tech that’s being pushed down our throats). But there are efforts to divide us. Elderly folks are getting social helpers with tech, which will shrink those resisting enshitification of everything to a population that’s easier to marginalise. I also don’t suppose it will be long before the tech illiterate elderly are no longer with us anyway.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • at least in Germany companies and state are not anymore required to accept cash for invoices

    Yikes. That’s a shame. There is the EC Recommendation of 22 March 2010 (2010/191/EU) which wisely states:

    A debtor can discharge himself from a payment obligation by tendering euro banknotes and coins to the creditor.

    I am surprised Germany has gone against that. I thought cash was loved by Germans.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • Glad to hear you’re standing up for yourself, and others. And glad to hear an analog option is still possible. That’s by far the most important option. If you can do everything offline, then you can escape whatever garbage tech they try to push. Essential services like banking and utilities should always have an offline analog option.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • you should probably just keep the money in cash

    Of course. Cash would solve the problem. But creditors are refusing that now and also refusing cards at the same time. Otherwise the bank card could get cash out of the ATM and pay the creditors.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • No, not anymore. They became app exclusive. Customers must become an Apple or Google patron, or just use the bank card. They also closed their shop doors and terminated their phone number. If you call them on their unpublished phone number, they insist: “email us” and they refuse to give any service over the phone. And their email goes through gmail (and no PGP key given). Paper letters are ignored. They also refuse manual transfers. The app is the sole means for transfers.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?
  • The EU has that covered as REGULATION (EU) No 260/2012 imposes 2FA.

    But for me personally, I do not trust closed-source apps from surveillance advertisers running on a Google or Apple proprietary platform, no matter how well they do the 2FA. Even if the endpoint were impenetrable, I do not trust the bank itself not to snoop -- in part because I do not trust the GDPR, which is scantly enforced and regularly disregarded to a laughable extent. And from the ecocide PoV, I refuse to throw away good hardware and support designed obsolescence. They can pry my old phone from my cold dead hands.

  • When an EU-based bank forces you to buy a recent smartphone to access your account, what are your rights?

    Suppose you resist a bank that forces you to access your account exclusively via some shitty phone app, which also requires you to buy a new smartphone. And suppose you refuse, so your only access to the bank account is via the card.

    What happens when the time comes that (e.g.) the gov or a creditor demands a payment by credit transfer, not by card? Are you consequently forced by your obligation to make a payment to then buy a phone? Or do you have a right to manually order a payment from your bank by sending a written letter or something?

    There is this law but I’m not sure it’s applicable:

    > REGULATION (EU) No 260/2012, Art.4: Interoperability > … > 3. The processing of credit transfers and direct debits shall not be hindered by technical obstacles.

    I think that law was really intended for the bank-to-bank segment of the transaction, not consumer to bank. I get the impression we have no codefied rights, just recommendations to lawmakers, such as:

    > The European Commission, in its 2012 Green Paper, insisted that standardisation in the mobile payments area should ensure full interoperability between mobile payment solutions, and favour open standards to ensure the mobility of consumers when they wish to change their telecom operator or bank. > … > In its Mobile Payments Initiatives Overview, the European Payments Council stated that different mobile payment solutions from multiple payment service providers should be able to coexist in the same mobile device. In its opinion, consumers should not be bound to a specific network operator or particular mobile equipment, but should be able to switch between payment service providers, with interoperability as a key feature needed to achieve these goals.

    But to be fair that was written 10 years ago. Any headway?

    16
    (OSMand)⚠ downloadable map list empty!
  • Thanks for the feedback. A couple other people also say they have no problem.

    I am trapped on a 3-year old version. I could upgrade from 4.0.7 to 4.0.9, but that’s as far as I can go because 4.1.9 abandons anyone running AOS older than 6.0. So I wonder if they recently changed the map server in a way that breaks old versions.

    I am also on Tor. But also tried a VPN. I doubt they would block Tor and VPNs and then also introduce blocks on both at the same time. Thought I should mention it in the remote off chance that it matters.

  • (OSMand)⚠ downloadable map list empty!

    I somewhat urgently need a map, but for the past day or two there are no maps in #OSMand available for download. Can anyone confirm or deny this problem?

    Is this related to the OSM outtage 6 days ago, which was supposedly resolved?

    (edit) workaround -- download maps manually and side-load them. The maps are here:

    https://osmand.net/list.php

    Next question: how do you know which files cover a particular city if it’s not obvious from the filename?

    2
    Suppose you agree to a contract that binds you to relying on other people doing something?
  • you can’t just scream legal tender and throw physical money at your creditor¹.

    IIRC in the US it’s written simply that if you leave legal tender in the creditor’s possession, your debt is reduced by that amount regardless of what they do with it. But of course gathering evidence in that case can be dicey.

    If I remember rightly you need to lodge it with the courts and then it basically prevents you from being sued as the money is there to pick up.

    There was a guy in Germany who fought the forced use of electronic payment for radio licensing fees that way. He escrowed it in a blocked account so that the gov could not claim he was just looking to evade the fees. It seems like a good approach.

  • Suppose you agree to a contract that binds you to relying on other people doing something?

    cross-posted from: https://linkage.ds8.zone/post/341870

    > I signed an agreement with a creditor that obligates me to pay them using a bank inside the country. This was fine initially but then I moved out of the country and the acct was closed. Other banks will not open an account for me and the creditor refuses cash. So the creditor is treating me like a non-payer to a quite harsh extent. > > I have over-simplified here but I just want to know very generally what the common practices are around the world for contract law situations where someone without much bargaining power signs a contract that obligates them to do something that’s only achievable if other 3rd-parties agree to serve them, and then those other 3rd-parties later refuse. > > BTW, I am not interested in advice on situational hacks and angles like “find a friend to pay for you”. I want to know how courts treat the situation when all options have failed. Are people typically held accountable for agreeing to something which relied on actions of others?

    (the situation is not in the Netherlands but I am still interested in answers as to how these kinds of situations are dealt with in the Netherlands)

    /cc @law@a.gup.pe

    1
    Suppose you agree to a contract that binds you to relying on other people doing something?

    cross-posted from: https://linkage.ds8.zone/post/341870

    > I signed an agreement with a creditor that obligates me to pay them using a bank inside the country. This was fine initially but then I moved out of the country and the acct was closed. Other banks will not open an account for me and the creditor refuses cash. So the creditor is treating me like a non-payer to a quite harsh extent. > > I have over-simplified here but I just want to know very generally what the common practices are around the world for contract law situations where someone without much bargaining power signs a contract that obligates them to do something that’s only achievable if other 3rd-parties agree to serve them, and then those other 3rd-parties later refuse. > > BTW, I am not interested in advice on situational hacks and angles like “find a friend to pay for you”. I want to know how courts treat the situation when all options have failed. Are people typically held accountable for agreeing to something which relied on actions of others?

    (the situation is not in the UK but I am still interested in answers as to how these kinds of situations are dealt with in the UK)

    11
    US Law (local/state/federal) @lemmy.sdf.org LibreMonk @linkage.ds8.zone
    Suppose you agree to a contract that binds you to relying on other people doing something?

    cross-posted from: https://linkage.ds8.zone/post/341870

    > I signed an agreement with a creditor that obligates me to pay them using a bank inside the country. This was fine initially but then I moved out of the country and the acct was closed. Other banks will not open an account for me and the creditor refuses cash. So the creditor is treating me like a non-payer to a quite harsh extent. > > I have over-simplified here but I just want to know very generally what the common practices are around the world for contract law situations where someone without much bargaining power signs a contract that obligates them to do something that’s only achievable if other 3rd-parties agree to serve them, and then those other 3rd-parties later refuse. > > BTW, I am not interested in advice on situational hacks and angles like “find a friend to pay for you”. I want to know how courts treat the situation when all options have failed. Are people typically held accountable for agreeing to something which relied on actions of others?

    (the situation is not in the US but I am still interested in answers as to how these kinds of situations are dealt with in the US; of course legal tender is a right the US gives to debtors, but I’m looking for more general legal concepts)

    0
    Suppose you agree to a contract that binds you to relying on other people doing something?

    I signed an agreement with a creditor that obligates me to pay them using a bank inside the country. This was fine initially but then I moved out of the country and the acct was closed. Other banks will not open an account for me and the creditor refuses cash. So the creditor is treating me like a non-payer to a quite harsh extent.

    I have over-simplified here but I just want to know very generally what the common practices are around the world for contract law situations where someone without much bargaining power signs a contract that obligates them to do something that’s only achievable if other 3rd-parties agree to serve them, and then those other 3rd-parties later refuse.

    BTW, I am not interested in advice on situational hacks and angles like “find a friend to pay for you”. I want to know how courts treat the situation when all options have failed. Are people typically held accountable for agreeing to something which relied on actions of others?

    0
    Generating reference numbers in bash or sqlite that do not appear sequential (like shuffling a deck of cards)

    TL;DR → The main problem is coming up with a way to reorder an array non-randomly but without introducing bulky code. Like the effect of shuffling a deck of cards in a deterministic cheating way.

    --- Full background:

    I would like to generate reference numbers for letters sent via postal mail. An sqlite db is used to track the sequence numbers (but not the reference numbers). This is the bash code I have so far:

    typeset -a symbolset=(a b c d e f g h j k m n p q r s t u v w x y z 2 3 4 5 6 7 8 9) ln_symbolset=${#symbolset[@]}; # 41 is the answer, not 42 itemseq=$(sqlite3 ltr_tracking.db "select max(counter) from $tbl;") printf '%s\n' "next letter reference number is: $(date +%Y)-${symbolset[$((itemseq / ln_symbolset))]}${symbolset[$((itemseq % ln_symbolset))]}"

    An array is defined with alphanumeric symbols, taking care to eliminate symbols that humans struggle to distinguish (e.g. 1l0o). Then integer div and mod operations produce a two character number which is then prefixed with the year. So e.g. 2024-aa. Just two chars gives more numbers than would ever be generated in one calandar year.

    This code mostly satisfies the need. But there’s a problem: a recipient who receives two letters can easily realise how many letters were sent in the time span of the two letters they receive. Most numbers will start with “a” “b” or “c”.

    I do not need or want a cryptographic level of security which then leads to ungodly 16 byte numbers. Simplicity¹ is far more important than confidentiality. Just a small tweak to stifle the most trivial analysis would be useful.

    One temptation is to simply manually mix up the order of chars in the symbolset array, hard-coded. But then that makes the code less readible. So I probably need to create a 2nd array “symbolseq” which arbitrarily unorders the symbolset array. I say arbitrary and not random because the sequence must be deterministic and static from one execution to the next.

    An associative array is one idea:

    typeset -A symbolset_lookup_table=( [a]=k [b]=3 [c]=s …

    I’m just slightly put off by the fact that it’s not readily evident that the RHS values are all used from the same set as the LHS keys exactly once.

    I should probably encode the year as well. This would give a two char year:

    printf '%s ' "$(((2024/41) % 41))" "$((2024 % 41))" "→ ${symbolset[$(((2024 / 41) % 41))]}" "${symbolset[$((2024 % 41))]}" output: 8 15 → j s

    (edit) All the calculations must be easily reversible so a ref number can be converted back into a sequence number for DB queries.

    ¹ simplicity in both the code and in the numbers generated.

    0
    the JavaScript problem: a conflict of interest

    I was thinking about the problem with JavaScript and the misery it brings to people. I think I’ve pinned it down to a conflict of interest.

    Software is supposed to serve the user who runs it. That’s the expectation, and rightfully so. It’s not supposed to serve anyone else. Free software is true to this principle, loosely under the FSF “freedom 0” principle.

    Non-free software is problematic because the user cannot see the code. The code only has to pretend to serve the user while in reality it serves the real master (the corporation who profits from it).

    JavaScript has a similar conflict of interest. It’s distributed by the same entity who operates API services -- a stakeholder. Regardless of whether the JS is free software or not, there is an inherent conflict of interest whereby the JS is produced by a non-user party to the digital transactions. This means the software is not working for the user. It’s only pretending to.

    4
    ☠ lemmy.sdfeu.org ~~has died~~ is back up, but communities gone

    I just started using the LaTeX community (!tex@lemmy.sdfeu.org). Sad to see it go.

    update --- Just noticed it’s back up, but there are no communities. That’s bizarre. So if someone not on lemmy.sdfeu.org were to post to !tex@lemmy.sdfeu.org, I guess it’d still be like a ghost node because the post would have nowhere to go on the hosting node.

    5
    InitialsDiceBearhttps://github.com/dicebear/dicebearhttps://creativecommons.org/publicdomain/zero/1.0/„Initials” (https://github.com/dicebear/dicebear) by „DiceBear”, licensed under „CC0 1.0” (https://creativecommons.org/publicdomain/zero/1.0/)LI
    LibreMonk @linkage.ds8.zone
    Posts 15
    Comments 27