copyparty 1.15.4__py3-none-any.whl → 1.15.5__py3-none-any.whl

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.
copyparty/__init__.py CHANGED
@@ -105,7 +105,6 @@ RES = set(zs.strip().split("\n"))
105
105
 
106
106
  class EnvParams(object):
107
107
  def __init__(self) :
108
- self.pkg = None
109
108
  self.t0 = time.time()
110
109
  self.mod = ""
111
110
  self.cfg = ""
copyparty/__main__.py CHANGED
@@ -212,7 +212,6 @@ def init_E(EE ) :
212
212
 
213
213
  raise Exception("could not find a writable path for config")
214
214
 
215
- E.pkg = sys.modules[__package__]
216
215
  E.mod = os.path.dirname(os.path.realpath(__file__))
217
216
  if E.mod.endswith("__init__"):
218
217
  E.mod = os.path.dirname(E.mod)
copyparty/__version__.py CHANGED
@@ -1,8 +1,8 @@
1
1
  # coding: utf-8
2
2
 
3
- VERSION = (1, 15, 4)
3
+ VERSION = (1, 15, 5)
4
4
  CODENAME = "fill the drives"
5
- BUILD_DT = (2024, 10, 4)
5
+ BUILD_DT = (2024, 10, 5)
6
6
 
7
7
  S_VERSION = ".".join(map(str, VERSION))
8
8
  S_BUILD_DT = "{0:04d}-{1:02d}-{2:02d}".format(*BUILD_DT)
copyparty/util.py CHANGED
@@ -3532,9 +3532,9 @@ def stat_resource(E , name ):
3532
3532
  return None
3533
3533
 
3534
3534
 
3535
- def _find_impresource(E , name ):
3535
+ def _find_impresource(pkg , name ):
3536
3536
  try:
3537
- files = impresources.files(E.pkg)
3537
+ files = impresources.files(pkg)
3538
3538
  except ImportError:
3539
3539
  return None
3540
3540
 
@@ -3544,7 +3544,7 @@ def _find_impresource(E , name ):
3544
3544
  _rescache_has = {}
3545
3545
 
3546
3546
 
3547
- def _has_resource(E , name ):
3547
+ def _has_resource(name ):
3548
3548
  try:
3549
3549
  return _rescache_has[name]
3550
3550
  except:
@@ -3553,14 +3553,16 @@ def _has_resource(E , name ):
3553
3553
  if len(_rescache_has) > 999:
3554
3554
  _rescache_has.clear()
3555
3555
 
3556
+ pkg = sys.modules[__package__]
3557
+
3556
3558
  if impresources:
3557
- res = _find_impresource(E, name)
3559
+ res = _find_impresource(pkg, name)
3558
3560
  if res and res.is_file():
3559
3561
  _rescache_has[name] = True
3560
3562
  return True
3561
3563
 
3562
3564
  if pkg_resources:
3563
- if _pkg_resource_exists(E.pkg.__name__, name):
3565
+ if _pkg_resource_exists(pkg.__name__, name):
3564
3566
  _rescache_has[name] = True
3565
3567
  return True
3566
3568
 
@@ -3569,14 +3571,14 @@ def _has_resource(E , name ):
3569
3571
 
3570
3572
 
3571
3573
  def has_resource(E , name ):
3572
- return _has_resource(E, name) or os.path.exists(os.path.join(E.mod, name))
3574
+ return _has_resource(name) or os.path.exists(os.path.join(E.mod, name))
3573
3575
 
3574
3576
 
3575
3577
  def load_resource(E , name , mode="rb") :
3576
3578
  enc = None if "b" in mode else "utf-8"
3577
3579
 
3578
3580
  if impresources:
3579
- res = _find_impresource(E, name)
3581
+ res = _find_impresource(sys.modules[__package__], name)
3580
3582
  if res and res.is_file():
3581
3583
  if enc:
3582
3584
  return res.open(mode, encoding=enc)
@@ -3585,8 +3587,9 @@ def load_resource(E , name , mode="rb") :
3585
3587
  return res.open(mode)
3586
3588
 
3587
3589
  if pkg_resources:
3588
- if _pkg_resource_exists(E.pkg.__name__, name):
3589
- stream = pkg_resources.resource_stream(E.pkg.__name__, name)
3590
+ pkg = sys.modules[__package__]
3591
+ if _pkg_resource_exists(pkg.__name__, name):
3592
+ stream = pkg_resources.resource_stream(pkg.__name__, name)
3590
3593
  if enc:
3591
3594
  stream = codecs.getreader(enc)(stream)
3592
3595
  return stream
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: copyparty
3
- Version: 1.15.4
3
+ Version: 1.15.5
4
4
  Summary: Portable file server with accelerated resumable uploads, deduplication, WebDAV, FTP, zeroconf, media indexer, video thumbnails, audio transcoding, and write-only folders
5
5
  Author-email: ed <copyparty@ocv.me>
6
6
  License: MIT
@@ -831,6 +831,7 @@ semi-intentional limitations:
831
831
 
832
832
  * cleanup of expired shares only works when global option `e2d` is set, and/or at least one volume on the server has volflag `e2d`
833
833
  * only folders from the same volume are shared; if you are sharing a folder which contains other volumes, then the contents of those volumes will not be available
