pidibble 1.4.1__tar.gz → 1.4.2__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.
Files changed (52) hide show
  1. {pidibble-1.4.1 → pidibble-1.4.2}/PKG-INFO +3 -1
  2. {pidibble-1.4.1 → pidibble-1.4.2}/README.md +2 -0
  3. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/pdbparse.py +2 -2
  4. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/pdbrecord.py +3 -0
  5. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/resources/pdb_format.yaml +2 -1
  6. {pidibble-1.4.1 → pidibble-1.4.2}/pyproject.toml +1 -1
  7. {pidibble-1.4.1 → pidibble-1.4.2}/.github/workflows/release.yaml +0 -0
  8. {pidibble-1.4.1 → pidibble-1.4.2}/.gitignore +0 -0
  9. {pidibble-1.4.1 → pidibble-1.4.2}/.readthedocs.yaml +0 -0
  10. {pidibble-1.4.1 → pidibble-1.4.2}/LICENSE +0 -0
  11. {pidibble-1.4.1 → pidibble-1.4.2}/MANIFEST.in +0 -0
  12. {pidibble-1.4.1 → pidibble-1.4.2}/docs/Makefile +0 -0
  13. {pidibble-1.4.1 → pidibble-1.4.2}/docs/make.bat +0 -0
  14. {pidibble-1.4.1 → pidibble-1.4.2}/docs/requirements.txt +0 -0
  15. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/_static/css/custom.css +0 -0
  16. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/API.rst +0 -0
  17. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.baseparsers.rst +0 -0
  18. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.baserecord.rst +0 -0
  19. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.hex.rst +0 -0
  20. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.mmcif_parse.rst +0 -0
  21. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.pdbparse.rst +0 -0
  22. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.pdbrecord.rst +0 -0
  23. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.resources.rst +0 -0
  24. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/api/pidibble.rst +0 -0
  25. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/conf.py +0 -0
  26. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/index.rst +0 -0
  27. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/installation.rst +0 -0
  28. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/notes.md +0 -0
  29. {pidibble-1.4.1 → pidibble-1.4.2}/docs/source/usage.rst +0 -0
  30. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/__init__.py +0 -0
  31. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/baseparsers.py +0 -0
  32. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/baserecord.py +0 -0
  33. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/hex.py +0 -0
  34. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/mmcif_parse.py +0 -0
  35. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/resources/__init__.py +0 -0
  36. {pidibble-1.4.1 → pidibble-1.4.2}/pidibble/resources/mmcif_format.yaml +0 -0
  37. {pidibble-1.4.1 → pidibble-1.4.2}/tests/__init__.py +0 -0
  38. {pidibble-1.4.1 → pidibble-1.4.2}/tests/conftest.py +0 -0
  39. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_hex/my_system.pdb +0 -0
  40. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_hex.py +0 -0
  41. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/4tvp.cif +0 -0
  42. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/4tvp.pdb +0 -0
  43. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/4zmj-newresnames.pdb +0 -0
  44. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/4zmj.cif +0 -0
  45. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/4zmj.pdb +0 -0
  46. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/6m0j.pdb +0 -0
  47. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/8fae.cif +0 -0
  48. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/G.pdb +0 -0
  49. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/GG.pdb +0 -0
  50. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/test.pdb +0 -0
  51. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb/test_pdb_format.yaml +0 -0
  52. {pidibble-1.4.1 → pidibble-1.4.2}/tests/unit/test_rcsb.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pidibble
3
- Version: 1.4.1
3
+ Version: 1.4.2
4
4
  Summary: A complete Protein Data Bank (PDB) file parser
5
5
  Project-URL: Source, https://github.com/cameronabrams/pidibble
6
6
  Project-URL: Documentation, https://pidibble.readthedocs.io/en/latest/
@@ -91,6 +91,8 @@ ATOM
91
91
  ```
92
92
 
93
93
  ## Release History
94
+ * 1.4.2
95
+ * updated alphafold interface
94
96
  * 1.4.1
95
97
  * Fixed parsing bug in `PDBRecordList`
96
98
  * 1.4.0
@@ -73,6 +73,8 @@ ATOM
73
73
  ```
74
74
 
75
75
  ## Release History
76
+ * 1.4.2
77
+ * updated alphafold interface
76
78
  * 1.4.1
77
79
  * Fixed parsing bug in `PDBRecordList`
78
80
  * 1.4.0
@@ -14,7 +14,6 @@ import yaml
14
14
  import numpy as np
15
15
  from pathlib import Path
16
16
  from mmcif.io.IoAdapterCore import IoAdapterCore
17
- from typing import List, Dict
18
17
  from . import resources
19
18
  from .baseparsers import ListParsers, ListParser, str2int_sig, safe_float
20
19
  from .baserecord import BaseRecordParser
@@ -144,8 +143,9 @@ class PDBParser:
144
143
  self.filepath=f'{self.alphafold}.pdb'
145
144
  BASE_URL=self.pdb_format_dict['ALPHAFOLD_API_URL']
146
145
  target_url=os.path.join(BASE_URL,self.alphafold)
146
+ logger.debug(f'target url {target_url}')
147
147
  try:
148
- urllib.request.urlretrieve(target_url,f'{self.alphafold}.json')
148
+ urllib.request.urlretrieve(target_url+r'?key='+self.pdb_format_dict['ALPHAFOLD_API_KEY'],f'{self.alphafold}.json')
149
149
  except:
150
150
  logger.warning(f'Could not fetch metadata for entry with accession code {self.alphafold} from AlphaFold')
151
151
  return False
@@ -132,6 +132,9 @@ class PDBRecord(BaseRecord):
132
132
  inst.format=current_format
133
133
  return inst
134
134
 
135
+ def __repr__(self):
136
+ return f'<PDBRecord {self.__dict__}>'
137
+
135
138
  def get_token(self,key):
136
139
  """
137
140
  Retrieve a token value from the PDBRecord instance based on the provided key.
@@ -11,7 +11,8 @@
11
11
  # 1. 28-FEB-2024: Alphafold stuff
12
12
  #
13
13
  BASE_URL: https://files.rcsb.org/download
14
- ALPHAFOLD_API_URL: https://alphafold.com/api/prediction
14
+ ALPHAFOLD_API_URL: https://alphafold.ebi.ac.uk/api/prediction
15
+ ALPHAFOLD_API_KEY: AIzaSyCeurAJz7ZGjPQUtEaerUkBZ3TaBkXrY94
15
16
  record_types:
16
17
  1: one-time-single-line
17
18
  2: one-time-multiple-line
@@ -3,7 +3,7 @@ requires = ["hatchling"]
3
3
  build-backend = "hatchling.build"
4
4
  [project]
5
5
  name = "pidibble"
6
- version = "1.4.1"
6
+ version = "1.4.2"
7
7
  authors = [
8
8
  { name="Cameron F Abrams", email="cfa22@drexel.edu" },
9
9
  ]
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes