Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Converts a CSV formatted input to a readable table in text. The table is Markdown compatible.
Install package using pip:
python -m pip install csvtables
You can use the package directly in the terminal or by importing it in a python script.
csvtables --help
Let's assume we have the following text file which is located in tests/sample_data.csv
(reference: https://en.wikipedia.org/wiki/List_of_galaxies#Closest_galaxies):
Rank,Galaxy,Distance
1,Milky Way Galaxy,0
2,Canis Major Dwarf,0.025 Mly
3,Virgo Stellar Stream,0.030 Mly
4,Sagittarius Dwarf Elliptical Galaxy,0.081 Mly
5,Large Magellanic Cloud,0.163 Mly
6,Small Magellanic Cloud,0.197 Mly
The table is generated by running:
csvtables closest_galaxies.csv
and should produce the following output:
| Rank | Galaxy | Distance |
|------|-------------------------------------|-----------|
| 1 | Milky Way Galaxy | 0 |
| 2 | Canis Major Dwarf | 0.025 Mly |
| 3 | Virgo Stellar Stream | 0.030 Mly |
| 4 | Sagittarius Dwarf Elliptical Galaxy | 0.081 Mly |
| 5 | Large Magellanic Cloud | 0.163 Mly |
| 6 | Small Magellanic Cloud | 0.197 Mly |
# example.py
from csvtables import csvtables
csv_file = open("tests/sample_data.csv", "r")
table = csvtables.CSVTable(csv_file)
print(table.generate_table()) # display the table to stdout
FAQs
Convert a CSV formatted input to a readable table in text
We found that csvtables 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.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.