secondstrike 1.0.1__tar.gz → 1.0.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: secondstrike
3
- Version: 1.0.1
3
+ Version: 1.0.2
4
4
  Summary: Put your AI agent in command of a nation in SECOND STRIKE, a real-time world war on a 3D globe with a nuclear doomsday clock. Client, starter bot and an LLM agent for any OpenAI-compatible model.
5
5
  Author-email: "Kyle Clouthier (Clouthier Simulation Labs)" <kyle@simgen.dev>
6
6
  License: MIT
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "secondstrike"
7
- version = "1.0.1"
7
+ version = "1.0.2"
8
8
  description = "Put your AI agent in command of a nation in SECOND STRIKE, a real-time world war on a 3D globe with a nuclear doomsday clock. Client, starter bot and an LLM agent for any OpenAI-compatible model."
9
9
  readme = "README.md"
10
10
  license = { text = "MIT" }
@@ -23,7 +23,7 @@ import time
23
23
  import urllib.error
24
24
  import urllib.request
25
25
 
26
- __version__ = "1.0.1"
26
+ __version__ = "1.0.2"
27
27
  BASE = os.environ.get("SECONDSTRIKE_URL", "https://secondstrike-server-zgqvqzdrta-uc.a.run.app")
28
28
 
29
29
 
@@ -46,9 +46,14 @@ def ask_model(system, state, last_plan, llm_url, llm_key, model):
46
46
 
47
47
  def main(argv=None):
48
48
  argv = sys.argv[1:] if argv is None else argv
49
- if any(a in ("-h", "--help") for a in argv):
50
- print(__doc__)
49
+ flag = next((a for a in argv if a.startswith("-")), None) # flags are never names
50
+ if flag in ("--version", "-v"):
51
+ from . import __version__
52
+ print("secondstrike", __version__)
51
53
  return 0
54
+ if flag:
55
+ print(__doc__)
56
+ return 0 if flag in ("-h", "--help") else 2
52
57
  llm_url = os.environ.get("OPENAI_BASE_URL", "https://api.openai.com/v1").rstrip("/")
53
58
  llm_key = os.environ.get("OPENAI_API_KEY", "")
54
59
  model = os.environ.get("MODEL", "gpt-4o-mini")
@@ -40,9 +40,14 @@ def decide(s):
40
40
 
41
41
  def main(argv=None):
42
42
  argv = sys.argv[1:] if argv is None else argv
43
- if any(a in ("-h", "--help") for a in argv):
44
- print(__doc__)
43
+ flag = next((a for a in argv if a.startswith("-")), None) # flags are never names
44
+ if flag in ("--version", "-v"):
45
+ from . import __version__
46
+ print("secondstrike", __version__)
45
47
  return 0
48
+ if flag:
49
+ print(__doc__)
50
+ return 0 if flag in ("-h", "--help") else 2
46
51
  name = (argv[0] if argv else "ROOKIE").upper()[:11]
47
52
  country = argv[1] if len(argv) > 1 else "Canada"
48
53
  c = Client()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: secondstrike
3
- Version: 1.0.1
3
+ Version: 1.0.2
4
4
  Summary: Put your AI agent in command of a nation in SECOND STRIKE, a real-time world war on a 3D globe with a nuclear doomsday clock. Client, starter bot and an LLM agent for any OpenAI-compatible model.
5
5
  Author-email: "Kyle Clouthier (Clouthier Simulation Labs)" <kyle@simgen.dev>
6
6
  License: MIT
File without changes
File without changes
File without changes