834
+ * related to [IdP volumes being forgotten on shutdown](https://github.com/9001/copyparty/blob/hovudstraum/docs/idp.md#idp-volumes-are-forgotten-on-shutdown), any shares pointing into a user's IdP volume will be unavailable until that user makes their first request after a restart
834
835
  * no option to "delete after first access" because tricky
835
836
  * when linking something to discord (for example) it'll get accessed by their scraper and that would count as a hit
836
837
  * browsers wouldn't be able to resume a broken download unless the requester's IP gets allowlisted for X minutes (ref. tricky)
@@ -1,6 +1,6 @@
1
- copyparty/__init__.py,sha256=wkz_fW1qOsy4bUb6UOX45wyoM6eMXZrH_pbbJTHyhx4,2622
2
- copyparty/__main__.py,sha256=haJukP40kmpE0HidO3bY2mmohe-H4ih_cwFTullxrlE,109570
3
- copyparty/__version__.py,sha256=QdadkcRd9LbeLxEk1w-II6vFXxoK9pVhEgKcLiaEbOQ,257
1
+ copyparty/__init__.py,sha256=Chqw7uXX4r_-a2p6-xthrrqVHFI4aZdW45sWU7UvqeE,2597
2
+ copyparty/__main__.py,sha256=igXfkIk20dnXiMD3bOgmomv2m1_STd46QADrPb52P6E,109533
3
+ copyparty/__version__.py,sha256=kIxyRw7J4J4tZ35LfBec0gjCU3PVbEq-j0P5Esc6kXw,257
4
4
  copyparty/authsrv.py,sha256=Uw_RaCJIsXUzjYih4R2VLQOkDfUePLfidiW5ERvCtMo,98670
5
5
  copyparty/broker_mp.py,sha256=jsHUM2BSfRVRyZT869iPCqYEHSqedk6VkwvygZwbEZE,4017
6
6
  copyparty/broker_mpw.py,sha256=PYFgQfssOCfdI6qayW1ZjO1j1-7oez094muhYMbPOz0,3339
@@ -32,7 +32,7 @@ copyparty/th_cli.py,sha256=o6FMkerYvAXS455z3DUossVztu_nzFlYSQhs6qN6Jt8,4636
32
32
  copyparty/th_srv.py,sha256=hI9wY1E_9N9Cgqvtr8zADeVqqiLGTiTdAnYAA7WFvJw,29346
33
33
  copyparty/u2idx.py,sha256=JjgqwgJBNj6sTn4PJfuqM3VEHqlmoyGC5bk4_92K2h0,13414
34
34
  copyparty/up2k.py,sha256=TzCNQKiC-fxfV2EpXdy1oCA3yExpHyzrH6BmgFrTrJg,163817
35
- copyparty/util.py,sha256=B9BhffBGsRE7f48078646gDABNVerSAuM8EbQpAjlxY,91242
35
+ copyparty/util.py,sha256=RrL6SBjgeVTyXZdZQ8RRFVQn72Jz0Y6DTGYr4LO3Phc,91329
36
36
  copyparty/bos/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
37
37
  copyparty/bos/bos.py,sha256=Wb7eWsXJgR5AFlBR9ZOyKrLTwy-Kct9RrGiOu4Jo37Y,1622
38
38
  copyparty/bos/path.py,sha256=yEjCq2ki9CvxA5sCT8pS0keEXwugs0ZeUyUhdBziOCI,777
@@ -106,9 +106,9 @@ copyparty/web/deps/prismd.css.gz,sha256=ObUlksQVr-OuYlTz-I4B23TeBg2QDVVGRnWBz8cV
106
106
  copyparty/web/deps/scp.woff2,sha256=w99BDU5i8MukkMEL-iW0YO9H4vFFZSPWxbkH70ytaAg,8612
107
107
  copyparty/web/deps/sha512.ac.js.gz,sha256=lFZaCLumgWxrvEuDr4bqdKHsqjX82AbVAb7_F45Yk88,7033
108
108
  copyparty/web/deps/sha512.hw.js.gz,sha256=vqoXeracj-99Z5MfY3jK2N4WiSzYQdfjy0RnUlQDhSU,8110
109
- copyparty-1.15.4.dist-info/LICENSE,sha256=gOr4h33pCsBEg9uIy9AYmb7qlocL4V9t2uPJS5wllr0,1072
110
- copyparty-1.15.4.dist-info/METADATA,sha256=BpkzqpVDqywI5NP2j8_M_ccH12Ym3p4wUnNE9sdzYVs,135552
111
- copyparty-1.15.4.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
112
- copyparty-1.15.4.dist-info/entry_points.txt,sha256=4zw6a3rqASywQomiYLObjjlxybaI65LYYOTJwgKz7b0,128
113
- copyparty-1.15.4.dist-info/top_level.txt,sha256=LnYUPsDyk-8kFgM6YJLG4h820DQekn81cObKSu9g-sI,10
114
- copyparty-1.15.4.dist-info/RECORD,,
109
+ copyparty-1.15.5.dist-info/LICENSE,sha256=gOr4h33pCsBEg9uIy9AYmb7qlocL4V9t2uPJS5wllr0,1072
110
+ copyparty-1.15.5.dist-info/METADATA,sha256=o3EaYdn7-JhJSuNd838dMe48Lv4KAberuypcFv5v03Q,135833
111
+ copyparty-1.15.5.dist-info/WHEEL,sha256=GV9aMThwP_4oNCtvEC2ec3qUYutgWeAzklro_0m4WJQ,91
112
+ copyparty-1.15.5.dist-info/entry_points.txt,sha256=4zw6a3rqASywQomiYLObjjlxybaI65LYYOTJwgKz7b0,128
113
+ copyparty-1.15.5.dist-info/top_level.txt,sha256=LnYUPsDyk-8kFgM6YJLG4h820DQekn81cObKSu9g-sI,10
114
+ copyparty-1.15.5.dist-info/RECORD,,