sourcecode 1.32.5__py3-none-any.whl → 1.32.6__py3-none-any.whl

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.
sourcecode/__init__.py CHANGED
@@ -1,3 +1,3 @@
1
1
  """sourcecode — Deterministic codebase context maps for AI coding agents."""
2
2
 
3
- __version__ = "1.32.5"
3
+ __version__ = "1.32.6"
sourcecode/cli.py CHANGED
@@ -384,6 +384,18 @@ def _get_command_with_preprocessing(typer_instance: Any) -> Any:
384
384
  # Refresh help text at invocation time so it reflects current license state.
385
385
  cmd.help = _build_help_text()
386
386
 
387
+ # Add [Pro] badge to Pro-gated option help strings for free-tier users.
388
+ try:
389
+ from sourcecode.license import is_pro as _lp_is_pro
390
+ except Exception:
391
+ _lp_is_pro = False
392
+ if not _lp_is_pro:
393
+ _PRO_OPTS = {"full"}
394
+ for _param in cmd.params:
395
+ if getattr(_param, "name", None) in _PRO_OPTS and getattr(_param, "help", None):
396
+ if "[Pro]" not in _param.help:
397
+ _param.help = _param.help + " [dim][Pro][/dim]"
398
+
387
399
  _orig_cmd_main = cmd.main
388
400
 
389
401
  def _cmd_main(args: Optional[list[str]] = None, **kwargs: Any) -> Any:
@@ -1442,12 +1454,23 @@ def main(
1442
1454
  if dependency_analyzer is not None
1443
1455
  else None
1444
1456
  )
1457
+ # Free-tier node cap: limit graph size to 10 nodes unless Pro.
1458
+ _effective_max_nodes = max_nodes
1459
+ try:
1460
+ from sourcecode.license import is_pro as _lp_is_pro_gm
1461
+ except Exception:
1462
+ _lp_is_pro_gm = False
1463
+ _FREE_NODE_CAP = 10
1464
+ if not _lp_is_pro_gm and graph_analyzer is not None:
1465
+ if _effective_max_nodes is None or _effective_max_nodes > _FREE_NODE_CAP:
1466
+ _effective_max_nodes = _FREE_NODE_CAP
1467
+
1445
1468
  module_graph = (
1446
1469
  graph_analyzer.merge_graphs(
1447
1470
  module_graphs,
1448
1471
  detail=graph_detail_typed,
1449
1472
  edge_kinds=parsed_graph_edges,
1450
- max_nodes=max_nodes,
1473
+ max_nodes=_effective_max_nodes,
1451
1474
  entry_points=entry_points,
1452
1475
  )
1453
1476
  if graph_analyzer is not None
@@ -1567,6 +1590,15 @@ def main(
1567
1590
  semantic_summary=sem_sum,
1568
1591
  )
1569
1592
 
1593
+ # Free-tier node cap for --semantics: limit semantic_symbols to 10 unless Pro.
1594
+ if semantic_analyzer is not None and sm.semantic_symbols:
1595
+ try:
1596
+ from sourcecode.license import is_pro as _lp_is_pro_sem
1597
+ except Exception:
1598
+ _lp_is_pro_sem = False
1599
+ if not _lp_is_pro_sem and len(sm.semantic_symbols) > _FREE_NODE_CAP:
1600
+ sm = replace(sm, semantic_symbols=sm.semantic_symbols[:_FREE_NODE_CAP])
1601
+
1570
1602
  # Runtime architecture — classify workspace packages for structural summaries
1571
1603
  if workspace_analysis.workspaces:
1572
1604
  from sourcecode.runtime_classifier import RuntimeClassifier
sourcecode/license.py CHANGED
@@ -248,6 +248,7 @@ def require_feature(feature_name: str) -> None:
248
248
  f"'{display}' requires a Pro license. "
249
249
  "Run: sourcecode activate <license_key>"
250
250
  ),
251
+ "upgrade_hint": "sourcecode activate <license_key>",
251
252
  }
252
253
  sys.stdout.write(json.dumps(payload, ensure_ascii=False) + "\n")
253
254
  sys.stdout.flush()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: sourcecode
3
- Version: 1.32.5
3
+ Version: 1.32.6
4
4
  Summary: Deterministic codebase context for AI coding agents
5
5
  License-File: LICENSE
6
6
  Keywords: agents,ai,codebase,context,developer-tools,llm
@@ -1,4 +1,4 @@
1
- sourcecode/__init__.py,sha256=OcIqvxMtCqwdofwolfD8-rpWZk-fh2PbDUp8V3xRur4,103
1
+ sourcecode/__init__.py,sha256=KgyhBn2jfjwXzdBpdStMZoNfqCUlHHAwk1wuU3Nez1M,103
2
2
  sourcecode/adaptive_scanner.py,sha256=XffluXKzJUXrMtjEiAOnSNPZnztdIcts17T9ouHeID0,10521
3
3
  sourcecode/architecture_analyzer.py,sha256=qh749a7ykPtGmQI1MR9y6j8TtL_jBdVYFx9YRsLqOMw,44121
4
4
  sourcecode/architecture_summary.py,sha256=z34_6v7cSwy98cof2UVciGho7SCrZ93tiqMmq5WNzRQ,20405
