Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge from grantami-bomanalytics-private #386

Merged
merged 350 commits into from
Jan 16, 2024
Merged
Show file tree
Hide file tree
Changes from 250 commits
Commits
Show all changes
350 commits
Select commit Hold shift + click to select a range
4aac71d
Remove outdated typevars
ludovicsteinbach Oct 2, 2023
b705daa
Merge pull request #53 from ansys/feat/update-24.1.213
ludovicsteinbach Oct 4, 2023
6529554
Include finishing processes in summary
ludovicsteinbach Oct 4, 2023
191a147
Update example BoM
ludovicsteinbach Oct 4, 2023
6d71d0c
Create 4-2_BoM_Sustainability.py
ludovicsteinbach Oct 4, 2023
dd9632f
Add example to docs
ludovicsteinbach Oct 4, 2023
1114053
Sustainability example changes
Andy-Grigg Oct 4, 2023
bc9d467
Fix server name
Andy-Grigg Oct 4, 2023
0196a5d
Tweak working
Andy-Grigg Oct 5, 2023
aa69031
Merge pull request #56 from ansys/docs/sustainability-example-agrigg-…
Andy-Grigg Oct 5, 2023
d4d75e4
Change BoM naming convention
ludovicsteinbach Oct 5, 2023
ddeba8a
Add API link and minor formatting tweaks
ludovicsteinbach Oct 5, 2023
ac4dd2b
Change legend position
ludovicsteinbach Oct 5, 2023
1aae470
Merge pull request #55 from ansys/docs/sustainability-example
ludovicsteinbach Oct 5, 2023
2595370
Uncomment integration tests job
ludovicsteinbach Oct 5, 2023
0de8471
Make sure this class isn't collected by pytest
Andy-Grigg Oct 9, 2023
9803825
Rename with_legislations to with_legislation_ids
Andy-Grigg Oct 9, 2023
e6bc095
Add trailing space
Andy-Grigg Oct 9, 2023
510b5e1
Merge pull request #62 from ansys/fix/44-rename-testableBomHandler
da1910 Oct 10, 2023
e93a33a
Rename external_id on part to external_identity
da1910 Oct 10, 2023
797c906
Merge pull request #65 from ansys/fix/57_external_identity
da1910 Oct 10, 2023
7fd10a6
Enforce keywords for indicator constructors
Andy-Grigg Oct 10, 2023
6d0214b
Run black
Andy-Grigg Oct 10, 2023
2cffdc7
Merge pull request #63 from ansys/feat/10-document-legislation-id-change
Andy-Grigg Oct 10, 2023
2e1d789
Merge branch 'main' into ci/reinstate-integration-tests
Andy-Grigg Oct 10, 2023
716dcfb
Copy check_server from recordlists
Andy-Grigg Oct 10, 2023
33acecf
Add variable to disable vm state management
Andy-Grigg Oct 10, 2023
606b645
Fix error message
Andy-Grigg Oct 10, 2023
47061ad
Fix typo
ludovicsteinbach Oct 9, 2023
b0e3c52
Use absolute masses for secondary processes and use floats
ludovicsteinbach Oct 10, 2023
ee7eb5b
Draft bom builder example
ludovicsteinbach Oct 10, 2023
09e3839
Add example to docs
ludovicsteinbach Oct 11, 2023
69d5b93
Fix typing
ludovicsteinbach Oct 11, 2023
6b0f7de
Merge pull request #68 from ansys/maint/typing-issue-#59
ludovicsteinbach Oct 11, 2023
69ac314
Remove some boms
ludovicsteinbach Oct 11, 2023
e6345ab
Improve sustainability integration tests
ludovicsteinbach Oct 11, 2023
0cf0fd2
Fix error message
Andy-Grigg Oct 11, 2023
3344e4c
PR feedback
ludovicsteinbach Oct 12, 2023
d683d35
Merge pull request #69 from ansys/tests-sustainabilty-integration-tests
ludovicsteinbach Oct 12, 2023
653fa6b
Apply language suggestions from code review
ludovicsteinbach Oct 12, 2023
a9fe4df
Add delimiters and fix comments
ludovicsteinbach Oct 12, 2023
f65a440
Fix GUID field name
ludovicsteinbach Oct 12, 2023
f8a58e1
Merge branch 'main' into docs/bom-builder-example
ludovicsteinbach Oct 12, 2023
6694723
Use method for record references
ludovicsteinbach Oct 12, 2023
d52b478
Fix test assertions (due to mass changes in BoM)
ludovicsteinbach Oct 12, 2023
ad650ce
Change plotly renderer in examples tests [skip-ci]
ludovicsteinbach Oct 12, 2023
deb88ff
Update BillOfMaterialsEco2301.xsd
ludovicsteinbach Oct 12, 2023
2236242
Add category enum
ludovicsteinbach Oct 12, 2023
8a83bba
Merge pull request #70 from ansys/feat/update-bom-schema
ludovicsteinbach Oct 12, 2023
1d2de34
Merge pull request #67 from ansys/docs/bom-builder-example
ludovicsteinbach Oct 12, 2023
992fd25
Update sus. tests to reflect aggregation changes
ludovicsteinbach Oct 12, 2023
db23e87
Remove outdated todo
ludovicsteinbach Oct 12, 2023
9880594
Fix error message
Andy-Grigg Oct 10, 2023
da36e2e
Fix missing database test
ludovicsteinbach Oct 12, 2023
f4fd8e4
Merge pull request #71 from ansys/feat/update-24.1.248
ludovicsteinbach Oct 12, 2023
a463837
Add initial docs for BoM Types
da1910 Oct 13, 2023
2dd6ff0
Update files for 2024 R1
Andy-Grigg Oct 13, 2023
b4beb04
Ignore deserialization
da1910 Oct 13, 2023
76ddb3a
Exclude the right thing
da1910 Oct 13, 2023
a66de53
Move a docstring and update the other ignorewords...
da1910 Oct 13, 2023
8b6aedf
Try without tildes
da1910 Oct 13, 2023
7e86594
Pin vale?
da1910 Oct 13, 2023
a4c61a2
There is no 2.28
da1910 Oct 13, 2023
7ff91ce
Update index.rst
da1910 Oct 16, 2023
b5a019a
Merge pull request #74 from ansys/doc/bom-types
da1910 Oct 16, 2023
4ed327d
Update README.rst
ludovicsteinbach Oct 13, 2023
9b12511
Clarify aggregation methodology
ludovicsteinbach Oct 13, 2023
315dc7a
Add links to online docs
ludovicsteinbach Oct 13, 2023
aa803bd
Add record identification documentation
ludovicsteinbach Oct 13, 2023
ab01217
Remove id notes
ludovicsteinbach Oct 13, 2023
14e6e51
Remove "do not instantiate" notes
ludovicsteinbach Oct 13, 2023
2d989d7
Fix message typing
ludovicsteinbach Oct 16, 2023
876ecf2
Update summary results docstrings
ludovicsteinbach Oct 16, 2023
f8fb229
Bump openapi package
ludovicsteinbach Oct 16, 2023
e965af0
Remove sustainability blank coatings
ludovicsteinbach Oct 16, 2023
cafa05d
Remove sustainability from specifications
ludovicsteinbach Oct 16, 2023
94c637b
Remove substances from MaterialWithSustainability
ludovicsteinbach Oct 16, 2023
8482a02
Fix issues with Quantity
da1910 Oct 16, 2023
e0ca441
Add name to transport results
ludovicsteinbach Oct 16, 2023
9d0d132
Update examples.py
ludovicsteinbach Oct 16, 2023
2c1bae5
Update unit tests
ludovicsteinbach Oct 16, 2023
a0ef56a
Merge pull request #76 from ansys/docs/improve-docs
ludovicsteinbach Oct 17, 2023
5b1d457
Merge branch 'main' into feat/update-24.1.258
ludovicsteinbach Oct 17, 2023
a064597
Use merge commit ref
ludovicsteinbach Oct 17, 2023
b482327
Update tests/test_item_results.py
ludovicsteinbach Oct 17, 2023
5b6da65
Merge pull request #80 from ansys/feat/update-24.1.258
ludovicsteinbach Oct 17, 2023
fe2269f
Create BillOfMaterialsEco1711.xsd
ludovicsteinbach Oct 17, 2023
e2a4e5b
Schemas sub-package
ludovicsteinbach Oct 17, 2023
836d32d
Remove schemas from examples
ludovicsteinbach Oct 17, 2023
5227fa0
Merge branch 'main' into fix/75_attribute_xml
Andy-Grigg Oct 17, 2023
30a16f0
Merge branch 'ci/reinstate-integration-tests' of https://github.com/a…
Andy-Grigg Oct 17, 2023
c2eefe9
Merge branch 'main' into ci/reinstate-integration-tests
Andy-Grigg Oct 17, 2023
53dadcc
Merge pull request #81 from ansys/feat/bom-schemas
ludovicsteinbach Oct 18, 2023
93c5e25
Review comments
da1910 Oct 18, 2023
8a04e33
Merge pull request #79 from ansys/fix/75_attribute_xml
da1910 Oct 18, 2023
ddcaf65
Expect warnings in tests
ludovicsteinbach Oct 18, 2023
d8063ea
Make inputs mandatory
ludovicsteinbach Oct 18, 2023
eb08bb1
Naive support for multiple BoM versions
ludovicsteinbach Oct 18, 2023
81756b5
Add notes about schemas and schemas to docs
ludovicsteinbach Oct 19, 2023
5f64bd0
Rename sample bom
ludovicsteinbach Oct 19, 2023
dd78f2b
Delete unused test helpers
ludovicsteinbach Oct 19, 2023
511b6ba
Update test_integration_tests.py
ludovicsteinbach Oct 19, 2023
68774a0
Modify invalid bom to pass client side validation
ludovicsteinbach Oct 19, 2023
1583e82
Fix fixture name
ludovicsteinbach Oct 19, 2023
6258763
Add custom tables for sustainability
Andy-Grigg Oct 19, 2023
bb622a2
Fix failing integration tests
Andy-Grigg Oct 19, 2023
adae7f9
Minor feedback
ludovicsteinbach Oct 20, 2023
611655e
Fix database key
Andy-Grigg Oct 20, 2023
8171dc1
Merge pull request #84 from ansys/ci/reinstate-integration-tests
Andy-Grigg Oct 20, 2023
dacc12f
Fix vale vocab
Andy-Grigg Oct 20, 2023
8505d99
Remove use of regex
ludovicsteinbach Oct 23, 2023
ea147ee
Merge branch 'main' into feat/2-multiple-bom-formats
ludovicsteinbach Oct 23, 2023
e9bdd7a
Remove messages assertions
ludovicsteinbach Oct 23, 2023
86d8af8
Update docs
ludovicsteinbach Oct 23, 2023
6b389a8
Merge pull request #83 from ansys/feat/2-multiple-bom-formats
ludovicsteinbach Oct 23, 2023
1a9fb4a
Remove results classes
ludovicsteinbach Oct 24, 2023
07ffb60
Update tests
ludovicsteinbach Oct 24, 2023
1a1830c
Remove from docs
ludovicsteinbach Oct 24, 2023
5426a78
Update PartWithSustainability docstring
ludovicsteinbach Oct 24, 2023
28c726e
Compose record references
ludovicsteinbach Oct 24, 2023
69ffb2c
Add part number
ludovicsteinbach Oct 24, 2023
7fa2235
Update tests
ludovicsteinbach Oct 24, 2023
321cab7
Correct typing
ludovicsteinbach Oct 24, 2023
b507be7
Update mock responses and associated tests
ludovicsteinbach Oct 24, 2023
c7da2e9
Update dependency
ludovicsteinbach Oct 24, 2023
877470f
Merge pull request #88 from ansys/feat/remove-irrelevant-items-sustai…
ludovicsteinbach Oct 24, 2023
14ea1f7
Merge branch 'main' into feat/update-24.1.269
ludovicsteinbach Oct 24, 2023
653a773
Make mixin into base class
ludovicsteinbach Oct 24, 2023
35e9409
Use merge commit ref
ludovicsteinbach Oct 24, 2023
aebe5a9
Merge pull request #89 from ansys/feat/update-24.1.269
ludovicsteinbach Oct 24, 2023
a9f5a5a
Warn on multiple root parts in sust. query result
ludovicsteinbach Oct 25, 2023
83ef0b8
Update warning
ludovicsteinbach Oct 25, 2023
e5727b8
Merge pull request #90 from ansys/feat/warn-on-multiple-root-parts-su…
ludovicsteinbach Oct 25, 2023
71a3c90
Add part and transport references to docs
ludovicsteinbach Oct 25, 2023
2145ca5
Update docs homepage
ludovicsteinbach Oct 25, 2023
ab7cf9b
Update GitHub org name
ludovicsteinbach Oct 25, 2023
26cfd36
Update MI version requirements
ludovicsteinbach Oct 25, 2023
5592a82
Add note about product licensing
ludovicsteinbach Oct 25, 2023
61b0a6f
Update Process properties names and docs
ludovicsteinbach Oct 26, 2023
4bcacbf
Update BoM builder example
ludovicsteinbach Oct 26, 2023
2a0c724
Update example bom
ludovicsteinbach Oct 26, 2023
27af5cf
Remove duplicated BoM
ludovicsteinbach Oct 26, 2023
a2176f1
Rename test BoMs
ludovicsteinbach Oct 26, 2023
afb8aeb
Remove duplicated BoM
ludovicsteinbach Oct 26, 2023
e94a9d9
Rename paths variables
ludovicsteinbach Oct 26, 2023
f9bf476
Add variables for extra boms
ludovicsteinbach Oct 26, 2023
f4cd5f7
Use newer version of vale
Andy-Grigg Oct 26, 2023
279f2c3
Convert to dataclasses
ludovicsteinbach Oct 14, 2023
f4ced58
Update bom types docs
ludovicsteinbach Oct 27, 2023
f0ad8cc
Fix bom types issues
ludovicsteinbach Oct 27, 2023
276f32d
Comment out troublesome properties
ludovicsteinbach Oct 27, 2023
94c91b9
Add test
ludovicsteinbach Oct 27, 2023
56e7869
Fix typing and formatting
ludovicsteinbach Oct 27, 2023
29e025b
Merge pull request #92 from ansys/fix/bom-type-process
ludovicsteinbach Oct 30, 2023
1b05f80
Apply suggestions from code review
ludovicsteinbach Oct 30, 2023
4255721
Remove special handling for ids
ludovicsteinbach Oct 27, 2023
7b38d8d
Comment out annotations
ludovicsteinbach Oct 30, 2023
2986a71
Merge pull request #91 from ansys/docs/misc-updates
ludovicsteinbach Oct 30, 2023
7b38cf6
Address more small issues
ludovicsteinbach Oct 30, 2023
67ceb43
Merge branch 'main' into feat/use-dataclass
ludovicsteinbach Oct 30, 2023
be2576f
Add comment about BoM "update"
ludovicsteinbach Oct 30, 2023
4f1cea1
Merge branch 'main' into maint/less-boms
ludovicsteinbach Oct 30, 2023
a02c8b7
Merge pull request #93 from ansys/maint/less-boms
ludovicsteinbach Oct 31, 2023
34dfbba
Add TODOs with issue ID
ludovicsteinbach Oct 31, 2023
af7ce0c
Merge branch 'main' into feat/use-dataclass
ludovicsteinbach Oct 31, 2023
d18eb15
Ignore numpydoc warning
ludovicsteinbach Oct 31, 2023
245dbb0
Add missing docstrings
ludovicsteinbach Oct 31, 2023
139f36f
Address vale issues
ludovicsteinbach Oct 31, 2023
f984367
Update accept.txt
ludovicsteinbach Oct 31, 2023
0b60a49
Update accept.txt
ludovicsteinbach Oct 31, 2023
cabdf86
Add test for unexpected args
ludovicsteinbach Oct 31, 2023
862f2a8
Merge pull request #94 from ansys/feat/use-dataclass
ludovicsteinbach Oct 31, 2023
956cd24
Script tweaks
Andy-Grigg Nov 1, 2023
a9d37e7
Update .vale.ini
ludovicsteinbach Nov 2, 2023
70aecaf
Update common identifiers documentation
ludovicsteinbach Nov 2, 2023
9145c55
Add missing punctuation
ludovicsteinbach Nov 2, 2023
8c9b1d2
Merge pull request #97 from ansys/doc/fix-vale-issues
ludovicsteinbach Nov 2, 2023
688a600
Merge pull request #87 from ansys/doc/fix-vale-vocab
Andy-Grigg Nov 2, 2023
2daae27
Wording feedback
ludovicsteinbach Nov 2, 2023
f62d4b8
Merge branch 'main' into docs/identities
ludovicsteinbach Nov 2, 2023
1a39b91
Merge pull request #99 from ansys/docs/identities
ludovicsteinbach Nov 2, 2023
d61bb22
Bump actions/checkout from 3 to 4
dependabot[bot] Nov 3, 2023
cc599cd
Merge pull request #15 from ansys/dependabot/github_actions/actions/c…
ludovicsteinbach Nov 3, 2023
24b7100
Merge pull request #98 from ansys/maint/2024-r1-fixes
Andy-Grigg Nov 3, 2023
62e84a9
Remove test bom
ludovicsteinbach Nov 3, 2023
4eb4401
Fix doc header
ludovicsteinbach Nov 3, 2023
12987c4
Merge pull request #100 from ansys/maint/delete-bom
ludovicsteinbach Nov 3, 2023
1403b41
Add badges to README
ludovicsteinbach Nov 3, 2023
dc46301
Sustainability docs tweaks
ludovicsteinbach Nov 6, 2023
5f7b40e
Fix/ignore reference warnings
ludovicsteinbach Nov 6, 2023
f7826d7
Typo in example
ludovicsteinbach Nov 6, 2023
e23a65b
Clarify env. footprint hierarchy
ludovicsteinbach Nov 6, 2023
43760ac
Merge pull request #101 from ansys/maint/add-badges
ludovicsteinbach Nov 7, 2023
c9ea44d
Remove TODO
ludovicsteinbach Nov 7, 2023
31b6ad4
Merge pull request #103 from ansys/docs/minor-tweaks
ludovicsteinbach Nov 7, 2023
fcf2f7d
Updates to bom builder example script
Andy-Grigg Nov 13, 2023
6a787e3
Update package index
ludovicsteinbach Nov 14, 2023
69cba74
Add note about item expansion
ludovicsteinbach Nov 15, 2023
53da47d
Fix error message
Andy-Grigg Nov 15, 2023
6d2d4b7
Document aggregation criteria
ludovicsteinbach Nov 15, 2023
34eda87
Flake8
Andy-Grigg Nov 15, 2023
3cf71b8
Add space
Andy-Grigg Nov 15, 2023
78be98f
Merge pull request #104 from ansys/doc/73-bom-builder-examples
Andy-Grigg Nov 15, 2023
9004d2e
Merge branch 'main' into docs/add-documentation
ludovicsteinbach Nov 15, 2023
5464fd8
Language feedback
ludovicsteinbach Nov 16, 2023
50259f6
Re-ordering
ludovicsteinbach Nov 16, 2023
de1f0d2
Merge pull request #105 from ansys/docs/add-documentation
ludovicsteinbach Nov 16, 2023
a4f953f
Add missing mian dependencies
ludovicsteinbach Nov 16, 2023
6b9fcb7
Poetry lock with update
ludovicsteinbach Nov 16, 2023
691e180
Merge pull request #113 from ansys/maint/bump-dependencies
ludovicsteinbach Nov 16, 2023
e382052
Update emails
ludovicsteinbach Nov 16, 2023
7e75d90
Use openapi PR ref
ludovicsteinbach Nov 16, 2023
b7f8a9d
Drop Python 3.8
ludovicsteinbach Nov 16, 2023
d1382fe
Support Python 3.12
ludovicsteinbach Nov 16, 2023
10db44a
Fix tox config
ludovicsteinbach Nov 16, 2023
49fa665
Use merge commit ref
ludovicsteinbach Nov 17, 2023
57479d9
Merge pull request #114 from ansys/maint/update-openapi-and-python
ludovicsteinbach Nov 17, 2023
c3a5c7b
Update docs dependencies
ludovicsteinbach Nov 17, 2023
50f0b6d
Update comment
ludovicsteinbach Nov 20, 2023
45a4a5b
Loosen specifications
ludovicsteinbach Nov 20, 2023
a8019ec
Merge pull request #117 from ansys/maint/update-docs-deps
ludovicsteinbach Nov 20, 2023
b2edfa6
Bump pandas from 2.0.3 to 2.1.3
dependabot[bot] Nov 20, 2023
4df4788
Merge pull request #119 from ansys/dependabot/pip/pandas-2.1.3
ludovicsteinbach Nov 20, 2023
7e26637
Remove with_stk_records (#123)
ludovicsteinbach Nov 21, 2023
b76187b
Fix: add repr and example formatting (#122)
ludovicsteinbach Nov 21, 2023
b2e3ddd
Maint: Update docs deps (#127)
ludovicsteinbach Nov 22, 2023
12a2def
Feat: Single part in BoM sustainability (#130)
ludovicsteinbach Nov 30, 2023
dd91ef8
Docs: PM feedback (#132)
ludovicsteinbach Nov 30, 2023
c01fbf8
Bump jupytext from 1.15.2 to 1.16.0 (#133)
dependabot[bot] Dec 5, 2023
8df1260
Docs: review feedback (#142)
ludovicsteinbach Jan 4, 2024
2da259c
Allow null material identity and reference
ludovicsteinbach Jan 4, 2024
d1c3537
Add first draft of general improvements to documentation
Andy-Grigg Jan 4, 2024
bd270b2
Vale fixes
Andy-Grigg Jan 4, 2024
825f1db
Add note to compliance API page
Andy-Grigg Jan 5, 2024
994f2cf
Move license note to end
Andy-Grigg Jan 5, 2024
710ebe3
Fix BoM query descriptions
Andy-Grigg Jan 5, 2024
e17ed09
Merge pull request #143 from ansys/fix/process-summary
Andy-Grigg Jan 9, 2024
e986315
Fix typo
ludovicsteinbach Jan 10, 2024
eea5664
Documentation review feedback
ludovicsteinbach Jan 10, 2024
70a3aa9
Merge pull request #147 from ansys/doc/improve-docs
Andy-Grigg Jan 10, 2024
b2b24ee
Merge pull request #144 from ansys/doc/optional-changes
Andy-Grigg Jan 10, 2024
08ed5f0
Point at public bomanalytics-openapi
Andy-Grigg Jan 10, 2024
4547533
Merge pull request #149 from ansys/maint/use-public-bomanalytics-openapi
Andy-Grigg Jan 11, 2024
28cef4f
Merge remote-tracking branch 'public/main' into maint/merge-from-private
Andy-Grigg Jan 11, 2024
72d1aef
Fix cname
Andy-Grigg Jan 11, 2024
0575d50
Clean up workflows
Andy-Grigg Jan 11, 2024
29c5953
Use public bomanalytics-openapi
Andy-Grigg Jan 12, 2024
6bcbc64
Maint/codacy fixes (#388)
Andy-Grigg Jan 15, 2024
d876d2f
Add metapackage instructions (#390)
Andy-Grigg Jan 15, 2024
0231a35
Docs: update product help links (#391)
ludovicsteinbach Jan 16, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 3 additions & 11 deletions .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,17 +29,9 @@ jobs:
needs: local_checks
if: ${{ !startsWith( github.event.pull_request.head.ref, 'dependabot/') }}
uses: ./.github/workflows/server_checks.yml
secrets:
AZURE_APP_ID: ${{ secrets.AZURE_APP_ID }}
AZURE_SECRET: ${{ secrets.AZURE_SECRET }}
AZURE_TENANT_ID: ${{ secrets.AZURE_TENANT_ID }}
AZURE_RESOURCE_GROUP: ${{ secrets.AZURE_RESOURCE_GROUP }}
AZURE_VM_NAME: ${{ secrets.AZURE_VM_NAME }}
TEST_SERVER_URL: ${{ secrets.TEST_SERVER_URL }}
TEST_SERVER_READ_USER: ${{ secrets.TEST_SERVER_READ_USER }}
TEST_SERVER_READ_PASS: ${{ secrets.TEST_SERVER_READ_PASS }}
TEST_SERVER_WRITE_USER: ${{ secrets.TEST_SERVER_WRITE_USER }}
TEST_SERVER_WRITE_PASS: ${{ secrets.TEST_SERVER_WRITE_PASS }}
with:
skip-vm-management: ${{ vars.SKIP_VM_MANAGEMENT == 'true' }}
secrets: inherit

doc-deploy-dev:
name: "Deploy development documentation"
Expand Down
32 changes: 8 additions & 24 deletions .github/workflows/local_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,11 @@ env:
MAIN_PYTHON_VERSION: '3.9'

jobs:
style:
name: Code Style Check
code-style:
name: "Code Style Check"
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up Python ${{ env.MAIN_PYTHON_VERSION }}
uses: actions/setup-python@v4
with:
python-version: ${{ env.MAIN_PYTHON_VERSION }}

- name: Install style requirements
run: pip install 'tox<4' poetry --disable-pip-version-check

- name: Spell, Lint and Type Check
run: tox -e style

- uses: ansys/actions/code-style@v4

docs-style:
name: Documentation Style Check
Expand All @@ -35,19 +22,22 @@ jobs:
uses: ansys/actions/doc-style@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
vale-version: "2.29.6"

unit_tests:
name: Unit tests
runs-on: ubuntu-latest

strategy:
matrix:
python-version: [ '3.8', '3.9', '3.10', '3.11' ]
python-version: [ '3.9', '3.10', '3.11', '3.12' ]
steps:
- uses: actions/checkout@v4

- name: Install kerberos headers
run: sudo apt install libkrb5-dev
run: |
sudo apt-get update
sudo apt install libkrb5-dev

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
Expand All @@ -60,12 +50,6 @@ jobs:
- name: Test with tox (no integration tests)
run: tox -- -m "not integration"

- name: Upload coverage report
uses: codecov/codecov-action@v3
with:
fail_ci_if_error: true
token: ${{ secrets.CODECOV_TOKEN }}

package:
name: Build package
runs-on: ubuntu-latest
Expand Down
15 changes: 13 additions & 2 deletions .github/workflows/server_checks.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
on:
workflow_call:
inputs:
skip-vm-management:
description: >
Whether to skip or not the start up of the virtual machine. Default
value is ``false``.
required: false
default: false
type: boolean
secrets:
AZURE_APP_ID:
required: true
Expand Down Expand Up @@ -38,6 +46,7 @@ jobs:
- name: Start VM with Azure CLI
id: azure_cli
uses: azure/CLI@v1
if: ${{ !(inputs.skip-vm-management)}}
with:
azcliversion: 2.32.0
inlineScript: |
Expand Down Expand Up @@ -73,7 +82,9 @@ jobs:

- name: Install kerberos headers (ubuntu only)
if: ${{ matrix.os == 'ubuntu-latest' }}
run: sudo apt install libkrb5-dev
run: |
sudo apt-get update
sudo apt install libkrb5-dev

- name: Install dependencies
run: pip install poetry 'tox<4' --disable-pip-version-check
Expand Down Expand Up @@ -141,7 +152,7 @@ jobs:
name: Stop Azure VM
runs-on: ubuntu-latest
needs: docs
if: always()
if: ${{ always() && !(inputs.skip-vm-management)}}

steps:
- name: Stop Azure VM
Expand Down
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,12 @@ test-output.xml
# Docs builds
doc/build

.ipython/profile_default/history.sqlite

# ipynb (generated from py files on docs build)
*.ipynb

# Pypi things
deps

venv/
46 changes: 24 additions & 22 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,13 @@ repos:
rev: 23.7.0
hooks:
- id: black
exclude: ^examples/|doc/|.ipython/

# ISORT should be activated at some point
#
# - repo: https://github.com/pycqa/isort
# rev: 5.10.1
# hooks:
# - id: isort

- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort

- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
Expand All @@ -21,23 +21,25 @@ repos:
rev: v2.2.5
hooks:
- id: codespell
args: ["--ignore-words", "doc/styles/Vocab/ANSYS/accept.txt", "--skip", "poetry.lock"]

# MYPY also not really working...
#
# - repo: https://github.com/pre-commit/mirrors-mypy
# rev: v0.991 # Use the sha / tag you want to point at
# hooks:
# - id: mypy
# args: ["--config-file", "pyproject.toml", ./src/ ]

# To be activated after quick dev cycles
#
# - repo: https://github.com/pycqa/pydocstyle
# rev: 6.1.1
# hooks:
# - id: pydocstyle
# additional_dependencies: [toml]
# exclude: "tests/"
- repo: local
hooks:
- id: mypy-code
name: "mypy: checks on code"
entry: mypy
language: python
types: [python]
require_serial: true
files: "^(src/)"
additional_dependencies: ["mypy==1.5.1"]

#- repo: https://github.com/pycqa/pydocstyle
# rev: 6.3.0
# hooks:
# - id: pydocstyle
# additional_dependencies: [tomli]
# files: "^(src/)"

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
Expand Down
48 changes: 41 additions & 7 deletions README.rst
Original file line number Diff line number Diff line change
@@ -1,15 +1,49 @@
|pyansys| |python| |pypi| |GH-CI| |codecov| |MIT| |black|

.. |pyansys| image:: https://img.shields.io/badge/Py-Ansys-ffc107.svg?labelColor=black&logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABDklEQVQ4jWNgoDfg5mD8vE7q/3bpVyskbW0sMRUwofHD7Dh5OBkZGBgW7/3W2tZpa2tLQEOyOzeEsfumlK2tbVpaGj4N6jIs1lpsDAwMJ278sveMY2BgCA0NFRISwqkhyQ1q/Nyd3zg4OBgYGNjZ2ePi4rB5loGBhZnhxTLJ/9ulv26Q4uVk1NXV/f///////69du4Zdg78lx//t0v+3S88rFISInD59GqIH2esIJ8G9O2/XVwhjzpw5EAam1xkkBJn/bJX+v1365hxxuCAfH9+3b9/+////48cPuNehNsS7cDEzMTAwMMzb+Q2u4dOnT2vWrMHu9ZtzxP9vl/69RVpCkBlZ3N7enoDXBwEAAA+YYitOilMVAAAAAElFTkSuQmCC
:target: https://docs.pyansys.com/
:alt: PyAnsys

.. |python| image:: https://img.shields.io/pypi/pyversions/ansys-grantami-bomanalytics?logo=pypi
:target: https://pypi.org/project/ansys-grantami-bomanalytics/
:alt: Python

.. |pypi| image:: https://img.shields.io/pypi/v/ansys-grantami-bomanalytics.svg?logo=python&logoColor=white
:target: https://pypi.org/project/ansys-grantami-bomanalytics
:alt: PyPI

.. |codecov| image:: https://codecov.io/gh/ansys/grantami-bomanalytics/branch/main/graph/badge.svg
:target: https://codecov.io/gh/ansys/grantami-bomanalytics
:alt: Codecov

.. |GH-CI| image:: https://github.com/ansys/grantami-bomanalytics/actions/workflows/ci_cd.yml/badge.svg
:target: https://github.com/ansys/grantami-bomanalytics/actions/workflows/ci_cd.yml
:alt: GH-CI

.. |MIT| image:: https://img.shields.io/badge/License-MIT-yellow.svg
:target: https://opensource.org/licenses/MIT
:alt: MIT

.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg?style=flat
:target: https://github.com/psf/black
:alt: Black


ansys-grantami-bomanalytics
###########################

Project Overview
----------------
PyGranta BoM Analytics is part of the larger `PyAnsys <https://github.com/pyansys>`_
PyGranta BoM Analytics is part of the larger `PyAnsys <https://docs.pyansys.com>`_
effort to facilitate the use of Ansys technologies directly from Python.

The Granta MI Restricted Substances solution includes a REST API for
evaluating compliance of products, assemblies, specifications, and
materials against legislations. This package abstracts automatically-
generated code into an easy-to-use client library.
The MI Restricted Substances and MI Sustainability solutions for Granta MI include REST APIs for:

- Evaluating compliance of products, assemblies, specifications, and
materials against legislations.
- Evaluating the environmental performance of products, assemblies, materials and processes.

This package abstracts automatically-generated code into an easy-to-use client library.


Installation
Expand All @@ -24,7 +58,7 @@ Alternatively, clone and install this package with this code:

.. code::

git clone https://github.com/pyansys/grantami-bomanalytics
git clone https://github.com/ansys/grantami-bomanalytics
cd grantami-bomanalytics
pip install .

Expand All @@ -49,7 +83,7 @@ Here's a brief example of how to use PyGranta BoM Analytics:
>>> query = (
... queries.MaterialImpactedSubstancesQuery()
... .with_material_ids(['plastic-abs-pvc-flame'])
... .with_legislations(['EU REACH - The Candidate List'])
... .with_legislation_ids(['Candidate_AnnexXV'])
... )

# Print out the result from the query.
Expand Down
35 changes: 25 additions & 10 deletions cicd/check_server.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import requests
from requests.auth import HTTPBasicAuth
import os
import json
import time
from functools import wraps
import json
import logging
import os
import platform
import time

import requests
from requests.auth import HTTPBasicAuth

logging.basicConfig(level=logging.INFO)
logger = logging.getLogger()
Expand Down Expand Up @@ -34,12 +36,25 @@ def wrapper(*args, **kwargs):

@block_until_server_is_ok
def check_status(url: str, auth_header: HTTPBasicAuth) -> bool:
python_implementation = platform.python_implementation()
python_version = platform.python_version()
os_version = platform.platform()
user_agent = f"check_server.py {python_implementation}/{python_version} ({os_version})"

try:
response = requests.get(url + "/Health/v2.svc/", auth=auth_header)
except requests.exceptions.RequestException:
# This generally won't happen in normal operation. But if a RequestException happens we want to make sure we
# handle it and try again.
# If MI isn't running we'll generally get a 5xx status from the gateway instead, which is handled below.
response = requests.get(
url + "/Health/v2.svc/",
auth=auth_header,
headers={
"User-Agent": user_agent,
},
)
except requests.exceptions.RequestException as e:
# This generally won't happen in normal operation. But if a RequestException happens we want
# to make sure we handle it and try again.
# If MI isn't running we'll generally get a 5xx status from the gateway instead, which is
# handled below.
logger.error(e)
return False
logger.info(f"Received {response.status_code} response.")
if response.status_code != 200:
Expand Down
Loading