Invalid key in stanza : restmap.conf`

Open
#153 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python, vscode
Domain
devtools

Research direction

Reproduce the diagnostics with the supplied restmap.conf stanzas, then trace the extension's restmap.conf validation path. Check how handlertype and handlerpersistentmode are recognized and find related tests or fixtures; done means both documented keys produce no syntax errors in the sample app.

Written by the indexing model from the issue text.

Description

in progress

Issue Short Description

Two invalid key in stanza errors on restmap.conf that contradict the documentation

Environment Information

VSCode Version:

  • Version: 1.101.1 (user setup)
  • Commit: 18e3a1ec544e6907be1e944a94c496e302073435
  • Date: 2025-06-18T13:35:12.605Z
  • Electron: 35.5.1
  • ElectronBuildId: 11727614
  • Chromium: 134.0.6998.205
  • Node.js: 22.15.1
  • V8: 13.4.114.21-electron.0
  • OS: Windows_NT x64 10.0.26100

Splunk Extension Version:

  • Identifier: splunk.splunk
  • Version: 0.3.4
  • Last Updated: 2025-06-10, 11:22:49

Issue Details

Seeing these two invalid key in stanza errors that are incorrect based on the documentation here: https://docs.splunk.com/Documentation/Splunk/9.4.2/Admin/restmapconf

  1. handlertype = python in [admin_external:<identifier] stanzas

     Invalid key in stanza [admin_external:ta-invalid_key_in_stanza1] in restmap.conf, line 6: handlertype = python.
    
  2. handlerpersistentmode = true|false in [script:] stanzas

     Invalid key in stanza [script:ta-invalid_key_in_stanza2] in restmap.conf, line 12: handlerpersistentmode = true.
    

Steps to reproduce

  1. Have vscode with Splunk Extension installed

  2. Create an app with the following files:

# default/app.conf
[install]
state = enabled

[package]
check_for_updates = false

[ui]
is_visible = false
is_manageable = false

# default/restmap.conf

[admin_external:ta-invalid_key_in_stanza1]
python.version = python3
handlerfile = ta_invalid_key_in_stanza1.py
handleractions = edit, list, remove, create
handlerpersistentmode = true
handlertype = python


[script:ta-invalid_key_in_stanza2]
handler = ta_invalid_key_in_stanza2
python.version = python3
handlerpersistentmode = true
scripttype = python

# metadata/local.meta
[]
access = read : [ * ], write : [ admin ]
export = system

Expected Outcome :

no syntax errors identified

Actual Outcome :

Line 6 and line 12 of restmap.conf showing invalid key in stanza errors

Dominant language
Python
Stars
96
Forks
28
Avg merge
4d 14h
Merged PRs (30d)
8

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from splunk/vscode-extension-splunk

All issues in splunk/vscode-extension-splunk

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.