golf-mcp 0.1.19__py3-none-any.whl → 0.1.20__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.

Potentially problematic release.


This version of golf-mcp might be problematic. Click here for more details.

golf/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "0.1.19"
1
+ __version__ = "0.1.20"
golf/core/builder.py CHANGED
@@ -1251,14 +1251,17 @@ def build_project(
1251
1251
  try:
1252
1252
  from golf.core.platform import register_project_with_platform
1253
1253
 
1254
- asyncio.run(
1254
+ success = asyncio.run(
1255
1255
  register_project_with_platform(
1256
1256
  project_path=project_path,
1257
1257
  settings=settings,
1258
1258
  components=generator.components,
1259
1259
  )
1260
1260
  )
1261
- console.print("[green]✓ Platform registration completed[/green]")
1261
+
1262
+ if success:
1263
+ console.print("[green]✓ Platform registration completed[/green]")
1264
+ # If success is False, the platform module already printed appropriate warnings
1262
1265
  except ImportError:
1263
1266
  console.print(
1264
1267
  "[yellow]Warning: Platform registration module not available[/yellow]"
golf/core/platform.py CHANGED
@@ -65,7 +65,7 @@ async def register_project_with_platform(
65
65
  try:
66
66
  async with httpx.AsyncClient(timeout=10.0) as client:
67
67
  response = await client.post(
68
- "http://localhost:8000/api/resources",
68
+ "https://golf-backend.golf-auth-1.authed-qukc4.ryvn.run/api/resources",
69
69
  json=metadata,
70
70
  headers={
71
71
  "X-Golf-Key": api_key,
@@ -36,11 +36,27 @@ def init_telemetry(service_name: str = "golf-mcp-server") -> TracerProvider | No
36
36
 
37
37
  # Check for Golf platform integration first
38
38
  golf_api_key = os.environ.get("GOLF_API_KEY")
39
- if golf_api_key and not os.environ.get("OTEL_EXPORTER_OTLP_ENDPOINT"):
40
- # Auto-configure for Golf platform
39
+ if golf_api_key:
40
+ # Auto-configure for Golf platform - always use OTLP when Golf API key is present
41
41
  os.environ["OTEL_TRACES_EXPORTER"] = "otlp_http"
42
- os.environ["OTEL_EXPORTER_OTLP_ENDPOINT"] = "http://localhost:8000/api/v1/otel"
43
- os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = f"X-Golf-Key={golf_api_key}"
42
+
43
+ # Only set endpoint if not already configured (allow user override)
44
+ if not os.environ.get("OTEL_EXPORTER_OTLP_ENDPOINT"):
45
+ os.environ["OTEL_EXPORTER_OTLP_ENDPOINT"] = (
46
+ "https://golf-backend.golf-auth-1.authed-qukc4.ryvn.run/api/v1/otel"
47
+ )
48
+
49
+ # Set Golf platform headers (append to existing if present)
50
+ existing_headers = os.environ.get("OTEL_EXPORTER_OTLP_HEADERS", "")
51
+ golf_header = f"X-Golf-Key={golf_api_key}"
52
+
53
+ if existing_headers:
54
+ # Check if Golf key is already in headers
55
+ if "X-Golf-Key=" not in existing_headers:
56
+ os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = f"{existing_headers},{golf_header}"
57
+ else:
58
+ os.environ["OTEL_EXPORTER_OTLP_HEADERS"] = golf_header
59
+
44
60
  print("[INFO] Auto-configured OpenTelemetry for Golf platform ingestion")
45
61
 
46
62
  # Check for required environment variables based on exporter type
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: golf-mcp
3
- Version: 0.1.19
3
+ Version: 0.1.20
4
4
  Summary: Framework for building MCP servers
5
5
  Author-email: Antoni Gmitruk <antoni@golf.dev>
6
6
  License-Expression: Apache-2.0
@@ -28,12 +28,11 @@ Requires-Dist: black>=24.10.0
28
28
  Requires-Dist: pyjwt>=2.0.0
29
29
  Requires-Dist: httpx>=0.28.1
30
30
  Requires-Dist: posthog>=4.1.0
31
- Provides-Extra: telemetry
32
- Requires-Dist: opentelemetry-api>=1.33.1; extra == "telemetry"
33
- Requires-Dist: opentelemetry-sdk>=1.33.1; extra == "telemetry"
34
- Requires-Dist: opentelemetry-instrumentation-asgi>=0.40b0; extra == "telemetry"
35
- Requires-Dist: opentelemetry-exporter-otlp-proto-http>=0.40b0; extra == "telemetry"
36
- Requires-Dist: wrapt>=1.17.0; extra == "telemetry"
31
+ Requires-Dist: opentelemetry-api>=1.33.1
32
+ Requires-Dist: opentelemetry-sdk>=1.33.1
33
+ Requires-Dist: opentelemetry-instrumentation-asgi>=0.40b0
34
+ Requires-Dist: opentelemetry-exporter-otlp-proto-http>=0.40b0
35
+ Requires-Dist: wrapt>=1.17.0
37
36
  Provides-Extra: metrics
38
37
  Requires-Dist: prometheus-client>=0.22.1; extra == "metrics"
39
38
  Dynamic: license-file
@@ -1,4 +1,4 @@
1
- golf/__init__.py,sha256=cAJAbAh288a9AL-3yxwFzEM1L26izSJ6wma5aiml_9Y,23
1
+ golf/__init__.py,sha256=8XalsVoLEfXslFvdtUEmkNOuYShzOzYOcFbgmOz1oSk,23
2
2
  golf/auth/__init__.py,sha256=Rj4yUngJklk6xrDCrxqLTtoDAMzF1HcTvy_l8wREeao,4103
3
3
  golf/auth/api_key.py,sha256=LiIraLiH2v7s3yavidaI6BDlAEfK8XnWF15QmaJn9G4,2378
4
4
  golf/auth/helpers.py,sha256=ZogdcHM7J2PN6cL6F6OLZ3gyoUR3dwAFDxOJQ2DW_bc,6526
@@ -11,13 +11,13 @@ golf/commands/build.py,sha256=jhdxB5EwwCC_8PgqdXLUKuBpnycjh0gft3_7EuTo6ro,2319
11
11
  golf/commands/init.py,sha256=DUAvGqOUapWdF2cgWPscqHRvyOZDiajR0F0Wkn_jm-k,10355
12
12
  golf/commands/run.py,sha256=xsiG5LZw4qVt3cRTTfIoWP4Bf4AxNBBJKx0NNfoua40,2884
13
13
  golf/core/__init__.py,sha256=4bKeskJ2fPaZqkz2xQScSa3phRLLrmrczwSL632jv-o,52
14
- golf/core/builder.py,sha256=flsXnlwOTUhXFMpmZwoxWgnK_oLj4zpSyqcKuDnXezw,59526
14
+ golf/core/builder.py,sha256=06BccMHR6BFMsdyL-3YJJFqLHVLE-NYSQriVyPFzL6s,59657
15
15
  golf/core/builder_auth.py,sha256=nGgyMTiRAqaNfh1FSvoFe6oTVq9RgfMf9JoFGAv2_do,14050
16
16
  golf/core/builder_metrics.py,sha256=j6Gtgd867o46JbDfSNGNsHt1QtV1XHKUJs1z8r4siQM,8830
17
17
  golf/core/builder_telemetry.py,sha256=jobFgRSspLQLuitL4ytk6asSUdTqYcDxGY3sTjkrZd4,2654
18
18
  golf/core/config.py,sha256=6yPtwzVTJauufEnrfUbxsz69H8jC0Ra427oDaRM0-xE,7397
19
19
  golf/core/parser.py,sha256=BQRus1O9zmzSmyavwLVfN8BpYFkbrWUDrgQ7yrYfAKw,42457
20
- golf/core/platform.py,sha256=Z2yEi6ilmQCLC_uAD_oZdVO0WvkL4tsyw7sx0vHhysI,6440
20
+ golf/core/platform.py,sha256=y8-yhRPfvm-Eu44p_kN9wg74n1kB2HweRgRYy-Gu1c4,6473
21
21
  golf/core/telemetry.py,sha256=CjZ7urbizaRjyFiVBjfGW8V4PmNCG1_quk3FvbVTcjw,15772
22
22
  golf/core/transformer.py,sha256=_0nM42M41oM9zw_XxPVVS6MErdBSw2B5lULC7_UFLfU,5287
23
23
  golf/examples/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
@@ -51,10 +51,10 @@ golf/metrics/__init__.py,sha256=O91y-hj_E9R06gqV8pDZrzHxOIl-1T415Hj9RvFAp3o,283
51
51
  golf/metrics/collector.py,sha256=iyRszP8TAAigyOsUFTGdKN8Xeob36LhUvXW9tntJrbA,7617
52
52
  golf/metrics/registry.py,sha256=mXQE4Pwf3PopGYjcUu4eGgPDAe085YWcsvcvWk0ny8Q,310
53
53
  golf/telemetry/__init__.py,sha256=ESGCg5HKwTCIfID1e_K7EE0bOWkSzMidlLtdqQgBd0w,396
54
- golf/telemetry/instrumentation.py,sha256=8n69nYUzsLCvItyYVe7TbxiyfYjgJHqC4sV7GgwL7QI,44652
55
- golf_mcp-0.1.19.dist-info/licenses/LICENSE,sha256=5_j2f6fTJmvfmUewzElhkpAaXg2grVoxKouOA8ihV6E,11348
56
- golf_mcp-0.1.19.dist-info/METADATA,sha256=VWwqQwy6gSijjJcjA2A2euWf53gHpZ3KhFRwK8yrE4U,12956
57
- golf_mcp-0.1.19.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
58
- golf_mcp-0.1.19.dist-info/entry_points.txt,sha256=5y7rHYM8jGpU-nfwdknCm5XsApLulqsnA37MO6BUTYg,43
59
- golf_mcp-0.1.19.dist-info/top_level.txt,sha256=BQToHcBUufdyhp9ONGMIvPE40jMEtmI20lYaKb4hxOg,5
60
- golf_mcp-0.1.19.dist-info/RECORD,,
54
+ golf/telemetry/instrumentation.py,sha256=t0iuoIuY3mmtcdNAlUvbUgUfpRkH0mZoYg2C6qm8g2s,45320
55
+ golf_mcp-0.1.20.dist-info/licenses/LICENSE,sha256=5_j2f6fTJmvfmUewzElhkpAaXg2grVoxKouOA8ihV6E,11348
56
+ golf_mcp-0.1.20.dist-info/METADATA,sha256=erjB5udWAGp_OQa3MiPhwbpi0R7zZAJeTMpSqnl67Rg,12820
57
+ golf_mcp-0.1.20.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
58
+ golf_mcp-0.1.20.dist-info/entry_points.txt,sha256=5y7rHYM8jGpU-nfwdknCm5XsApLulqsnA37MO6BUTYg,43
59
+ golf_mcp-0.1.20.dist-info/top_level.txt,sha256=BQToHcBUufdyhp9ONGMIvPE40jMEtmI20lYaKb4hxOg,5
60
+ golf_mcp-0.1.20.dist-info/RECORD,,