# commands.log: linkedin-post-character-limit, December 1, 2026 (server: Ubuntu 24.04.5 LTS, Python 3.12.3, Node v24.21.0) # Each published command as run, its exit code and the edge inputs it was also tried on. Scripts and test files sit next to this file. published: python3 linkedin-post-check.py my-post.txt (reader command; my-post.txt here is a copy of the plain test draft) ran: python3 linkedin-post-check.py my-post.txt exit=0 | characters: 409 UTF-16 units (Word counter), 409 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 2591 left of 3000 edge: an empty file ran: python3 linkedin-post-check.py empty.txt exit=2 | error: empty.txt has no text edge: a file of blank lines and spaces ran: python3 linkedin-post-check.py blank.txt exit=2 | error: blank.txt has no text edge: a missing file ran: python3 linkedin-post-check.py missing.txt exit=2 | error: cannot open missing.txt: No such file or directory edge: a file saved as Latin-1, not UTF-8 ran: python3 linkedin-post-check.py latin1.txt exit=2 | error: latin1.txt is not UTF-8 (byte 3); save it as UTF-8 and run again edge: the letter a 3,000 times plus one final line break (ignored, as an editor adds it on save: fits, 0 left) ran: python3 linkedin-post-check.py trail1.txt exit=0 | characters: 3000 UTF-16 units (Word counter), 3000 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 0 left of 3000 edge: the letter a 3,000 times plus two final line breaks (the second counts: over by 1) ran: python3 linkedin-post-check.py trail2.txt exit=1 | characters: 3001 UTF-16 units (Word counter), 3001 Python len() | line breaks: 1 (1 character each) | RESULT: over by 1 (limit 3000) published: python3 linkedin-post-check.py draft-near-limit.txt (our test run, output printed on the page) ran: python3 linkedin-post-check.py draft-near-limit.txt exit=1 | characters: 3009 UTF-16 units (Word counter), 2979 Python len() | line breaks: 4 (1 character each) | counted as 2 by the Word counter: 🚀 U+1F680 | RESULT: over by 9 (limit 3000) edge: control, the letter a 3,000 times (known answer: fits, 0 left) ran: python3 linkedin-post-check.py draft-control-3000.txt exit=0 | characters: 3000 UTF-16 units (Word counter), 3000 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 0 left of 3000 edge: control, the letter a 3,001 times (known answer: over by 1) ran: python3 linkedin-post-check.py draft-control-3001.txt exit=1 | characters: 3001 UTF-16 units (Word counter), 3001 Python len() | line breaks: 0 (1 character each) | RESULT: over by 1 (limit 3000) edge: the list post with blank lines (LF) ran: python3 linkedin-post-check.py draft-line-breaks.txt exit=0 | characters: 311 UTF-16 units (Word counter), 311 Python len() | line breaks: 12 (1 character each) | RESULT: fits, 2689 left of 3000 edge: the same list post saved with Windows CRLF line breaks; counted as LF, as a browser text box does ran: python3 linkedin-post-check.py draft-crlf.txt exit=0 | characters: 311 UTF-16 units (Word counter), 311 Python len() | line breaks: 12 (1 character each) | RESULT: fits, 2689 left of 3000 edge: emoji bullets (check mark 1 unit, pointing hand and rocket 2) ran: python3 linkedin-post-check.py draft-emoji-bullets.txt exit=0 | characters: 119 UTF-16 units (Word counter), 117 Python len() | line breaks: 4 (1 character each) | counted as 2 by the Word counter: 👉 U+1F449 🚀 U+1F680 | RESULT: fits, 2881 left of 3000 edge: skin-tone wave, a flag and a joined (ZWJ) emoji ran: python3 linkedin-post-check.py draft-skin-flag-zwj.txt exit=0 | characters: 87 UTF-16 units (Word counter), 81 Python len() | line breaks: 2 (1 character each) | counted as 2 by the Word counter: 🇦 U+1F1E6 🇨 U+1F1E8 🏽 U+1F3FD 👋 U+1F44B 👩 U+1F469 💻 U+1F4BB | RESULT: fits, 2913 left of 3000 edge: Unicode bold letters in the hook ran: python3 linkedin-post-check.py draft-bold-unicode.txt exit=0 | characters: 148 UTF-16 units (Word counter), 114 Python len() | line breaks: 2 (1 character each) | counted as 2 by the Word counter: 𝗙 U+1D5D9 𝗮 U+1D5EE 𝗯 U+1D5EF 𝗱 U+1D5F1 𝗲 U+1D5F2 𝗳 U+1D5F3 𝗶 U+1D5F6 𝗹 U+1D5F9 and 10 more | RESULT: fits, 2852 left of 3000 edge: a long link with tracking parameters ran: python3 linkedin-post-check.py draft-long-url.txt exit=0 | characters: 169 UTF-16 units (Word counter), 169 Python len() | line breaks: 0 (1 character each) | link: 120 characters: https://example.com/workshops/usability-testing-december?utm... | RESULT: fits, 2831 left of 3000 edge: output to a console or file that is not UTF-8 (cp1252, as on Windows); the emoji prints as ? ran: PYTHONIOENCODING=cp1252 python3 linkedin-post-check.py draft-near-limit.txt > out.txt exit=1 | characters: 3009 UTF-16 units (Word counter), 2979 Python len() | line breaks: 4 (1 character each) | counted as 2 by the Word counter: ? U+1F680 | RESULT: over by 9 (limit 3000) published: python3 linkedin-post-check.py my-comment.txt --limit 1250 (reader command; my-comment.txt here is a copy of the comment test draft) ran: python3 linkedin-post-check.py my-comment.txt --limit 1250 exit=0 | characters: 1115 UTF-16 units (Word counter), 1115 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 135 left of 1250 edge: the comment test draft itself, --limit 1250 ran: python3 linkedin-post-check.py draft-comment.txt --limit 1250 exit=0 | characters: 1115 UTF-16 units (Word counter), 1115 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 135 left of 1250 edge: --limit=1250 written with an equals sign (same as --limit 1250) ran: python3 linkedin-post-check.py draft-comment.txt --limit=1250 exit=0 | characters: 1115 UTF-16 units (Word counter), 1115 Python len() | line breaks: 0 (1 character each) | RESULT: fits, 135 left of 1250 edge: --limit with no number ran: python3 linkedin-post-check.py draft-comment.txt --limit exit=2 | error: --limit needs a whole number above 0, for example --limit 1250 edge: --limit 0 (rejected, a limit must be above 0) ran: python3 linkedin-post-check.py draft-comment.txt --limit 0 exit=2 | error: --limit needs a whole number above 0, for example --limit 1250 edge: --limit -5 (rejected) ran: python3 linkedin-post-check.py draft-comment.txt --limit -5 exit=2 | error: --limit needs a whole number above 0, for example --limit 1250