Skip to content

Commit

Permalink
change URI representation to upper case
Browse files Browse the repository at this point in the history
  • Loading branch information
titusz committed Apr 19, 2022
1 parent b0f3151 commit 7ef3a32
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## [0.2.8] - Unreleased
- Fixed bug with subtype for semantic code
- Changed URI representation to upper case
- Added line conversion tool
- Updated dependencies

Expand Down
1 change: 1 addition & 0 deletions docs/changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## [0.2.8] - Unreleased
- Fixed bug with subtype for semantic code
- Changed URI representation to upper case
- Added line conversion tool
- Updated dependencies

Expand Down
2 changes: 1 addition & 1 deletion iscc_core/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ def code(self) -> str:
@property
def uri(self) -> str:
"""Standard uri representation of an ISCC code."""
return f"iscc:{self.code.lower()}"
return f"ISCC:{self.code.upper()}"

@property
def bytes(self) -> bytes:
Expand Down
2 changes: 1 addition & 1 deletion tests/test_codec.py
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ def test_code_hashable():
def test_Code_uri():
mco = ic.Code(ic.gen_meta_code("This is an URI representation of a Meta-Code")["iscc"])
assert mco.code == "AAAX334V4AMT2PP4"
assert mco.uri == "iscc:aaax334v4amt2pp4"
assert mco.uri == "ISCC:AAAX334V4AMT2PP4"


def test_Code_mf_base16():
Expand Down

0 comments on commit 7ef3a32

Please sign in to comment.