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.
Website: https://buildingid.pnnl.gov/
Add this line to your application's Gemfile:
gem 'pnnl-building_id'
And then execute:
$ bundle
Or install it yourself as:
$ gem install pnnl-building_id
The pnnl-building_id
package supports one usage:
UBID codecs are encapsulated in separate modules:
PNNL::BuildingId::V3
(format: "C-n-e-s-w")Modules export the same API:
decode(String) ~> PNNL::BuildingId::CodeArea
encode(Float, Float, Float, Float, Float, Float, Integer) ~> String
encode_code_area(PNNL::BuildingId::CodeArea) ~> String
valid?(String) ~> Boolean
In the following example, a UBID code is decoded and then re-encoded:
# Use the "C-n-e-s-w" format for UBID codes.
require 'pnnl/building_id'
# Initialize UBID code.
code = '849VQJH6+95J-51-58-42-50'
$stdout.puts(code)
# Decode the UBID code.
code_area = PNNL::BuildingId::V3.decode(code)
$stdout.puts(code_area)
# Resize the resulting UBID code area.
#
# The effect of this operation is that the height and width of the UBID code
# area are reduced by half an OLC code area.
new_code_area = code_area.resize
$stdout.puts(new_code_area)
# Encode the new UBID code area.
new_code = PNNL::BuildingId::V3.encode_code_area(new_code_area)
$stdout.puts(new_code)
# Test that the new UBID code matches the original.
$stdout.puts(code == newCode)
The gem is available as open source under the terms of The 2-Clause BSD License.
Contributions are accepted on GitHub via the fork and pull request workflow. See here for more information.
FAQs
Unknown package
We found that pnnl-building_id demonstrated a not healthy version release cadence and project activity because the last version was released 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.