Skip to content

chore(release): bump version to 6.3.1 - #603

Merged
dwolfson merged 22 commits into
odpi:mainfrom
dwolfson:prep/6.3.1
Nov 18, 2026
Merged

dwolfson merged 22 commits into
odpi:mainfrom
dwolfson:prep/6.3.1

Conversation

@dwolfson

Copy link
Copy Markdown
Member

pyegeria 6.3.1: upstream main (with #601 My Profile communities and #602) plus the reviewed fixes held since 6.3.0. Every fix commit was read back by the Architect, and all commits are signed and carry Signed-off-by.

⚠️ Behaviour changes

  • No built-in password or admin credential in the library (PY-33, PY-35). With no password configured, create_egeria_bearer_token raises PyegeriaInvalidParameterException ("No password to sign in to Egeria as '' …") before any request is sent.
    • Before, the request reached Egeria with an empty or guessed password and came back as a 401. Code that catches that 401 should catch the new exception.
    • resolve_egeria_credentials no longer falls back to a built-in password.
    • The ADMIN_USER / ADMIN_PASSWORD reads have no literal defaults, nor does UserProfileConfig.user_pwd.
  • The command-line tools keep their demo-password fallback until 6.4. They read the password from --password / --user_pass and EGERIA_USER_PASSWORD only, so set EGERIA_USER_PASSWORD now. The new docs/setting-your-egeria-password.md explains where pyegeria looks for the password and how to set it.
  • In a process declared multi-user, a report run with no user is refused (PY-32). This covers EA, Studio and pyegeria's MCP HTTP server. Before, exec_report_spec / preview fell back to the configured user, which there is the app's service account. async_preview also refuses a client with no user_id, such as as_client(client) handed over by mistake. Single-user use (CLIs, notebooks) is unchanged.

Fixes

  • PY-29: add_like_to_element sends the emoji you choose, and doesn't hard-code a zone.
  • PY-30: Dr.Egeria's MCP run_block: a block with H1/H2 headings no longer parses to "0 commands, success"; the extractor gives hints.
  • PY-31: the delete_collection docstring matches the code (cascade defaults to False).
  • PY-34: ClassificationExplorer.find_authored_elements gets a real type-fit check in authoring validation. It's checked against the metadata_element_type the spec fixes, instead of warning "pyegeria has no record of its element type".

Also included (already on main)

Checks

  • Full micro-tests, both env ways (EGERIA_USER unset, and EGERIA_USER=someoneelse): 0 new failures by name against main 83675d4.
  • Wheel built and installed in a clean 3.13 venv:
    • version 6.3.1;
    • my_egeria is top-level, and serve_my_profile is installed;
    • with no password configured, the resolved password is None;
    • PY-32 and PY-34 are present.
  • uv.lock was regenerated with uv 0.13.9; the only change is the version.

🤖 Generated with Claude Code

…hard-coded zone

With an emoji and no body, the request carried the docstring placeholder
"Add characters here as text" instead of the emoji, and put the like in a
ZoneMembership hard-coded to erinoverview. The body now holds the emoji
passed in and no zone. A caller that wants a zone passes its own body.
Calls without an emoji, or with the caller's own body, are unchanged.
The Portal's likes send no emoji, so they were never affected.

Reported by Peter (via Dan, 2026-11-17).

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…ody class

R1: the comment said a caller could zone a like by passing its own body.
This endpoint ignores initialClassifications, and Egeria anchors a Like to
the liked element, so it is exactly as visible as that element.
R2: the endpoint reads UpdateElementRequestBody, so use that class. It
behaves the same, since the class is ignored.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…the code does (PY-31)

Both the async and sync docstrings said "defaults to True", but both
signatures default cascade to False. A reader trusting the docstring
could misjudge what a default delete removes. Docstrings only; no
behaviour change.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…less than meant (PY-30)

A Dr.Egeria command is an H2 heading "## <Verb> <Object>" with H3
attributes. Two heading mistakes passed silently:
- "# Delete Instance" (H1) is kept as prose, so the document runs no
  command and reports success with 0 commands;
- an attribute written as H2 ("## Delete Method") matches the command
  pattern and becomes a bogus command of its own.

diagnose() returns hints in words:
- an H1 line that is a command heading → write it as '## …';
- an H2 "command" whose name is an attribute of the command just above
  it, per the compact command specs → write it as '### …';
- no command at all → the expected shape.
The spec lookup is optional (an explicit mapping can be passed), and
diagnose() never fails extraction.

Tests: tests/micro-tests/test_extraction_diagnose.py (7 cases). The
micro-test suite has the same 15 failure names on base and branch.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…ands in the H1 hint (PY-30 R2)

The H1 check flagged "# Create a virtual environment" inside a ```bash
fence and advised turning it into "## Create a virtual environment",
which would make a shell comment a Dr.Egeria command. The tutorials are
full of such comments.

Now:
- lines inside ``` or ~~~ fences are skipped;
- when the command specs are loaded, the H1 hint is given only when
  "<Verb> <Object>" is a known command name, as the H2 check already
  does.

Tests: +4 (a fenced shell comment, a ~~~ fence, a non-command H1 with
specs, the real specs on a tutorial comment). 31 extraction tests pass
both env ways.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…es in words (PY-33)

resolve_egeria_credentials ended `... or "secret"`, and mermaid_utilities
defaulted ADMIN_PASSWORD / EGERIA_USER_PASSWORD to "secret", so a process
with no password configured signed in with a guessed one. On 2026-11-17
that is what EA's service account tried on laz (TR-34).

- resolve_egeria_credentials: with nothing configured the password is None.
- mermaid_utilities: no "secret" defaults.
- create_egeria_bearer_token (platform and server clients, sync and async):
  with no password (None, "" or NO_PASSWORD) it raises
  PyegeriaInvalidParameterException naming the user and what to set,
  before any sign-in request is sent. The 401 auto-retry already requires
  a held password, so it is unaffected.

Tests: test_py33_no_default_password.py (7), both env ways.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…igured user (PY-32)

EA's U3 (2026-11-17): EA handed preview as_client(client), a context
manager, as the client. preview read user_id/token from it as None, and
exec_report_spec then ran as the configured user, which in EA is its own
service account.

- async_preview refuses (AuthoringRefused) a client with no user_id, and
  says to pass the client itself, not as_client(client).
- exec_report_spec's user/user_pass defaults are no longer the settings
  values fixed at import. _caller_identity resolves them per call:
  - in a process declared multi-user (PYEGERIA_MULTI_USER /
    declare_multi_user: the Portal, EA, Studio, the MCP HTTP server) a run
    with no user is refused in words, and a named user never takes the
    configured password;
  - in a single-user process (CLI, notebook) an omitted user/password take
    configured_user_id() and the configured password, read at call time:
    6.x CLI behaviour (ISSUE-161).

The Portal's and EA's callers already pass an explicit identity.

Tests: test_py32_no_identity_no_fallback.py (7), both env ways; the
authoring/preview/executor suites (202) pass.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
… has no settings defaults

R1: _caller_identity's docstring said the Portal is declared multi-user.
It is not (no declare_multi_user() or PYEGERIA_MULTI_USER there yet).
Name the processes that do declare: EA, Studio and pyegeria's MCP HTTP
server (mcp_server.py).

R2: _exec_report_spec_impl no longer defaults user/user_pass to
settings.User_Profile, fixed at import. Its only caller,
exec_report_spec, passes the identity _caller_identity resolved.

Micro-tests vs upstream by name, both env ways: 0 new.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
PY-33 removed the "secret" password default and mermaid_utilities'
admin-password default. pyegeria still read ADMIN_USER / ADMIN_PASSWORD
with literal defaults in 24 places: md_processing (dr_egeria,
common_md_utils), mermaid_utilities' admin user, and ~20 CLI modules
under commands/.

Each only defines module constants (EGERIA_ADMIN_USER /
EGERIA_ADMIN_PASSWORD) that nothing in pyegeria reads. They now read the
environment with no default: unset means None. The names are kept for
any outside importer.

Two files, commands/deprecated/list_data_designer.py and
list_data_structures_full.py, already fail to parse on upstream/main.
They got the same text-only change and are otherwise untouched.

Tests: test_py35_no_default_admin_credentials.py (5), both env ways:
None when unset, read from the environment when set, and a source scan
that fails on any os.environ.get("ADMIN_USER"/"ADMIN_PASSWORD", <default>)
left in pyegeria/, md_processing/ or commands/.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…pe the spec asks for (PY-34)

ClassificationExplorer.find_authored_elements returns whatever
metadata_element_type it's asked for, so FIND_ELEMENT_TYPES had no entry
for it. Its type-fit check warned "Can't tell whether … pyegeria has no
record of its element type" and checked nothing. This surfaced in EA's U3
(2026-11-18) on its GlossaryTerm and GovernancePolicy content-status
specs.

New GENERIC_FIND_TYPE_PARAMS names the parameter that carries a generic
finder's returned type. _check_find_fit reads the value the spec fixes
in action.spec_params:
- fixed to the target, or to a supertype of it (via type_super_chain):
  checked, and the fit passes;
- fixed to an unrelated type: refused, as for any finder;
- not fixed: a warning in words (the method can return any type, so fix
  metadata_element_type = <target>), recorded in not_checked.

It isn't registered as None ("returns anything"), which would wave the
check through without knowing the type. EA's v2 content-status specs fix
metadata_element_type to the target (spec_authoring_v2 l.408), so theirs
now check and pass.

Tests: test_py34_generic_finder_type_fit.py (8), both env ways.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…built-in passwords (PY-35 W1)

The hey_egeria README's environment table still documented the defaults
PY-33/PY-35 removed, and three names the code doesn't read:
- EGERIA_USER_PASSWORD: no default (was "secret").
- EGERIA_ADMIN_USE -> ADMIN_USER, no default: the code reads ADMIN_USER;
  EGERIA_ADMIN_USER is only a Python constant name.
- EGERIA_ADMIN_PASSWORD -> ADMIN_PASSWORD, no default.
- EGERIA_TIMEOUT -> PYEGERIA_TIMEOUT_SECONDS, default 30: nothing reads
  EGERIA_TIMEOUT.
Every other name in the table was checked against pyegeria/core/config.py.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…back W2)

