microsoft-kiota-serialization-form 0.1.0__tar.gz
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.
- microsoft_kiota_serialization_form-0.1.0/.github/CODEOWNERS +1 -0
- microsoft_kiota_serialization_form-0.1.0/.github/ISSUE_TEMPLATE/bug_report.md +30 -0
- microsoft_kiota_serialization_form-0.1.0/.github/ISSUE_TEMPLATE/feature_request.md +20 -0
- microsoft_kiota_serialization_form-0.1.0/.github/dependabot.yml +12 -0
- microsoft_kiota_serialization_form-0.1.0/.github/policies/resourceManagement.yml +101 -0
- microsoft_kiota_serialization_form-0.1.0/.github/pull_request_template.md +23 -0
- microsoft_kiota_serialization_form-0.1.0/.github/workflows/auto-merge-dependabot.yml +32 -0
- microsoft_kiota_serialization_form-0.1.0/.github/workflows/build.yml +42 -0
- microsoft_kiota_serialization_form-0.1.0/.github/workflows/codeql-analysis.yml +70 -0
- microsoft_kiota_serialization_form-0.1.0/.github/workflows/conflicting-pr-label.yml +38 -0
- microsoft_kiota_serialization_form-0.1.0/.github/workflows/publish.yml +50 -0
- microsoft_kiota_serialization_form-0.1.0/.gitignore +350 -0
- microsoft_kiota_serialization_form-0.1.0/.pylintrc +519 -0
- microsoft_kiota_serialization_form-0.1.0/CHANGELOG.md +20 -0
- microsoft_kiota_serialization_form-0.1.0/CODE_OF_CONDUCT.md +9 -0
- microsoft_kiota_serialization_form-0.1.0/LICENSE +21 -0
- microsoft_kiota_serialization_form-0.1.0/PKG-INFO +60 -0
- microsoft_kiota_serialization_form-0.1.0/README.md +40 -0
- microsoft_kiota_serialization_form-0.1.0/SECURITY.md +41 -0
- microsoft_kiota_serialization_form-0.1.0/SUPPORT.md +25 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/__init__.py +6 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/_version.py +1 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/form_parse_node.py +348 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/form_parse_node_factory.py +35 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/form_serialization_writer.py +349 -0
- microsoft_kiota_serialization_form-0.1.0/kiota_serialization_form/form_serialization_writer_factory.py +30 -0
- microsoft_kiota_serialization_form-0.1.0/pyproject.toml +46 -0
- microsoft_kiota_serialization_form-0.1.0/requirements-dev.txt +22 -0
- microsoft_kiota_serialization_form-0.1.0/tests/__init__.py +0 -0
- microsoft_kiota_serialization_form-0.1.0/tests/helpers/__init__.py +2 -0
- microsoft_kiota_serialization_form-0.1.0/tests/helpers/test_entity.py +83 -0
- microsoft_kiota_serialization_form-0.1.0/tests/helpers/test_enum.py +10 -0
- microsoft_kiota_serialization_form-0.1.0/tests/unit/__init__.py +0 -0
- microsoft_kiota_serialization_form-0.1.0/tests/unit/test_form_parse_node.py +182 -0
- microsoft_kiota_serialization_form-0.1.0/tests/unit/test_form_parse_node_factory.py +48 -0
- microsoft_kiota_serialization_form-0.1.0/tests/unit/test_form_serialization_writer.py +193 -0
- microsoft_kiota_serialization_form-0.1.0/tests/unit/test_form_serialization_writer_factory.py +32 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
* @microsoft/kiota-write
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Bug report
|
|
3
|
+
about: Create a report to help us improve
|
|
4
|
+
title: ""
|
|
5
|
+
labels: bug
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
**Environment**
|
|
9
|
+
|
|
10
|
+
- Python Version
|
|
11
|
+
- kiota-serialization-form version:
|
|
12
|
+
- OS:
|
|
13
|
+
|
|
14
|
+
**Stack trace (if available)**
|
|
15
|
+
Screenshot or `formatted` copy and paste of your stack trace.
|
|
16
|
+
|
|
17
|
+
**Describe the bug**
|
|
18
|
+
A clear and concise description of what the bug is.
|
|
19
|
+
|
|
20
|
+
**To Reproduce**
|
|
21
|
+
Steps to reproduce the behavior:
|
|
22
|
+
|
|
23
|
+
**Expected behavior**
|
|
24
|
+
A clear and concise description of what you expected to happen.
|
|
25
|
+
|
|
26
|
+
**Screenshots**
|
|
27
|
+
If applicable, add screenshots to help explain your problem.
|
|
28
|
+
|
|
29
|
+
**Additional context**
|
|
30
|
+
Add any other context about the problem here.
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: Feature request
|
|
3
|
+
about: Suggest a feature for this project
|
|
4
|
+
title: ''
|
|
5
|
+
labels: enhancement
|
|
6
|
+
assignees: ''
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
**Is your feature request related to a problem? Please describe.**
|
|
11
|
+
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
|
12
|
+
|
|
13
|
+
**Describe the solution you'd like**
|
|
14
|
+
A clear and concise description of what you want to happen.
|
|
15
|
+
|
|
16
|
+
**Describe alternatives you've considered**
|
|
17
|
+
A clear and concise description of any alternative solutions or features you've considered.
|
|
18
|
+
|
|
19
|
+
**Additional context**
|
|
20
|
+
Add any other context or screenshots about the feature request here.
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
id:
|
|
2
|
+
name: GitOps.PullRequestIssueManagement
|
|
3
|
+
description: GitOps.PullRequestIssueManagement primitive
|
|
4
|
+
owner:
|
|
5
|
+
resource: repository
|
|
6
|
+
disabled: false
|
|
7
|
+
where:
|
|
8
|
+
configuration:
|
|
9
|
+
resourceManagementConfiguration:
|
|
10
|
+
scheduledSearches:
|
|
11
|
+
- description:
|
|
12
|
+
frequencies:
|
|
13
|
+
- hourly:
|
|
14
|
+
hour: 6
|
|
15
|
+
filters:
|
|
16
|
+
- isIssue
|
|
17
|
+
- isOpen
|
|
18
|
+
- hasLabel:
|
|
19
|
+
label: 'Needs: Author Feedback'
|
|
20
|
+
- hasLabel:
|
|
21
|
+
label: 'Status: No Recent Activity'
|
|
22
|
+
- noActivitySince:
|
|
23
|
+
days: 3
|
|
24
|
+
actions:
|
|
25
|
+
- closeIssue
|
|
26
|
+
- description:
|
|
27
|
+
frequencies:
|
|
28
|
+
- hourly:
|
|
29
|
+
hour: 6
|
|
30
|
+
filters:
|
|
31
|
+
- isIssue
|
|
32
|
+
- isOpen
|
|
33
|
+
- hasLabel:
|
|
34
|
+
label: 'Needs: Author Feedback'
|
|
35
|
+
- noActivitySince:
|
|
36
|
+
days: 4
|
|
37
|
+
- isNotLabeledWith:
|
|
38
|
+
label: 'Status: No Recent Activity'
|
|
39
|
+
actions:
|
|
40
|
+
- addLabel:
|
|
41
|
+
label: 'Status: No Recent Activity'
|
|
42
|
+
- addReply:
|
|
43
|
+
reply: This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for **4 days**. It will be closed if no further activity occurs **within 3 days of this comment**.
|
|
44
|
+
- description:
|
|
45
|
+
frequencies:
|
|
46
|
+
- hourly:
|
|
47
|
+
hour: 6
|
|
48
|
+
filters:
|
|
49
|
+
- isIssue
|
|
50
|
+
- isOpen
|
|
51
|
+
- hasLabel:
|
|
52
|
+
label: 'Resolution: Duplicate'
|
|
53
|
+
- noActivitySince:
|
|
54
|
+
days: 1
|
|
55
|
+
actions:
|
|
56
|
+
- addReply:
|
|
57
|
+
reply: This issue has been marked as duplicate and has not had any activity for **1 day**. It will be closed for housekeeping purposes.
|
|
58
|
+
- closeIssue
|
|
59
|
+
eventResponderTasks:
|
|
60
|
+
- if:
|
|
61
|
+
- payloadType: Issue_Comment
|
|
62
|
+
- isAction:
|
|
63
|
+
action: Created
|
|
64
|
+
- isActivitySender:
|
|
65
|
+
issueAuthor: True
|
|
66
|
+
- hasLabel:
|
|
67
|
+
label: 'Needs: Author Feedback'
|
|
68
|
+
- isOpen
|
|
69
|
+
then:
|
|
70
|
+
- addLabel:
|
|
71
|
+
label: 'Needs: Attention :wave:'
|
|
72
|
+
- removeLabel:
|
|
73
|
+
label: 'Needs: Author Feedback'
|
|
74
|
+
description:
|
|
75
|
+
- if:
|
|
76
|
+
- payloadType: Issues
|
|
77
|
+
- not:
|
|
78
|
+
isAction:
|
|
79
|
+
action: Closed
|
|
80
|
+
- hasLabel:
|
|
81
|
+
label: 'Status: No Recent Activity'
|
|
82
|
+
then:
|
|
83
|
+
- removeLabel:
|
|
84
|
+
label: 'Status: No Recent Activity'
|
|
85
|
+
description:
|
|
86
|
+
- if:
|
|
87
|
+
- payloadType: Issue_Comment
|
|
88
|
+
- hasLabel:
|
|
89
|
+
label: 'Status: No Recent Activity'
|
|
90
|
+
then:
|
|
91
|
+
- removeLabel:
|
|
92
|
+
label: 'Status: No Recent Activity'
|
|
93
|
+
description:
|
|
94
|
+
- if:
|
|
95
|
+
- payloadType: Pull_Request
|
|
96
|
+
then:
|
|
97
|
+
- inPrLabel:
|
|
98
|
+
label: WIP
|
|
99
|
+
description:
|
|
100
|
+
onFailure:
|
|
101
|
+
onSuccess:
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
## Overview
|
|
2
|
+
|
|
3
|
+
Brief description of what this PR does, and why it is needed.
|
|
4
|
+
|
|
5
|
+
## Related Issue
|
|
6
|
+
|
|
7
|
+
Fixes # (issue)
|
|
8
|
+
|
|
9
|
+
### Demo
|
|
10
|
+
|
|
11
|
+
Optional. Screenshots, `curl` examples, etc.
|
|
12
|
+
|
|
13
|
+
### Notes
|
|
14
|
+
|
|
15
|
+
Optional. Ancillary topics, caveats, alternative strategies that didn't work out, anything else.
|
|
16
|
+
|
|
17
|
+
## Testing Instructions
|
|
18
|
+
|
|
19
|
+
* How to test this PR
|
|
20
|
+
* Prefer bulleted description
|
|
21
|
+
* Start after checking out this branch
|
|
22
|
+
* Include any setup required, such as bundling scripts, restarting services, etc.
|
|
23
|
+
* Include test case, and expected output
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
name: Auto-merge dependabot updates
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
branches: [ main ]
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
pull-requests: write
|
|
9
|
+
contents: write
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
|
|
13
|
+
dependabot-merge:
|
|
14
|
+
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
|
|
17
|
+
if: ${{ github.actor == 'dependabot[bot]' }}
|
|
18
|
+
|
|
19
|
+
steps:
|
|
20
|
+
- name: Dependabot metadata
|
|
21
|
+
id: metadata
|
|
22
|
+
uses: dependabot/fetch-metadata@v1.6.0
|
|
23
|
+
with:
|
|
24
|
+
github-token: "${{ secrets.GITHUB_TOKEN }}"
|
|
25
|
+
|
|
26
|
+
- name: Enable auto-merge for Dependabot PRs
|
|
27
|
+
# Only if version bump is not a major version change
|
|
28
|
+
if: ${{steps.metadata.outputs.update-type != 'version-update:semver-major'}}
|
|
29
|
+
run: gh pr merge --auto --merge "$PR_URL"
|
|
30
|
+
env:
|
|
31
|
+
PR_URL: ${{github.event.pull_request.html_url}}
|
|
32
|
+
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
name: Python Serialization Form
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
workflow_call:
|
|
6
|
+
push:
|
|
7
|
+
branches: [main]
|
|
8
|
+
pull_request:
|
|
9
|
+
branches: [main]
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
build:
|
|
13
|
+
runs-on: ubuntu-latest
|
|
14
|
+
strategy:
|
|
15
|
+
matrix:
|
|
16
|
+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
|
|
17
|
+
steps:
|
|
18
|
+
- name: Checkout
|
|
19
|
+
uses: actions/checkout@v4
|
|
20
|
+
- name: Set up Python ${{ matrix.python-version }}
|
|
21
|
+
uses: actions/setup-python@v5
|
|
22
|
+
with:
|
|
23
|
+
python-version: ${{ matrix.python-version }}
|
|
24
|
+
- name: Install dependencies
|
|
25
|
+
run: |
|
|
26
|
+
python -m pip install --upgrade pip
|
|
27
|
+
pip install -r requirements-dev.txt
|
|
28
|
+
- name: Check code format
|
|
29
|
+
run: |
|
|
30
|
+
yapf -dr kiota_serialization_form
|
|
31
|
+
- name: Check import order
|
|
32
|
+
run: |
|
|
33
|
+
isort kiota_serialization_form
|
|
34
|
+
- name: Lint with Pylint
|
|
35
|
+
run: |
|
|
36
|
+
pylint kiota_serialization_form --disable=W --rcfile=.pylintrc
|
|
37
|
+
- name: Static type checking with Mypy
|
|
38
|
+
run: |
|
|
39
|
+
mypy kiota_serialization_form
|
|
40
|
+
- name: Run tests with Pytest
|
|
41
|
+
run: |
|
|
42
|
+
pytest
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# For most projects, this workflow file will not need changing; you simply need
|
|
2
|
+
# to commit it to your repository.
|
|
3
|
+
#
|
|
4
|
+
# You may wish to alter this file to override the set of languages analyzed,
|
|
5
|
+
# or to provide custom queries or build logic.
|
|
6
|
+
#
|
|
7
|
+
# ******** NOTE ********
|
|
8
|
+
# We have attempted to detect the languages in your repository. Please check
|
|
9
|
+
# the `language` matrix defined below to confirm you have the correct set of
|
|
10
|
+
# supported CodeQL languages.
|
|
11
|
+
#
|
|
12
|
+
name: "CodeQL"
|
|
13
|
+
|
|
14
|
+
on:
|
|
15
|
+
push:
|
|
16
|
+
branches: [ "main" ]
|
|
17
|
+
pull_request:
|
|
18
|
+
# The branches below must be a subset of the branches above
|
|
19
|
+
branches: [ "main" ]
|
|
20
|
+
schedule:
|
|
21
|
+
- cron: '41 19 * * 0'
|
|
22
|
+
|
|
23
|
+
jobs:
|
|
24
|
+
analyze:
|
|
25
|
+
name: Analyze
|
|
26
|
+
runs-on: ubuntu-latest
|
|
27
|
+
permissions:
|
|
28
|
+
actions: read
|
|
29
|
+
contents: read
|
|
30
|
+
security-events: write
|
|
31
|
+
|
|
32
|
+
strategy:
|
|
33
|
+
fail-fast: false
|
|
34
|
+
matrix:
|
|
35
|
+
language: [ 'python' ]
|
|
36
|
+
|
|
37
|
+
steps:
|
|
38
|
+
- name: Checkout repository
|
|
39
|
+
uses: actions/checkout@v4
|
|
40
|
+
|
|
41
|
+
# Initializes the CodeQL tools for scanning.
|
|
42
|
+
- name: Initialize CodeQL
|
|
43
|
+
uses: github/codeql-action/init@v3
|
|
44
|
+
with:
|
|
45
|
+
languages: ${{ matrix.language }}
|
|
46
|
+
# If you wish to specify custom queries, you can do so here or in a config file.
|
|
47
|
+
# By default, queries listed here will override any specified in a config file.
|
|
48
|
+
# Prefix the list here with "+" to use these queries and those in the config file.
|
|
49
|
+
|
|
50
|
+
# Details on CodeQL's query packs refer to : https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
|
|
51
|
+
# queries: security-extended,security-and-quality
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
|
|
55
|
+
# If this step fails, then you should remove it and run the build manually (see below)
|
|
56
|
+
- name: Autobuild
|
|
57
|
+
uses: github/codeql-action/autobuild@v3
|
|
58
|
+
|
|
59
|
+
# ℹ️ Command-line programs to run using the OS shell.
|
|
60
|
+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
|
|
61
|
+
|
|
62
|
+
# If the Autobuild fails above, remove it and uncomment the following three lines.
|
|
63
|
+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
|
|
64
|
+
|
|
65
|
+
# - run: |
|
|
66
|
+
# echo "Run, Build Application using script"
|
|
67
|
+
# ./location_of_script_within_repo/buildscript.sh
|
|
68
|
+
|
|
69
|
+
- name: Perform CodeQL Analysis
|
|
70
|
+
uses: github/codeql-action/analyze@v3
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# This is a basic workflow to help you get started with Actions
|
|
2
|
+
|
|
3
|
+
name: PullRequestConflicting
|
|
4
|
+
|
|
5
|
+
# Controls when the action will run. Triggers the workflow on push or pull request
|
|
6
|
+
# events but only for the master branch
|
|
7
|
+
on:
|
|
8
|
+
push:
|
|
9
|
+
branches: [ main ]
|
|
10
|
+
pull_request:
|
|
11
|
+
types: [synchronize]
|
|
12
|
+
branches: [ main ]
|
|
13
|
+
|
|
14
|
+
permissions:
|
|
15
|
+
pull-requests: write
|
|
16
|
+
contents: read
|
|
17
|
+
|
|
18
|
+
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
|
19
|
+
jobs:
|
|
20
|
+
# This workflow contains a single job called "build"
|
|
21
|
+
build:
|
|
22
|
+
# The type of runner that the job will run on
|
|
23
|
+
runs-on: ubuntu-latest
|
|
24
|
+
|
|
25
|
+
# Steps represent a sequence of tasks that will be executed as part of the job
|
|
26
|
+
steps:
|
|
27
|
+
- name: check if prs are dirty
|
|
28
|
+
uses: eps1lon/actions-label-merge-conflict@releases/2.x
|
|
29
|
+
if: env.LABELING_TOKEN != '' && env.LABELING_TOKEN != null
|
|
30
|
+
id: check
|
|
31
|
+
with:
|
|
32
|
+
dirtyLabel: "conflicting"
|
|
33
|
+
repoToken: "${{ secrets.GITHUB_TOKEN }}"
|
|
34
|
+
continueOnMissingPermissions: true
|
|
35
|
+
commentOnDirty: 'This pull request has conflicting changes, the author must resolve the conflicts before this pull request can be merged.'
|
|
36
|
+
commentOnClean: 'Conflicts have been resolved. A maintainer will take a look shortly.'
|
|
37
|
+
env:
|
|
38
|
+
LABELING_TOKEN: ${{secrets.GITHUB_TOKEN }}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
name: Publish package to PyPI and create release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
tags:
|
|
6
|
+
- "v*" # Push events to matching v*, i.e. v1.0, v20.15.10
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: write
|
|
10
|
+
|
|
11
|
+
jobs:
|
|
12
|
+
build:
|
|
13
|
+
uses: ./.github/workflows/build.yml
|
|
14
|
+
|
|
15
|
+
publish:
|
|
16
|
+
name: Publish distribution to PyPI
|
|
17
|
+
runs-on: ubuntu-latest
|
|
18
|
+
environment: pypi_prod
|
|
19
|
+
needs: [build]
|
|
20
|
+
steps:
|
|
21
|
+
- name: Checkout code
|
|
22
|
+
uses: actions/checkout@v4
|
|
23
|
+
- name: Set up Python 3.12
|
|
24
|
+
uses: actions/setup-python@v5
|
|
25
|
+
with:
|
|
26
|
+
python-version: 3.12
|
|
27
|
+
- name: Install flit
|
|
28
|
+
run: |
|
|
29
|
+
pip install flit
|
|
30
|
+
- name: Publish the distibution to PyPI
|
|
31
|
+
run: flit publish
|
|
32
|
+
env:
|
|
33
|
+
FLIT_INDEX_URL: https://upload.pypi.org/legacy/
|
|
34
|
+
FLIT_USERNAME: __token__
|
|
35
|
+
FLIT_PASSWORD: ${{ secrets. PYPI_API_TOKEN }}
|
|
36
|
+
|
|
37
|
+
release:
|
|
38
|
+
name: Create release
|
|
39
|
+
runs-on: ubuntu-latest
|
|
40
|
+
needs: [publish]
|
|
41
|
+
steps:
|
|
42
|
+
- name: Checkout
|
|
43
|
+
uses: actions/checkout@v4
|
|
44
|
+
- name: Extract release notes
|
|
45
|
+
id: extract-release-notes
|
|
46
|
+
uses: ffurrer2/extract-release-notes@v2
|
|
47
|
+
- name: Create release
|
|
48
|
+
env:
|
|
49
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
50
|
+
run: gh release create --notes '${{ steps.extract-release-notes.outputs.release_notes }}' --title ${{ github.ref_name }} ${{ github.ref_name }}
|