Was ist der unterschied zwischen blob und text

Guten Abend zusammen,

ich habe ein Problem mit Python. Ich habe ein Projekt in Node.js, für welches ich in Python eine GUI geschrieben habe (für die 'normalen' Benutzer). Ich habe es auch schon getestet - es funktioniert alles soweit. Mein Problem ist jetzt nur, wie ich das ganze in eine Exe-Datei kompilieren kann. Ich habe den pyinstaller installiert und mir sind auch die Komandozeilenoptionen --add-data , --add-binary oder die Konfiguration über die .spec Datei bekannt, wobei ich letzteres bevorzuge.

Beispiel zur .spec-Datei:

# -*- mode: python -*- block_cipher = None a = Analysis(['test.py'], pathex=['C:\\Users\\Admin\\Desktop\\___'], binaries=[], datas=[ ('testdatei.txt', '.')#<<-- Problem ], hiddenimports=[], hookspath=[], runtime_hooks=[], excludes=[], win_no_prefer_redirects=False, win_private_assemblies=False, cipher=block_cipher) pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher) exe = EXE(pyz, a.scripts, a.binaries, a.zipfiles, a.datas, name='test', debug=False, strip=False, upx=True, runtime_tmpdir=None, console=True )

Ich habe die Stelle gekennzeichnet, die das Problem darstellt. Wenn ich irgendwelche Dateien mit in die .exe Datei packen will, bekomme ich keinen Fehler und muss so also annehmen, dass sie hinzugefügt wurden. Hier soll eine Datei, testdatei.txt, die sich im gleichen Verzeichnis wie das Hauptskript auch in das root Verzeichnis (das oberste) in der .exe kopiert werden. In meiner Datei test.py habe ich folgenden Code:

# coding=UTF-8 datei = open('testdatei.txt') print(datei.read()) datei.close()

Es soll also nur die Datei testdatei.txt im gleichen Verzeichnis wie das Skript ausgelesen werden. Wenn ich es über die Konsole oder direkt über Python ausführe funktioniert es ganz normal. Wenn ich es aber mit pyinstaller test.spec zuerst in eine .exe packe, bekomme ich immer den Fehler, dass die Datei nicht gefunden wurde.

Habe ich irgendetwas falsch gemacht? Okay dumme Frage - natürlich ist etwas falsch aber hättest du eine Idee? Ich habe auch schon oft den 'magic comment' #!/usr/bin/python gesehen. Ich verstehe aber nicht wirklich, für was er ist, was ich damit machen muss oder ob/wie ich ihn anpassen muss.

Ich bin für jede Antwort dankbar, die irgendetwas hiermit zu tun hat!

Liebe Grüße

Win7User

PS: Mein Betriebssystem: Windows 7 Pro 64-bit / Windows 7 Ultimate 32-bit

Meine Python Version: 2.7.14

Skip to main content

This browser is no longer supported.

Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.

Comparing Azure Data Lake Storage Gen1 and Azure Blob Storage

  • Article
  • 09/23/2021
  • 2 minutes to read

In this article

The table in this article summarizes the differences between Azure Data Lake Storage Gen1 and Azure Blob Storage along some key aspects of big data processing. Azure Blob Storage is a general purpose, scalable object store that is designed for a wide variety of storage scenarios. Azure Data Lake Storage Gen1 is a hyper-scale repository that is optimized for big data analytics workloads.

CategoryAzure Data Lake Storage Gen1Azure Blob Storage
Purpose Optimized storage for big data analytics workloads General purpose object store for a wide variety of storage scenarios, including big data analytics
Use Cases Batch, interactive, streaming analytics and machine learning data such as log files, IoT data, click streams, large datasets Any type of text or binary data, such as application back end, backup data, media storage for streaming and general purpose data. Additionally, full support for analytics workloads; batch, interactive, streaming analytics and machine learning data such as log files, IoT data, click streams, large datasets
Key Concepts Data Lake Storage Gen1 account contains folders, which in turn contains data stored as files Storage account has containers, which in turn has data in the form of blobs
Structure Hierarchical file system Object store with flat namespace
API REST API over HTTPS REST API over HTTP/HTTPS
Server-side API WebHDFS-compatible REST API Azure Blob Storage REST API
Hadoop File System Client Yes Yes
Data Operations - Authentication Based on Azure Active Directory Identities Based on shared secrets - Account Access Keys and Shared Access Signature Keys.
Data Operations - Authentication Protocol OpenID Connect. Calls must contain a valid JWT (JSON web token) issued by Azure Active Directory. Hash-based Message Authentication Code (HMAC). Calls must contain a Base64-encoded SHA-256 hash over a part of the HTTP request.
Data Operations - Authorization POSIX Access Control Lists (ACLs). ACLs based on Azure Active Directory Identities can be set at the file and folder level. For account-level authorization – Use Account Access Keys
For account, container, or blob authorization - Use Shared Access Signature Keys
Data Operations - Auditing Available. See here for information. Available
Encryption data at rest
  • Transparent, Server side
    • With service-managed keys
    • With customer-managed keys in Azure KeyVault
  • Transparent, Server side
    • With service-managed keys
    • With customer-managed keys in Azure KeyVault (preview)
  • Client-side encryption
Management operations (for example, Account Create) Azure role-based access control (Azure RBAC) for account management Azure role-based access control (Azure RBAC) for account management
Developer SDKs .NET, Java, Python, Node.js .NET, Java, Python, Node.js, C++, Ruby, PHP, Go, Android, iOS
Analytics Workload Performance Optimized performance for parallel analytics workloads. High Throughput and IOPS. Optimized performance for parallel analytics workloads.
Size limits No limits on account sizes, file sizes, or number of files For specific limits, see Scalability targets for standard storage accounts and Scalability and performance targets for Blob storage. Larger account limits available by contacting Azure Support
Geo-redundancy Locally redundant (multiple copies of data in one Azure region) Locally redundant (LRS), zone redundant (ZRS), globally redundant (GRS), read-access globally redundant (RA-GRS). See here for more information
Service state Generally available Generally available
Regional availability See here Available in all Azure regions
Price See Pricing See Pricing

Feedback

Submit and view feedback for

Toplist

Neuester Beitrag

Stichworte