- UserProfileConfig.user_pwd defaulted to "secret" (core/config.py l.191).
  load_app_config always sets it, so it wasn't live, but the config report
  showed it as the default password, and any model built another way got
  it back. It's now None.
- monitor_engine_status read EGERIA_ADMIN_PASSWORD with a "secret" default
  (a dead constant, missed by the first scan because it uses that env name).
- build_global_guid_lists (create_tech_guid_lists, a developer utility
  with no callers) defaulted to "secret"; it's now None, and sign-in
  refuses in words without a password (PY-33).

The scan in test_py35_no_default_admin_credentials.py now also fails on
any literal password default in pyegeria/ or md_processing/, as a class
field, a parameter default, or a *PASSWORD*/*_PWD env read with a literal
fallback. It has its own regression case for a parameter list.

Left for a decision (not changed): the CLIs under commands/ default
EGERIA_USER_PASSWORD to "secret" in 79 live places, plus 2 fallbacks in
egeria_login_tui and 1 in my_reports.

Tests: 15 passed, both env ways.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…s (PY-37 notice)

New docs/setting-your-egeria-password.md:
- what changes: the library has no built-in password now; pyegeria 6.4
  removes the CLIs' demo-password fallback;
- the message you'll see, and the exception type change for code that
  caught the old 401;
- where pyegeria looks for the password, in the order the code reads it:
  an explicit --password / --user_pass / user_pwd=, EGERIA_USER_PASSWORD,
  config.json "User Profile" user_pwd, then a .env file;
- how to set it: per shell, .env (chmod 600, gitignored), config.json, a
  single command, and in code (os.environ[...], never a literal fallback);
- servers use their own service account and never set EGERIA_USER*.

Linked from the README, user_programming.md, the hey_egeria and Visual
Command Reference READMEs, and the release notes.

- release-notes/next.md: the Planned-for-6.4 item now names the CLI
  change; a Changed item records PY-33/PY-35 and the 401 to
  PyegeriaInvalidParameterException change.
- hey_egeria README: fixes my earlier row, which said EGERIA_USER_PASSWORD
  has no default. The CLIs still fall back to the demo password until 6.4.
  Adds a notice above the table.
- dr_egeria_manual.md: its 4 Python samples read
  os.environ["EGERIA_USER_PASSWORD"] instead of a "secret" fallback.

Dan, 2026-11-18: the CLI defaults "wait for 6.4", but add documentation
around the impending change and how people should set it.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…sions (read-back R1, R2, W1-W3)

1286564 said the CLIs read the password like the library. They don't.
egeria.py and the other CLIs compute --password's default as
os.environ.get("EGERIA_USER_PASSWORD", <demo>) and pass it explicitly, so
until 6.4 config.json and .env are never consulted for a CLI. A password
set only there isn't used, and the CLI still signs in with the demo
password.

setting-your-egeria-password.md:
- R1: the precedence is split by tool. The library uses user_pwd=, then
  EGERIA_USER_PASSWORD, then config.json, then .env. The CLIs until 6.4
  use --password / --user_pass, then EGERIA_USER_PASSWORD, then the demo
  password. "Set it now" means the environment variable, the one route
  that works in both.
- R2: the table's columns are pyegeria 6.3.0 / the next release / 6.4,
  since 6.3.0 still has the library's demo fallback and PY-33 ships in
  the next release.
- W1: .env is read from the directory you run from (or with_env_file),
  not PYEGERIA_ROOT_PATH.
- W2: an EGERIA_USER_PASSWORD that is set but empty counts as set, so
  pyegeria looks no further and sign-in is refused.
- W3: --password is described only for a single command, with the
  shell-history caution.

release-notes/next.md: the 6.4 item says what the CLIs read until then,
and tells people to set the environment variable. The Changed item says
"from this release".

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
…private (6.3.1 read-back)

The password page offered config.json's "user_pwd" with no caution, while .env got "chmod 600 + .gitignore".
Dan's rule (2026-11-18): credentials may come from a git-ignored config.json, never a committed one. The page
now says so: only a git-ignored config.json readable only by you; never commit it; use .env or the environment
variable if yours is tracked.

Signed-off-by: Dan Wolfson <dan.wolfson@pdr-associates.com>
@dwolfson
dwolfson merged commit b4beb91 into odpi:main Nov 18, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant