-
Notifications
You must be signed in to change notification settings - Fork 2
/
TODO.txt
266 lines (266 loc) · 19.2 KB
/
TODO.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
cs.distinfo: insert script metadata
default: cs.cmdutils: usage_format_parts: return (usage,full_desc), provide usage_desc_split to get line1 and trailing lines, provide usage_format_desc for full desc, use in the tabulated listing
√ cs.cmdutils: help -r but no -l - single tabulate call from the top level if subcommands?
cs.djutils: return 1 from a cmd_ method seems to be ignored?
pfx: each Pfx to include its sep for joining things up
default: drop cs.lex.indent, stdlib textwrap.indent does a better job
√ default: make an @popopts usable as a cmd method decorator
uses_cmd_options: append to the function docstring?
@promote: params to also accept a mapping of param_name to promotion_func
default: media info: support "http://www.omdbapi.com/?apikey={OMDB_API_KEY}&type=movie&s=&genre={genre}&y={year}" ?
√ cs.cmdutils: support opt=-field' for an inverted boolean option
√ cs.cmdutils: usage_text: in short mode list just subcmd and the usage 1-liner tabulated d
cs.cmdutils: generate zsh and bash autocompletion rules
cs.cmdutils: getopt from a called subcommand should only produce the usage for the subcommand
cs.cmdutils: solidify the thread wide runstate setup in run_context after merging the playon branch
cs.cmdutils/distinfo: cmd_blah descriptions should format the usage parts
cs.cmdutils: recite module version in command usage message?
BaseCommand: move most of __init__ into run-context along with setup_logging context manager use
√ cs.cmdutils: cmd_foo=None to remove am inherited subcommand
√ cs.cmdutils: help: suppress common subcommands?
cs.app.ydl: adopt the name format in use by cs.app.playon
cs.binary: _BinaryMultiValue_Base.for_json: use jsonable?
contextif: bypass the callable check if cmgr has .__enter__
√ atomic_filename: use the O_EXCL trick for reliable rename-to-target stuff?
does sqlite need the lock file or can I detect the locked exception and retry?
find all .from_any methods, convert to use @promote?
promote: correct typo annotations
@promote: update signature by inspecting the signatures of the promotion functions?
rewrite mrg using hashindex?
cs.delta: monitor() to accept an iterable of states as alternative to polling
Result: embed state diagram in the PyPI README.md
RunState: subclass FSM
RunState: include state diagram in README.md
RunState.notify_cancel: use the FSM notification system
cs.fsm: why is the default state a per-thread perthread_state.initial_state d
default: buglog in Python?
default: use cs.psutils.prep_argv throughout cs.cmdutils d
cs.cmdutils: shell: subcommand with no args - enter the subcommand mode even if there is a default subcommand, display usage on entry
cs.jsonutils: merge the various JSON utility functions?
merge the variable jsonable functions?
√ default: replace underscores with dashes in subcommand names in cs.cmdutils
√ fs.ftags: "fstags help ls" has bogus output
cs.upd.run_task: wait 0.5s before displaying the ticker? probably interacts badly with use of the ticker proxy
ffmpeg-docker: make stdin and stdout work correctly so that I can pipe ffmpeg commands
script to run strace or truss or sudo dtruss -p PID etc depending on the OS
√ cs.cmdutils OptSpec to be promotable, leverage in popopts
fetch the dedrm package if not present, store where? maybe ebooks dedrm install ? put in calibre if present?
service_api: rate limiter? context manager to access it directly, implied if .API_RATE_LIMIT
Upd: try the hide-the cursor stuff again, maybe in the update+clean method
Upd: keep a set of dirty slots, update+clean method
setvar: not expanding leading $MANPATH etc
bin-cs/brew: pass all HOMEBREW_* envvars through to brewexe
motion-shrink-timelapse: use -disposition to extract the 7am video from as JPG and add as the embedded cover
motion-shrink-timelapse: -metadata fields
TODO: accept -f to specify the file?
dk update: figure out the git rev associated with the image which would be pulled, list log from fstag dk.lastrev to that rev
cs.distinfo: a leading "# pylint:" comment is not a standin for a missing docstring
HasThreadState.default: run as a decorator if arg0 is a callable? make factory etc keyword only
ffmpeg-resize script - 2 pass ffmpeg
mklinks: update the hashindex while scanning
hashindex ls: default exclusions eg .hg,.git b d
fstags: drop rpaths func, merge into cs.fs.rpaths maybe?
default_params: supply modified signature for wrapper function indicating the param is optional
@uses_blah: correct type annotations
ffmpeg-docker: does not like files in other directories or something - some bug in atomic filename?
dlog: DLog to provide a Logger interface?
ydl/ffmeg-docker - network=none seems to break ffmpeg - what is it fteching and why, should I tweak the filenames?
ydl - specify preferred ffmpeg_exe + envvar?
√ hashindex rhashindex(rhost,dirpath[,ssh_exe=][,hashindex_exe=])
hashindex rearrange --sh to emit sh quotes commands inc the mkdirs
√ TagSet: parse_tag_value: a bare "nan" is a float
√ dlog needs a way to batch delayed updates
√ file checksum and tree sync tool to maintain a parallel tree based on checksums eg in a dl folder
cs.progress: progressbar with worker thread ticker to update the progress instead of updating on the iteration
√ cs.tarutils: polling task which stats the current filename every 0.5 or so seconds
cs.tarutils: cope with filenames which are not validly utf-8 encoded in the tar v stream
dk login update: silence on no change, same for update-sh
√ rel needs to check packages against the list from the DE guys
run-unbound: update config check incantation
√ ffmpeg-docker: support "ffmpeg-docker --version"
√ ListQueue should have builtin unrepeated support
Result with placholder return until some async operation completes it? thinking Tagger rule inference
cs.py.stack function to return the caller's current method name and class
method for MultiOpenMixin to capture common open-in-caller-close-in-child idiom?
√ cs.distinfo: cs-release seems to ignore SIGINT at least during a "rel"
cs.debug: Lock and RLock to be the same class with a different underlying lock class
Pfx: reimplement as a linked list, use HasThreadState
CornuCopyBuffer: improve docstring - replace references to .buf etc
frename needs to be a mode of fstags to move the tags
"Because" class containing a bool and an explaintion, start using in the SvcD test function and elsewhere
@promote: make @strable wrap this, using params=[0],promote[0]=open
@promote: optional promote[param_name]->callable mapping
@promote: accept ints in params to identify positional parameters?
an @promote decorator to scan types in func sig and call type.promote
progressbar/iterbar: check out len and length_hint as defaults for total
iterbar: call back to length_hint if no len as default?
√ mklinks: quit on SIGINT
cs.fsm: better docstrings, suppress FSMSubType docstring somehow
proxy-peerage: name acls using proxies:ptn passed through the identifier stuff from named_row_tuples - should make for better diffs and more readable configs
proxy-peerage: host/fqdn pattern: turn into an exact regexp?
cs.urlutils: drop Python 2 support
cs.upd: above should do clear-to-end-of-screen?
cs.binary: BinaryMixin.scan_file: CCB.from_file: return the unread buffer bytes to the file? seek if possible, warning if not and some buffered data
cs.logutils: PfxFormatter: dict args support needed
Pfx: accept a mode to defer computing the format string, eg for pfx_call et al, to make them nearly free
@locked_property: replace with @cachedmethod throughout
@cachedmethod: needs a __lock attribute, then review use throughout
cs.upd: Upd activation always makes the status line, Upd.insert can never create slot 0
cs.upd: print to know if inside above(), or above() to enter disabled mode
cs.iso14496: adapt for mp4 records with padding if short - adjust length field
cs.binary: a safe packet view into a file, based off the binary offset/length whihc can save via a safe sized buffer
cs.units: make decompose return an object which proxies to the list but is formattable and has a nice __str__, supporting print(bytes_geek(nbytes)) etc
cs.edit: use subprocess.run check=True
cs.app.maildb: port to BaseCommand
cs.logutils: new LoggingSetup class embodying infer_log_level etc, as a context manager to push and pop the setup, setup_logging to do the first part, easy replacement for setup_logging of some kind and use it in run_context
shortpath: optional using_symlinks mode switch to use bin-cs/shortpath-prompt sylink algoritm
BaseCommand: drop run_argv method
cs.logutils: supplant_logger should override the logging-already-set-up check?
cs.logutils: call basicConfig for the no-existing-logging mode
cs.logutils: drop supplant_logger, maybe turn into some mode
cs.logutils: drop warning and friends, no longer needed?
cs.pfx: drop Pfx.warning and friends, never used?
cs.logutils: context manager version of setup_logging, call it from setup_logging
UpdProxy: can we have an ftext property and monitor format keys for update?
rip out all cs.daetutils and friends, use the arrow module
unhostsify leaves temp files around, probably if interrupted
cs.deco: use @functools.wraps to gather up __doc__ etc
fstags ls in / wigs out
pfx_method no longer honours with_args, flip with_args to True and reimpl args?
cs.cmdutils: cmd_help does not print the usage preamble, just the per command usages
baseCommand autousage: make up a stub usage for subcommands with no usage
parser for /etc/terminal-colors.d
cs.upd/cs.logutils: if the Upd is disabled, logging upd_mode goes silent - fall back to plain nonupd_mode?
cs.upd: add pprint wrapper
cs.app.playon: keep playon recording info as ontology, distinct from state db
gitlog - record the branch too - maybe totally record dlog
extended prime seive impl?
let $XDG_* envvars override $VARDIR $LOGDIR ~/rc etc
cs.pop3: buffering for the SSL mode
an atomic-sh make scratch dir then rename to target name decorator
cs.units: maybe we can embed "%2.1f" in the UnitStep instead of max_width? may be faster
pfx_method: pass printf_func arg to Pfx
BaseCommand: do the prefix thing? unique prefix enough to invoke subcommand?
BaseCommand usage: recognise synonyms and merge cmd as {cmd1,cmd2}
cs.mp3: parse tags? pull names etc from cs.id3
progress/upd: fixed with trailing units, eg %2d
run-backups: single file: src type desthost[:dstpath?] [options...]
cs.pfx: can we hang the prefixes on the current frame? would solve the generator issue (NO, WE CANNOT)
cs.upd: what to do when the number of status lines exceeds the terminal height?
try to strip out use of cs.py3.bytes
replace @locked_property with @property @locked @cachedmethod throughout to placate linters, then @OBSOLETE @locked_property
cs.logutils: warning et all: once=key (or key on the warning format string if True)
general facility to do things just once, particularly warnings - then port cs.progress to it
Upd instances: callable like a proxy, has a .text property too - basicly a proxy for prxoies[0]
cs.ansi_colour: parser to recognise/strip ANSI colours? general ANSI sequences? splitter with offsets for cutting things up?
cs.lex: unctrl: duh - it calls expandtabs at the bottom - back out the inline tab expander?
@OBSOLETE(PfxThread) and replace uses with cs.threads.bg
cs.logutils: nested cs.cmdutils can call setup_logging more than once, make that sane instead of adding multiple loghandlers
vbox: cmd to associate the current default interface before starting vm?
vbox merge-vdi to merge vdis made from the same import, so likely to have largely the same blocks
does dbdigraph really need T_SEQ and friends? try to push that into cs.hier too
securer findup: sanity check on ownership or perms to stop walk? tunable?
BaseCommand: can we provide the expected command name instead of the class name in the docstring?
cs.logutils: when cs.upd has an ansi_mode, colour messages even when logrec.levelno == self.upd_level
cs.upd: ansi_mode to accept coloured message strings - requires an ansi_len function in cs.tty
cs.upd: some kind of ANSI escape support so that we can embed ANSI sequences in strings without confusing the length counter? cs.ansi_colour to get a parser/length measurer?
cs.progress: OverProgress: if units_scale=None, defer units_scale to render time, get from first subprogress?
cs.progress: control over status display - units etc
cs.upd: rate per proxy, bisect to update counter, autotune?
incd: remote tmux session to be per target dir
haproxy-tool: turn "ssh borg listen remote..." into haproxy clauses, mode to emit header settings too, to make haproxy.conf
new cs.dlog module and bin-cs/dlog command doing what the shell script does now
dlog: commit logs - tags the commit hash and branch
dlog: accept tags (leading tag=value words)?
rig-portfwd command doing the tmrc setup, scrub, ssh-agent reconnect
can putacc be recoded to use fstags --for-rsync efficiently? PROBABLY NOT REQUIRES FULL TREE WALK unless we can target the subtrees
ydl - accept pathnames as arguments, accept -t (tail) to tail a single filename argument including stdin
treet - a tree tool to read "parentkey key text" and render various tree listings, like all rows containing a string, and all their children, and their direct parents to a root, and things like that - makes pt scripts much easier, and applies to other things like vcs logs, trees in db listings etc
pf-genrules command to read a list of high level src-peer-port-proto type rules and make pf rules for an anchor, with apply mode and diff
cs.vcs.hg: import mercurial on instantiation, use native mercurial calls
cs.vcs.hg: log_since etc to always return ReleaseLogEntry instances, with full desc etc - firstline convenience property etc
cs.lex: doc for get_sloshed_text includes mapper=<function slosh_mapper at 0x111cda5f0>
incd: only save target for remote targets
incd: trusting fstags is a security issue in hostile directories - make incd only accept ssh+cd, not cd+exec, and maybe require writable .fstags file?
cs.logutils: present main_handler in loginfo, have a mode to outright replace the root logger handlers
signature based @cached properties, with revision numbers as fallback mode
replace use of sys.hexversion with sys.version.major etc
cs.rfc2047: command line mode with filter-text and rename-filename modes
cs.contextutils: no_recursion(identity_value[,default_return_value]) context manager for functions which might accidentally recurse
cs.obj: new IndexableNamespace with _from_nested_dicts factory method (_or_ optional leading positional nested dicts), to publish and to use as the basis for ExtendedNamespace, itself to be renamed as FormattableNamespace
mailfiler run_context stackattrs loginfo.level=INFO is actually ineffective, how to modify cs.logutils to fix this?
BaseCommand: accept dict for initial options, some way to honour this during apply_defaults
bin/nodedb: turn into pure python nodedb main programme, replace this script with secure python stub
resolve bin/maildb vs bin-cs/cs-maildb
svcd: subprocess to chdir to $HOME or defined directory - via incd? - for reliable behaviour and logging
setup_logging: can this be a context manager pushing a handler (ideally hiding existing handlers)
cs.py3: update cs.p3 module docstring with example code as it does not show the submodule names
logutils: use cs.tty stuff for the status() function
@strable: treat pathlike things like str?
@locked: do a timedout acquire with backoff to aid deadlock debugging
RunState flow diagram: pending->running->cancelled-stopped and triggers?
cs.app.flags: make a FlagOSDir mapping class to implement the fs based flags, accept any mapping for the Flags class, move the normalisation the the Flags class otherwise a raw mapping impl might fail if moved to the fs
Pfx: do not insert umark: if umark is empty, supports "" and None
mutt-highlight: match markers at start or end of lines
readline: fix spelling, detab, apply set -ue, use read -r line as fallback
cs.excutils_tests: special logging setup to discard error messages - the successful test suite is very noisy
@decorator: issue warning if positional arg 0 is callable and other args supplied, at least for the interim
@decorator: maybe support @deco(callable,*a,**kw)?
@mapattr class decorator to map .foo to .bah.this.that... with get/set support (why? use case?)
cs.deco: @decorator: does not seem to propagate __doc__ to wrapper functions from inner function - needs debugging
man pages not included in PyPI packages, for example cs.app.mailfiler
cs.app.megacli: after fixup, copy to megacli_legacy as py2, upgrade megacli to python 3, update module docstrings to explain and reference
mcli: alarm control, locate control
cs.result: attach a RunState and use it for the .state property - support attach in __init__ to use an existing runstate
rc/shell/fn-vcs: move repeated-commit check into hg() and git() functions
@cached: cache generators
replace cs.env.envsub with os.path.expandvars
portfwd: changes to match svcd changes
svcd: take a Service instance, which will have optional on_reap, on_spawn etc method, cutting down the ludicrous param list
drop lib/python/cs/testdata/cs.mailutils/maildir, too big
cs.mappings: support passing a named_column_tuple class to the names_columns_tuples loader
mappings: named tuple rows: omit columns with empty names - common in spreadsheet exports and breaks namedtuples
iso14496: parser for mdat section - how to know the audio/video format?
cs.flags: put a lock around all accesses
SvcD to subclass RunStateMixin?
Results to inherit from RunStateMixin?
SvcD/Portfwd: is there some unlocked dict access or something to trigger the segfault?
SvcD/Portfwd: cleanup mode polling pid files to kill former processes
take the wait-until-idle code from cs.vt.index.LMDBIndex and turn into a general facility in cs.resources
cs.resources: finish subopen proxy support
PyPI: remove cs.asynchron once dependent packages updated
cs.logutils.status: fold into cs.statusline, merge features
speed up cs.lex.unctrl using enumerate and join of substrs
make Asynchrons __await__able
port cs.fileutils.files_property to cs.deco.cached
cs.py.func: @signatured to track state based on signature func, support poll rate, port file_property etc to this
fvwm: move cs-fvwm-blah python code into cs.app.fvwm
cs.py.func: find out why eval causes syntax error with raise e from e2
vcs: modernise into "vcs top", "vcs branch", "vcs new-branch", "vcs commit" etc and track git branch changes with notes via post-commit
portfwd ARP_ADDR check for local networks
colourise command highlighing multiple regexps and line ranges
portfwd daemon mode to monitor active pf flags, start/stop relevant daemons
pf activate new-pf-clause
rename shortpath-prompt to short-path, make path breaking shortenings options (for prompt mode), make it work with relative paths and files as endpoints
setenv: remove cs.logutils, not py2.5 compatible
vbox: support remote device import for mkvdi
str: strace/ktrace wrapper, spawn ktrace + kdump -l
vbox status
vbox info
vbox: list vms is needed by some op and missing
compare curses calls between cs.logutils and cs.tty
merge cs.fileutils.shortpath and bin-cs/shortpath-prompt
myke: support +=
cs.numeric
add histograms
function the evaluate a rolling hash against all possible permutations
ssh-opts: cononical capitalisation of option names
cs.buffer
unit tests
cs.fileutils:
subfile: a file-like object proxying a byte range of another file
tail() with blocking and nonblocking mode; follow mode? emits chunks
mp4/iso14496
STTSBox (_GenericSampleBox): shorter rendition of .samples
cs.logutils: PfxThread to clone current prefix to new Thread, use in venti.blockify
yes