@@ -7,7 +7,7 @@ sourcecode/cache.py,sha256=h1BT-9PG_7HK---ZzH0j5u3PN0dz2s6IRAUOjQIPYH4,28055
7
7
  sourcecode/cache.tmp_new,sha256=-IvV7CojiZjqeKMln1m-lqI0QVA2uFGWmYir4XRFOUk,27970
8
8
  sourcecode/canonical_ir.py,sha256=_HM3AUmKSdna9u4dCoU6rpgSA6HdF8gzOKZykIUCNGY,23277
9
9
  sourcecode/classifier.py,sha256=2lYoSH3vOTkXZYPU7Go2WIet1-IuNzTWVhc-ULnXtgw,8024
10
- sourcecode/cli.py,sha256=-iUcg3FA8K0xgG1xvXJRCF4Xrleyf04QEOJho8bF5mw,169600
10
+ sourcecode/cli.py,sha256=PJbs8ltIdsBmedJlBJ6HG9UCRBLDtUhG_eIqyazP_sU,170992
11
11
  sourcecode/code_notes_analyzer.py,sha256=EJemNCNc9Dn-1RZYu-aNbK0ELzmsyC4s6FdHi3XyNEI,9392
12
12
  sourcecode/confidence_analyzer.py,sha256=_jckZSxksV-OU38vbkxfVNBnWCtlCq8Vwfg23x1uspA,19054
13
13
  sourcecode/context_scorer.py,sha256=QpChSpsmaAYz91rXA4Ue5xzQmNz_ZboZN09YOHScq1U,14679
@@ -23,7 +23,7 @@ sourcecode/file_classifier.py,sha256=QrYm7MlG29HQdAR1WOfpnIIBysAz62c5coz9eQ76meo
23
23
  sourcecode/flow_analyzer.py,sha256=dSiuY4w49k29jW_EPXUOND9B5uVbuCA7kjnuHi-pIWA,28781
24
24
  sourcecode/git_analyzer.py,sha256=JStxTQXNjBWi_wLdwhsZs9mT-v50cSJIz4Agzn6Kh9I,13362
25
25
  sourcecode/graph_analyzer.py,sha256=iUK-7pSV-cvGqqD2hENdYmhnm0wcXFEyK-xnu5ul8OU,62515
26
- sourcecode/license.py,sha256=m5n4PKZ7ZZZ17bpLjIsKwd94PXaIg5iS_2kFNjCV2Og,11378
26
+ sourcecode/license.py,sha256=cz6FIqo8QjPeLmXiBWoo256gfqsotgbHHgMMEwR5pjw,11439
27
27
  sourcecode/mcp_nudge.py,sha256=5ELU_ixzh6uA83NXLOZT8h00OhL53okfQdji3jyKOjg,2917
28
28
  sourcecode/metrics_analyzer.py,sha256=m0ENgtqKeBL17kUIK3fmGkgo7UfXBNHxCMj0H_Y5K7c,22750
29
29
  sourcecode/output_budget.py,sha256=43307mJEyUPU3MI-QEQoVxrcAvNyUzdzF_SAPgisBQE,6603
@@ -80,8 +80,8 @@ sourcecode/telemetry/consent.py,sha256=wLMvGNJeSSyZoNkQXpoUioY6mMv4Qdvuw7S9jAEWn
80
80
  sourcecode/telemetry/events.py,sha256=oEvvulfsv5GIDWG2174gSS6tNB95w38AIYiYeifGKlE,2294
81
81
  sourcecode/telemetry/filters.py,sha256=Asa71oRl7q3Wt_FMwuufIZJFzSYdgRNKS8LHCIyFeYE,4805
82
82
  sourcecode/telemetry/transport.py,sha256=KJeIPCPWMdmbCP3ySGs2iUlia34U6vWne2dZsUezesw,1560
83
- sourcecode-1.32.5.dist-info/METADATA,sha256=kuVwifYAr-Xr4ME4ak-9zWuZqYS-fFMYfFcpx4YJugs,19120
84
- sourcecode-1.32.5.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
85
- sourcecode-1.32.5.dist-info/entry_points.txt,sha256=ex3F9rmbXeyDIoFQHtkEqTsKSaJow8F0LrVu8XfIktQ,57
86
- sourcecode-1.32.5.dist-info/licenses/LICENSE,sha256=7DdHrU9Z_3e7dSvq4ISijZNjnuHo5NIHNiHDouMQ9JU,10491
87
- sourcecode-1.32.5.dist-info/RECORD,,
83
+ sourcecode-1.32.6.dist-info/METADATA,sha256=Aa7pmdWB0T8LkQYd6rihJOQQwE1Ts_nJ7AHUyYT2gF0,19120
84
+ sourcecode-1.32.6.dist-info/WHEEL,sha256=QccIxa26bgl1E6uMy58deGWi-0aeIkkangHcxk2kWfw,87
85
+ sourcecode-1.32.6.dist-info/entry_points.txt,sha256=ex3F9rmbXeyDIoFQHtkEqTsKSaJow8F0LrVu8XfIktQ,57
86
+ sourcecode-1.32.6.dist-info/licenses/LICENSE,sha256=7DdHrU9Z_3e7dSvq4ISijZNjnuHo5NIHNiHDouMQ9JU,10491
87
+ sourcecode-1.32.6.dist-info/RECORD,,