#2754 closed task (fixed)

remove "_appname.py" file, variable application name

Reported by: warner Owned by: Brian Warner <warner@…>
Priority: normal Milestone: 1.13.0
Component: packaging Version: 1.10.2
Keywords: Cc:
Launchpad Bug:

Description

A long long time ago, at AllMyData, we had different branches of the Tahoe source tree for different deployment environments. We had a "prod" branch for production, a "dev" branch for development, and I think a "client" or "server" or something else.

To be able to have multiple branches installed on a single box, we added code to alter the installed bin/tahoe name. We were using Darcs back then, and the easiest thing we could think of was to put the "application name" into a file, and add a single darcs patch that changed this file's contents to "prod" or "dev" or whatever. On the prod machines, we'd have a darcs repo that was exactly like the main repo, except it would have this one extra appname-changing patch.

That era is long gone, and we no longer need that complexity in our setup.py. If people really want this feature (maybe someone wants to fork tahoe and call it "shmahoe"), they can just edit setup.py to change the name of the entrypoint script.

(actually, it might be slightly harder than that: we have some tests that check that the literal string "tahoe" is in the output of tahoe --version. If we really want to support forking, then keeping this in a allmydata.__appname__ constant would be easier. But I don't think this is worth it)

Actions:

  • delete src/allmydata/_appname.py
  • remove the setup.py code that reads/writes it
  • maybe change the tests that look for allmydata.__appname__ in command output and have them look for a hard-coded "tahoe" instead. This includes test_cli, test_client, test_runner, and test_system.

Change History (3)

comment:1 Changed at 2016-06-28T18:20:37Z by warner

  • Milestone changed from 1.12.0 to 1.13.0

moving most tickets from 1.12 to 1.13 so we can release 1.12 with magic-folders

comment:2 Changed at 2016-08-08T01:53:06Z by warner

first patch in https://github.com/tahoe-lafs/tahoe-lafs/pull/305

This removes _appname.py and the code which writes/reads it. It does not change any of the tests yet.

comment:3 Changed at 2016-08-12T06:25:05Z by Brian Warner <warner@…>

  • Owner set to Brian Warner <warner@…>
  • Resolution set to fixed
  • Status changed from new to closed

In b637636/trunk:

remove _appname.py file

We no longer need the complexity of choosing the application name at
runtime. This removes the setup.py code which populates the _appname.py
file, and the code in init.py which reads it. It does not yet remove
the tests which compare the output of e.g. tahoe --version against
allmydata.__appname__, which I think could be removed, but that's more
invasive than I want to do right now.

closes ticket:2754

Note: See TracTickets for help on using tickets.