Skip to content

Commit

Permalink
Merge pull request #400 from braingram/revert_360
Browse files Browse the repository at this point in the history
Revert "Merge pull request #360 from WilliamJamieson/refactor/layout"
  • Loading branch information
braingram authored Sep 5, 2023
2 parents 4e461f3 + 19a4d91 commit b756938
Show file tree
Hide file tree
Showing 81 changed files with 254 additions and 255 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,6 @@ jobs:
with:
upload_to_pypi: false
upload_to_anaconda: false
test_extras: test
test_command: pytest --pyargs asdf_standard

asdf-dev:
name: Run asdf-development tests
Expand Down
1 change: 0 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ The stable ASDF Standard is v1.5.0
- Bugfix for ``base_format`` in ``time-1.2.0`` schema. [#349]
- Add new ``ndarray-1.1.0`` schema to fix #345 [#350]
- Remove ``unit-1.1.0`` erroneously added in #350 [#355]
- Refactor file layout [#360]
- Fix URI fragment format in metaschema references. [#373]
- Fix URI fragment format in quantity-1.2 schema [#374]
- Drop support for python 3.8 [#390]
Expand Down
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@
# -- sphinx_asdf configuration ---------------------------------------------

# Top-level directory containing ASDF schemas (relative to current directory)
asdf_schema_path = "../../src/asdf_standard/resources/schemas"
asdf_schema_path = "../../resources/schemas"
# This is the prefix common to all schema IDs in this repository
asdf_schema_standard_prefix = "stsci.edu/asdf"
# This seems pretty redundant/unnecessary and should probably be fixed in the
Expand Down
2 changes: 1 addition & 1 deletion docs/source/schemas/manifest.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ The ASDF tags (described by schemas) available under each ASDF standard version
by a single manifest document for that ASDF standard version.

.. asdf-autoschemas::
:schema_root: ../../src/asdf_standard/resources/manifests
:schema_root: ../../resources/manifests
:standard_prefix: asdf-format.org/core

core-1.0.0
Expand Down
2 changes: 1 addition & 1 deletion docs/source/schemas/yaml_schema.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ Writing a new schema is described in :ref:`extending-asdf`.
.. _yaml-schema-draft-01:

.. asdf-schema::
:schema_root: ../../src/asdf_standard/resources/schemas/stsci.edu
:schema_root: ../../resources/schemas/stsci.edu
:standard_prefix:

yaml-schema/draft-01
6 changes: 3 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,14 +61,14 @@ write_to = "src/asdf_standard/_version.py"
packages = ["asdf_standard", "asdf_standard.resources"]

[tool.setuptools.package-data]
"asdf_standard.resources" = ["src/asdf_standard/resources/**/*.yaml"]
"asdf_standard.resources" = ["resources/**/*.yaml"]

[tool.setuptools.package-dir]
"" = "src"
"asdf_standard.resources" = "src/asdf_standard/resources"
"asdf_standard.resources" = "resources"

[tool.pytest.ini_options]
asdf_schema_root = 'src/asdf_standard/resources/schemas'
asdf_schema_root = 'resources/schemas'
asdf_schema_skip_tests = """
stsci.edu/asdf/asdf-schema-1.0.0.yaml
stsci.edu/asdf/wcs/celestial_frame-1.0.0.yaml
Expand Down
7 changes: 6 additions & 1 deletion src/asdf_standard/integration.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import sys
from pathlib import Path

if sys.version_info < (3, 9):
import importlib_resources
Expand All @@ -11,7 +12,11 @@
def get_resource_mappings():
resources_root = importlib_resources.files(asdf_standard) / "resources"
if not resources_root.is_dir():
raise RuntimeError("Missing resources directory")
# In an editable install, the resources directory will exist off the
# repository root:
resources_root = Path(__file__).absolute().parent.parent.parent / "resources"
if not resources_root.is_dir():
raise RuntimeError("Missing resources directory")

return [
asdf_standard.DirectoryResourceMapping(
Expand Down
170 changes: 0 additions & 170 deletions src/asdf_standard/tests/common.py

This file was deleted.

File renamed without changes.
Loading

0 comments on commit b756938

Please sign in to comment.