Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: e4251f432b77698f6fe241f5a96767358a3b8e0f197c8432e2e36e3499e597a2
Ticket: 7db9574a06b1994c5b3f8cdf13e6ffcbea072d4b
Undocumented features of zipfs implementation
User & Date: tberg on 2024-07-30 08:35:22
Changes

  1. assignee changed to: "nobody"
  2. closer changed to: "nobody"
  3. cmimetype changed to: "text/x-markdown"
  4. comment changed to:
    Here are some undocumented features of zipfs (implementing TIP 430):
    
    ## 1. zipfs mount_data
    There is a command `zipfs mount_data` but it is undocumented. Should it be documented in the manual page?
    
    ## 2. ::tcl::zipfs::tcl_library_init
    The C source code defines a `::tcl::zipfs::tcl_library_init` procedure that is also undocumented. Should it be documented and what does it do? I guess it is only for internal use.
    
    On the other hand, [TIP 430](https://core.tcl-lang.org/tips/doc/trunk/tip/430.md) defines a public subcommand `zipfs tcl_library`. This command is *not* implemented but seems to do the same.
    
    ## 3. zip archives attached to tclsh/wish or to libraries
    TIP 430 describes what happens when a zip archive is attached/appended to tclsh/wish or to a library file. In this context, it also mentions the specific mount points `ZIPFS_ROOT/app` and `ZIPFS_ROOT/lib/PGKNAME` plus some files and directories inside to look for during startup.
    
    This is documented in the tclsh(1) manual page. However, the documentation does not mention the specific mount points. The example at the end of TIP 430 should then also be included in the manual as it clarifies nicely how to exactly use that feature as it is difficult to put in words alone. This could be done in zipfs(n) to not overload the tclsh(1) manual page.
    
    Also, the TIP defines something like `tclsh install ...`. This is not documented in tclsh(1) and I am not sure if this is even implemented.
    
    
    ## 4. General consistency with TIP 430
    In general, the manual page is not consistent with the proposal in the TIP, meaning that zipfs was implemented differently from what the TIP says. Maybe that is OK, I am not sure whether the TIP should always be in line with the implementation, but here are some of the differences:
    
    * `zipfs canonical` has some options not mentioned in the TIP
    * `zipfs mount` can use a password option not documented in the TIP
    * `zipfs lmkimg` has one optional pair of options (... `?password infile?`) while the TIP has them as two separate options (... `?password? ?infile?`). This is somewhat related to [this ticket](/tktview/b9f3ff8fe69cae04239a2de23601d51b289dad06)
    
    When we refer to the TIP as "further reading" from the manual page, this could at least increase confusion.
    
  5. foundin changed to: "9.0"
  6. is_private changed to: "0"
  7. login: "tberg"
  8. priority changed to: "5 Medium"
  9. private_contact changed to: "94879582b1b42c382be6941728fabc85e28a2f74"
  10. resolution changed to: "None"
  11. severity changed to: "Important"
  12. status changed to: "Open"
  13. submitter changed to: "tberg"
  14. subsystem changed to: "- New Builtin Commands"
  15. title changed to: "Undocumented features of zipfs implementation"
  16. type changed to: "Bug"