Research
Security News
Malicious npm Package Targets Solana Developers and Hijacks Funds
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
More Data Structures
or more-ds
for short,
provides simple and convenient Python data structures.
SemVer
Class for easy creation of semantic version numbers.
URL
Class for easy (unvalidated) URL construction.
Timer
Context manager for timing a block of code.
.. code-block:: console
% pip install more-ds
.. code-block:: python
>>> from more_ds.network import URL
>>> base_url = URL("http://example.org/")
>>> api_url = base_url / "api"
>>> url = api_url / "ip" / "address" // dict(version=4)
>>> print(url)
http://example.org/api/ip/address?version=4
Or
.. code-block:: python
from time import sleep
from more_ds.time import Timer
with Timer() as t:
# sleep for half a second
sleep(.5)
print(t.elapsed) # -> 0:00:00.501864
Or
.. code-block:: python
>>> from more_ds.id import SemVer
>>> old = SemVer("v3.1.4")
>>> new = SemVer("3.2")
>>> old
SemVer("3.1.4")
>>> new
SemVer("3.2.0")
>>> old == new
False
>>> old < new
True
>>> old > new
False
>>> repr(old)
'SemVer("3.1.4")'
>>> repr(new)
'SemVer("3.2.0")'
>>> isinstance(old, str)
True
The projected started
with the need to extract the simplest of classes
from an existing open source library, nwa-stdlib
.
That library primarily contained code
that was rather specific to the organization that created the library.
However, the URL
class was a tiny convenience data structure,
with broader applicability,
that took the chore out of programmatically creating URLs.
By extracting that class into a separate project,
one that is specifically focussed on convenient data structures,
it hopefully attracts a broader set of users
that would otherwise don't feel comfortable including nwa-stdlib
as a whole.
The project's name was inspired by the wonderful More Itertools
_ library.
.. _nwa-stdlib: https://github.com/workfloworchestrator/nwa-stdlib .. _More Itertools: https://more-itertools.readthedocs.io/en/stable/index.html
FAQs
More Data Structures
We found that more-ds demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A malicious npm package targets Solana developers, rerouting funds in 2% of transactions to a hardcoded address.
Security News
Research
Socket researchers have discovered malicious npm packages targeting crypto developers, stealing credentials and wallet data using spyware delivered through typosquats of popular cryptographic libraries.
Security News
Socket's package search now displays weekly downloads for npm packages, helping developers quickly assess popularity and make more informed decisions.