Script 'mail_helper' called by obssrc
Hello community,

here is the log from the commit of package python-hatch_nodejs_version for 
openSUSE:Factory checked in at 2023-12-08 22:32:07
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-hatch_nodejs_version (Old)
 and      /work/SRC/openSUSE:Factory/.python-hatch_nodejs_version.new.25432 
(New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-hatch_nodejs_version"

Fri Dec  8 22:32:07 2023 rev:4 rq:1131732 version:0.3.2

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-hatch_nodejs_version/python-hatch_nodejs_version.changes
  2023-02-07 18:49:36.883302470 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-hatch_nodejs_version.new.25432/python-hatch_nodejs_version.changes
       2023-12-08 22:32:38.613302684 +0100
@@ -1,0 +2,7 @@
+Thu Dec  7 22:33:44 UTC 2023 - Dirk Müller <[email protected]>
+
+- update to 0.3.2:
+  * Add a trailing newline to package.json when appropriate #17
+  * Assume NPM person can be string #20 (@vikramaditya91)
+
+-------------------------------------------------------------------

Old:
----
  hatch_nodejs_version-0.3.1.tar.gz

New:
----
  hatch_nodejs_version-0.3.2.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-hatch_nodejs_version.spec ++++++
--- /var/tmp/diff_new_pack.KflbJ4/_old  2023-12-08 22:32:39.141322111 +0100
+++ /var/tmp/diff_new_pack.KflbJ4/_new  2023-12-08 22:32:39.145322259 +0100
@@ -17,7 +17,7 @@
 
 
 Name:           python-hatch_nodejs_version
-Version:        0.3.1
+Version:        0.3.2
 Release:        0
 Summary:        This package provides two Hatch plugins for nodejs
 License:        MIT

++++++ hatch_nodejs_version-0.3.1.tar.gz -> hatch_nodejs_version-0.3.2.tar.gz 
++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/.github/workflows/check-release.yml 
new/hatch_nodejs_version-0.3.2/.github/workflows/check-release.yml
--- old/hatch_nodejs_version-0.3.1/.github/workflows/check-release.yml  
1970-01-01 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/.github/workflows/check-release.yml  
2020-02-02 01:00:00.000000000 +0100
@@ -0,0 +1,29 @@
+name: Check Release
+on:
+  push:
+    branches: ["main"]
+  pull_request:
+    branches: ["*"]
+
+jobs:
+  check_release:
+    runs-on: ubuntu-latest
+    steps:
+      - name: Checkout
+        uses: actions/checkout@v3
+      - name: Base Setup
+        uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
+      - name: Install Dependencies
+        run: |
+          pip install -e .
+      - name: Check Release
+        uses: jupyter-server/jupyter_releaser/.github/actions/check-release@v2
+        with:
+
+          token: ${{ secrets.GITHUB_TOKEN }}
+
+      - name: Upload Distributions
+        uses: actions/upload-artifact@v3
+        with:
+          name: jupyterlab_myst-releaser-dist-${{ github.run_number }}
+          path: .jupyter_releaser_checkout/dist
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/.github/workflows/enforce-label.yml 
new/hatch_nodejs_version-0.3.2/.github/workflows/enforce-label.yml
--- old/hatch_nodejs_version-0.3.1/.github/workflows/enforce-label.yml  
1970-01-01 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/.github/workflows/enforce-label.yml  
2020-02-02 01:00:00.000000000 +0100
@@ -0,0 +1,13 @@
+name: Enforce PR label
+
+on:
+  pull_request:
+    types: [labeled, unlabeled, opened, edited, synchronize]
+jobs:
+  enforce-label:
+    runs-on: ubuntu-latest
+    permissions:
+      pull-requests: write
+    steps:
+      - name: enforce-triage-label
+        uses: jupyterlab/maintainer-tools/.github/actions/enforce-label@v1
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/.github/workflows/full-release.yml 
new/hatch_nodejs_version-0.3.2/.github/workflows/full-release.yml
--- old/hatch_nodejs_version-0.3.1/.github/workflows/full-release.yml   
1970-01-01 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/.github/workflows/full-release.yml   
2020-02-02 01:00:00.000000000 +0100
@@ -0,0 +1,66 @@
+name: "Steps 1 + 2: Full Release"
+on:
+  workflow_dispatch:
+    inputs:
+      version_spec:
+        description: "New Version Specifier"
+        default: "next"
+        required: false
+      branch:
+        description: "The branch to target"
+        required: false
+      post_version_spec:
+        description: "Post Version Specifier"
+        required: false
+      since:
+        description: "Use PRs with activity since this date or git reference"
+        required: false
+      since_last_stable:
+        description: "Use PRs with activity since the last stable git tag"
+        required: false
+        type: boolean
+      steps_to_skip:
+        description: "Comma separated list of steps to skip during Populate 
Release"
+        required: false
+jobs:
+  full_release:
+    runs-on: ubuntu-latest
+    permissions:
+      # This is useful if you want to use PyPI trusted publisher
+      # and NPM provenance
+      id-token: write
+    steps:
+      - uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
+
+      - name: Prep Release
+        id: prep-release
+        uses: jupyter-server/jupyter_releaser/.github/actions/prep-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          version_spec: ${{ github.event.inputs.version_spec }}
+          post_version_spec: ${{ github.event.inputs.post_version_spec }}
+          branch: ${{ github.event.inputs.branch }}
+          since: ${{ github.event.inputs.since }}
+          since_last_stable: ${{ github.event.inputs.since_last_stable }}
+
+      - name: Populate Release
+        id: populate-release
+        uses: 
jupyter-server/jupyter_releaser/.github/actions/populate-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          branch: ${{ github.event.inputs.branch }}
+          release_url: ${{ steps.prep-release.outputs.release_url }}
+          steps_to_skip: ${{ github.event.inputs.steps_to_skip }}
+
+      - name: Finalize Release
+        id: finalize-release
+        uses: 
jupyter-server/jupyter-releaser/.github/actions/finalize-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          release_url: ${{ steps.populate-release.outputs.release_url }}
+
+      - name: "** Next Step **"
+        if: ${{ success() }}
+        run: |
+          echo "Verify the final release"
+          echo ${{ steps.finalize-release.outputs.release_url }}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/.github/workflows/prep-release.yml 
new/hatch_nodejs_version-0.3.2/.github/workflows/prep-release.yml
--- old/hatch_nodejs_version-0.3.1/.github/workflows/prep-release.yml   
1970-01-01 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/.github/workflows/prep-release.yml   
2020-02-02 01:00:00.000000000 +0100
@@ -0,0 +1,41 @@
+name: "Step 1: Prep Release"
+on:
+  workflow_dispatch:
+    inputs:
+      version_spec:
+        description: "New Version Specifier"
+        default: "next"
+        required: false
+      branch:
+        description: "The branch to target"
+        required: false
+      post_version_spec:
+        description: "Post Version Specifier"
+        required: false
+      since:
+        description: "Use PRs with activity since this date or git reference"
+        required: false
+      since_last_stable:
+        description: "Use PRs with activity since the last stable git tag"
+        required: false
+        type: boolean
+jobs:
+  prep_release:
+    runs-on: ubuntu-latest
+    steps:
+      - uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
+
+      - name: Prep Release
+        id: prep-release
+        uses: jupyter-server/jupyter_releaser/.github/actions/prep-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          version_spec: ${{ github.event.inputs.version_spec }}
+          post_version_spec: ${{ github.event.inputs.post_version_spec }}
+          branch: ${{ github.event.inputs.branch }}
+          since: ${{ github.event.inputs.since }}
+          since_last_stable: ${{ github.event.inputs.since_last_stable }}
+
+      - name: "** Next Step **"
+        run: |
+          echo "Optional): Review Draft Release: ${{ 
steps.prep-release.outputs.release_url }}"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/.github/workflows/publish-release.yml 
new/hatch_nodejs_version-0.3.2/.github/workflows/publish-release.yml
--- old/hatch_nodejs_version-0.3.1/.github/workflows/publish-release.yml        
1970-01-01 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/.github/workflows/publish-release.yml        
2020-02-02 01:00:00.000000000 +0100
@@ -0,0 +1,51 @@
+name: "Step 2: Publish Release"
+on:
+  workflow_dispatch:
+    inputs:
+      branch:
+        description: "The target branch"
+        required: false
+      release_url:
+        description: "The URL of the draft GitHub release"
+        required: false
+      steps_to_skip:
+        description: "Comma separated list of steps to skip"
+        required: false
+
+jobs:
+  publish_release:
+    runs-on: ubuntu-latest
+    permissions:
+      # This is useful if you want to use PyPI trusted publisher
+      # and NPM provenance
+      id-token: write
+    steps:
+      - uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1
+
+      - name: Populate Release
+        id: populate-release
+        uses: 
jupyter-server/jupyter_releaser/.github/actions/populate-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          branch: ${{ github.event.inputs.branch }}
+          release_url: ${{ github.event.inputs.release_url }}
+          steps_to_skip: ${{ github.event.inputs.steps_to_skip }}
+
+      - name: Finalize Release
+        id: finalize-release
+        uses: 
jupyter-server/jupyter-releaser/.github/actions/finalize-release@v2
+        with:
+          token: ${{ secrets.ADMIN_GITHUB_TOKEN }}
+          release_url: ${{ steps.populate-release.outputs.release_url }}
+
+      - name: "** Next Step **"
+        if: ${{ success() }}
+        run: |
+          echo "Verify the final release"
+          echo ${{ steps.finalize-release.outputs.release_url }}
+
+      - name: "** Failure Message **"
+        if: ${{ failure() }}
+        run: |
+          echo "Failed to Publish the Draft Release Url:"
+          echo ${{ steps.populate-release.outputs.release_url }}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/hatch_nodejs_version-0.3.1/CHANGELOG.md 
new/hatch_nodejs_version-0.3.2/CHANGELOG.md
--- old/hatch_nodejs_version-0.3.1/CHANGELOG.md 1970-01-01 01:00:00.000000000 
+0100
+++ new/hatch_nodejs_version-0.3.2/CHANGELOG.md 2020-02-02 01:00:00.000000000 
+0100
@@ -0,0 +1,23 @@
+# Changelog
+
+<!-- <START NEW CHANGELOG ENTRY> -->
+
+## 0.3.2
+
+([Full 
Changelog](https://github.com/agoose77/hatch-nodejs-version/compare/v0.3.0...4d3c73d2f4e5ac927274dc810351bc0be95ef224))
+
+### Bugs fixed
+
+- Add a trailing newline to package.json when appropriate 
[#17](https://github.com/agoose77/hatch-nodejs-version/pull/17) 
([@blink1073](https://github.com/blink1073))
+
+### Other merged PRs
+
+- Assume NPM person can be string 
[#20](https://github.com/agoose77/hatch-nodejs-version/pull/20) 
([@vikramaditya91](https://github.com/vikramaditya91))
+
+### Contributors to this release
+
+([GitHub contributors page for this 
release](https://github.com/agoose77/hatch-nodejs-version/graphs/contributors?from=2022-09-21&to=2023-09-06&type=c))
+
+[@agoose77](https://github.com/search?q=repo%3Aagoose77%2Fhatch-nodejs-version+involves%3Aagoose77+updated%3A2022-09-21..2023-09-06&type=Issues)
 | 
[@blink1073](https://github.com/search?q=repo%3Aagoose77%2Fhatch-nodejs-version+involves%3Ablink1073+updated%3A2022-09-21..2023-09-06&type=Issues)
 | 
[@vikramaditya91](https://github.com/search?q=repo%3Aagoose77%2Fhatch-nodejs-version+involves%3Avikramaditya91+updated%3A2022-09-21..2023-09-06&type=Issues)
+
+<!-- <END NEW CHANGELOG ENTRY> -->
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/hatch_nodejs_version-0.3.1/PKG-INFO 
new/hatch_nodejs_version-0.3.2/PKG-INFO
--- old/hatch_nodejs_version-0.3.1/PKG-INFO     2020-02-02 01:00:00.000000000 
+0100
+++ new/hatch_nodejs_version-0.3.2/PKG-INFO     2020-02-02 01:00:00.000000000 
+0100
@@ -1,6 +1,6 @@
 Metadata-Version: 2.1
 Name: hatch-nodejs-version
-Version: 0.3.1
+Version: 0.3.2
 Summary: Hatch plugin for versioning from a package.json file
 Project-URL: Homepage, https://github.com/agoose77/hatch-nodejs-version
 Project-URL: Issue Tracker, 
https://github.com/agoose77/hatch-nodejs-version/issues
@@ -88,7 +88,7 @@
 - `post-release`
 - `dev-release`
 
-In order to ensure round-trip support, and ensure semantic consistency between 
Node.js and Python, this plugin only
+In order to ensure contentful round-trip support, and ensure semantic 
consistency between Node.js and Python, this plugin only
 accepts the common version parts:
 
 - `major`
@@ -98,6 +98,9 @@
 
 e.g. `1.2.3-rc0`.
 
+Note that where normalisation occurs, the round-trip result will differ. This 
can be avoided by careful choice of the delimeters e.g. `-.`.
+
+
 ### Version source options
 
 | Option        | Type | Default       | Description                           
     |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/hatch_nodejs_version-0.3.1/README.md 
new/hatch_nodejs_version-0.3.2/README.md
--- old/hatch_nodejs_version-0.3.1/README.md    2020-02-02 01:00:00.000000000 
+0100
+++ new/hatch_nodejs_version-0.3.2/README.md    2020-02-02 01:00:00.000000000 
+0100
@@ -68,7 +68,7 @@
 - `post-release`
 - `dev-release`
 
-In order to ensure round-trip support, and ensure semantic consistency between 
Node.js and Python, this plugin only
+In order to ensure contentful round-trip support, and ensure semantic 
consistency between Node.js and Python, this plugin only
 accepts the common version parts:
 
 - `major`
@@ -78,6 +78,9 @@
 
 e.g. `1.2.3-rc0`.
 
+Note that where normalisation occurs, the round-trip result will differ. This 
can be avoided by careful choice of the delimeters e.g. `-.`.
+
+
 ### Version source options
 
 | Option        | Type | Default       | Description                           
     |
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/hatch_nodejs_version-0.3.1/RELEASE.md 
new/hatch_nodejs_version-0.3.2/RELEASE.md
--- old/hatch_nodejs_version-0.3.1/RELEASE.md   1970-01-01 01:00:00.000000000 
+0100
+++ new/hatch_nodejs_version-0.3.2/RELEASE.md   2020-02-02 01:00:00.000000000 
+0100
@@ -0,0 +1,65 @@
+# Making a new release of jupyterlab_myst
+
+The extension can be published to `PyPI` and `npm` manually or using the 
[Jupyter Releaser](https://github.com/jupyter-server/jupyter_releaser).
+
+## Manual release
+
+### Python package
+
+This extension can be distributed as Python packages. All of the Python
+packaging instructions are in the `pyproject.toml` file to wrap your extension 
in a
+Python package. Before generating a package, you first need to install some 
tools:
+
+```bash
+pip install build twine hatch
+```
+
+Bump the version using `hatch`. By default this will create a tag.
+See the docs on 
[hatch-nodejs-version](https://github.com/agoose77/hatch-nodejs-version#semver) 
for details.
+
+```bash
+hatch version <new-version>
+```
+
+To create a Python source package (`.tar.gz`) and the binary package (`.whl`) 
in the `dist/` directory, do:
+
+```bash
+python -m build
+```
+
+> `python setup.py sdist bdist_wheel` is deprecated and will not work for this 
package.
+
+Then to upload the package to PyPI, do:
+
+```bash
+twine upload dist/*
+```
+
+### NPM package
+
+To publish the frontend part of the extension as a NPM package, do:
+
+```bash
+npm login
+npm publish --access public
+```
+
+## Automated releases with the Jupyter Releaser
+
+The extension repository should already be compatible with the Jupyter 
Releaser.
+
+Check out the [workflow 
documentation](https://jupyter-releaser.readthedocs.io/en/latest/get_started/making_release_from_repo.html)
 for more information.
+
+Here is a summary of the steps to cut a new release:
+
+- Add `ADMIN_GITHUB_TOKEN`, `PYPI_TOKEN` and `NPM_TOKEN` to the [Github 
Secrets](https://docs.github.com/en/actions/security-guides/encrypted-secrets) 
in the repository
+- Go to the Actions panel
+- Run the "Step 1: Prep Release" workflow
+- Check the draft changelog
+- Run the "Step 2: Publish Release" workflow
+
+## Publishing to `conda-forge`
+
+If the package is not on conda forge yet, check the documentation to learn how 
to add it: https://conda-forge.org/docs/maintainer/adding_pkgs.html
+
+Otherwise a bot should pick up the new version publish to PyPI, and open a new 
PR on the feedstock repository automatically.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-project
 
new/hatch_nodejs_version-0.3.2/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-project
--- 
old/hatch_nodejs_version-0.3.1/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-project
        2020-02-02 01:00:00.000000000 +0100
+++ 
new/hatch_nodejs_version-0.3.2/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-project
        1970-01-01 01:00:00.000000000 +0100
@@ -1 +0,0 @@
-{"folders":[{"path": "."}]}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-workspace
 
new/hatch_nodejs_version-0.3.2/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-workspace
--- 
old/hatch_nodejs_version-0.3.1/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-workspace
      2020-02-02 01:00:00.000000000 +0100
+++ 
new/hatch_nodejs_version-0.3.2/hatch-nodejs-version-9ee3546c1288b1f063220757.sublime-workspace
      1970-01-01 01:00:00.000000000 +0100
@@ -1 +0,0 @@
-{}
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/hatch_nodejs_version/_version.py 
new/hatch_nodejs_version-0.3.2/hatch_nodejs_version/_version.py
--- old/hatch_nodejs_version-0.3.1/hatch_nodejs_version/_version.py     
2020-02-02 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/hatch_nodejs_version/_version.py     
2020-02-02 01:00:00.000000000 +0100
@@ -1,4 +1,4 @@
 # SPDX-FileCopyrightText: 2022-present Angus Hollands <[email protected]>
 #
 # SPDX-License-Identifier: MIT
-__version__ = "0.3.1"
+__version__ = "0.3.2"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/hatch_nodejs_version/metadata_source.py 
new/hatch_nodejs_version-0.3.2/hatch_nodejs_version/metadata_source.py
--- old/hatch_nodejs_version-0.3.1/hatch_nodejs_version/metadata_source.py      
2020-02-02 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/hatch_nodejs_version/metadata_source.py      
2020-02-02 01:00:00.000000000 +0100
@@ -7,11 +7,11 @@
 import os.path
 import re
 import urllib.parse
-from typing import Any
+from typing import Any, Union
 
 from hatchling.metadata.plugin.interface import MetadataHookInterface
 
-AUTHOR_PATTERN = r"^([^<(]+?)?[ \t]*(?:<([^>(]+?)>)?[ \t]*(?:\(([^)]+?)\)|$)"
+AUTHOR_PATTERN = r"^(?P<name>[^<(]+?)?[ \t]*(?:<(?P<email>[^>(]+?)>)?[ 
\t]*(?:\((?P<url>[^)]+?)\)|$)"
 REPOSITORY_PATTERN = r"^(?:(gist|bitbucket|gitlab|github):)?(.*?)$"
 REPOSITORY_TABLE = {
     "gitlab": "https://gitlab.com";,
@@ -137,19 +137,24 @@
         return bugs["url"]
 
     def _parse_person(self, person: dict[str, str]) -> dict[str, str]:
-        if {"url", "email"} & person.keys():
-            result = {"name": person["name"]}
-            if "email" in person:
-                result["email"] = person["email"]
+        result = {}
+        if isinstance(person, dict):
+            if {"url", "email"} & person.keys():
+                result["name"] = person["name"]
+                if "email" in person:
+                    result["email"] = person["email"]
+                return result
+            else:
+                author = person["name"]
         else:
-            match = re.match(AUTHOR_PATTERN, person["name"])
-            if match is None:
-                raise ValueError(f"Invalid author name: {person['name']}")
-            name, email, _ = match.groups()
-            result = {"name": name}
-            if email is not None:
-                result["email"] = email
-
+            author = person
+        match = re.match(AUTHOR_PATTERN, author)
+        if match is None:
+            raise ValueError(f"Invalid author name: {author}")
+        name, email, _ = match.groups()
+        result = {"name": name}
+        if email is not None:
+            result["email"] = email
         return result
 
     def _parse_repository(self, repository: str | dict[str, str]) -> str:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/hatch_nodejs_version-0.3.1/pyrightconfig.json 
new/hatch_nodejs_version-0.3.2/pyrightconfig.json
--- old/hatch_nodejs_version-0.3.1/pyrightconfig.json   2020-02-02 
01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/pyrightconfig.json   1970-01-01 
01:00:00.000000000 +0100
@@ -1 +0,0 @@
-{"venvPath":"/Users/steve.silvester/workspace/.venvs","venv": 
"hatch-nodejs-version-9ee3546c1288b1f063220757"}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/hatch_nodejs_version-0.3.1/tests/test_metadata_config.py 
new/hatch_nodejs_version-0.3.2/tests/test_metadata_config.py
--- old/hatch_nodejs_version-0.3.1/tests/test_metadata_config.py        
2020-02-02 01:00:00.000000000 +0100
+++ new/hatch_nodejs_version-0.3.2/tests/test_metadata_config.py        
2020-02-02 01:00:00.000000000 +0100
@@ -2,6 +2,7 @@
 #
 # SPDX-License-Identifier: MIT
 import pytest
+import json
 
 from hatch_nodejs_version.metadata_source import NodeJSMetadataHook
 
@@ -165,3 +166,19 @@
         assert urls["the-repository"] == "https://github.com/some/code.git";
         assert urls["the-bug-tracker"] == "https://www.send-help.com";
         assert urls["the-homepage"] == "https://where-the-heart-is.com";
+
+    def test_authors_accepted_as_strings(self, project):
+        original_package_content = json.loads(TRIVIAL_PACKAGE_CONTENTS)
+        updated_package_content = original_package_content.copy()
+        author_as_string = f"{original_package_content['author']['name']} " \
+                           f"<{original_package_content['author']['email']}>"
+        updated_package_content['author'] = author_as_string
+        (project / "pyproject.toml").write_text(TRIVIAL_PYPROJECT_CONTENTS)
+        (project / 
"package.json").write_text(json.dumps(updated_package_content))
+
+        config = {}
+        metadata = {}
+        metadata_source = NodeJSMetadataHook(project, config=config)
+        metadata_source.update(metadata)
+        assert metadata == TRIVIAL_EXPECTED_METADATA
+

Reply via email to