Thanks a lot
Hallo,
I would like to send emails from Nim using module smtp.
However, I need to include an attachment with the message.
Is it possible? If so, can you pls provide a code snippet to help me out?
Can you pls share some code / example related to web scraping? TIA
@Stefan_Salewski Awesome job! Thank you
Hallo, I'm running a Jester application and I would like to silent the message
"Jester is making jokes at...". Is it possible? Thanks in advance
https://forum.nim-lang.org/t/3288#20699
Hello,
I'm creating a REST microservice with Nim and Jester (in Windows). My API will
have just a few end-points and just a few simultaneously clients will consume
it. When I say 'few clients', I mean that at most just 3 concurrent users will
consume the API - if so. The JSON data returned per
Thank you. Worked as intented.
My final binary will be executed in a machine without the Nim source code. So,
the loadUnidecodeTable("lib/pure/unidecode/unidecode.dat") won't worked.
Is there a way to do the loadUnidecodeTable at compiled time only?
I recompiled my source with the `embedUnidecodeTable` symbol define. Now It is
all set.
Opencollective is also an option. (Got issues with Bounty Source too)
(NT)
Thank you guys !
One of the ways you feel motivated is to live in a community thanks guys
Hello,
Considering that I am a Windows user (since my childhood... just kidding), and
considering I was in great need of a way to work with Excel files, I am very
happy to have discovered Winim.
Practically all my problems are over! Great work @khchen !!
However, I have a question: given the
@wizzardx, I think it is possible to do so... but considering that @oyster has
supposedly already started a wrapper process with libxl, I figured we could
contribute something to it.
Hello @oyster
Ssorry to ask, but how is the process going with the libxl binding ?
I need to work with a project where reading and writing Excel files will be an
important prerequisite ... figuring that there is not yet a component in Nim to
get the job done, I will have to perform the
Hi, thanks for the help of all of you.
Yes, I'm pre-calculating things. In the data orchestration process I'm involved
in, I can usually estimate the time of a rendering based on the number of rows
I'm processing. It is a linear process and the processing time is typically not
much affected as
https://github.com/dom96/choosenim
@wizzardx, please, go ahead !
I think your initiative (following the idea of the cookbook concept of
@nimboolean) is completely valid
Anyway, @nimboolean already posted some interesting content at
[https://github.com/btbytes/nim-cookbook/](https://github.com/btbytes/nim-cookbook/).
So I think
Guys, thank you for your help.
@Stefan_Salewski, yes speed is an important point for me. I found the link you
provided (about SMID) very interesting ... however, I do not know how to do
this using Nim. Could you please help?
Even to help newbies like me, thought to include the response of this
@wizzardx This is nice. Your idea really makes more sense. Count on me to help.
How to configure a wiki ? What would be the best link (URL)?
@nimboolean, I will help you out with PRs you very soon... thanks
Hello,
Before processing a giant txt file, I need to know in advance how many lines
that file has. Since I will have to process multiple files it would be
important to perform this line counting operation as quickly as possible.
What is the fastest way to know how many lines a txt file has?
I
Thank you guys !
@mratsim, off topic:
[https://twitter.com/DeepMindAI/status/920696139657240576](https://twitter.com/DeepMindAI/status/920696139657240576)
Cool !!
@sky_khan, I agree with you. The more examples the better!
I am also learning Nim ... one of the main problems I had (and I have) is
precisely the absence of examples in the documentation.
In addition, I would kindly ask a favor for the older staff - please create
more examples in the
Hi, please consider the code below.
import json
var field1, field2, field3 : str
var jz : JsonNode
field1 = jz["node1"].getStr
field2 = jz["node2"].getStr
field3 = jz["node3"].getStr
Sometimes the nodes node1, node2 and/or node3 are available at my
Thanks for your advice. Cheers
Hallo,
Typically, I handle my data wranglers jobs using Python and Perl. I have a lot
of legacy code in both languages, so I need to find some free time to rewrite
all my stuff in Nim.
Sometimes, I need to extract key information from an unstructured data file...
and I would like to start
I'm using Nim to handle ZIP Code validation and address correction. It's a
fuzzy process of checking the postal address to ensure that the given ZIP Code
is correct. Nim should match the ZIP Code against the postal data file and
refers to the correct location and so on.
Given I'm not using any
Our **lovely Nim** is outstanding !
@zolern, thank you. Your code rocks.
However, we are cheating Julia because in her code there is a **POW** instead
**MOD**.
I will modify / rerun the .jl script just to check the result.
Thank you all.
@wiffel/Nibbler, in my Julia test, I was using Pro version 0.6.1 64 bit running
on Windows 10.
Now, running the same .jl code on a Windows 8 64 bit (i5 CPU 650 @ 3.20GHz,
3193 Mhz, 2 Cores, 4 Processors) I got the following:
2.763225 seconds (1.77 k allocations:
Hello,
How can I optimize the speed of the following proc:
import times, math
proc leibniz(terms: int): float =
var res = 0.0
for n in 0..terms:
res += pow(-1.0,float(n))/(2.0*float(n)+1.0)
return 4*res
let t0 = cpuTime()
Great Job !! Mine is on the way !
All the best.
Sounds interesting stuff:
[https://leanpub.com/create_languages](https://leanpub.com/create_languages)
Thank you all !
@Stevo, can you pls provide some examples of how to use it ?
Hello, Is there any In-Memory Database project around for Nim ? Or any wrapper
available for any of these
[https://githubreviews.com/explore/databases/popular-in-memory](https://githubreviews.com/explore/databases/popular-in-memory)
? TIA
Arne, pls, keep going with your videos. Well done. Thx.
Nice job Euan ! Thanks.
All the best guys !
Hello,
I'm trying to create a simple progress bar indicator. I'd like to print
(update) the bar always in the same line of the screen. Looking at the source
code of choosenim, I discovered eraseLine(). So, I made the following toy code:
import strutils, terminal
proc
The lib [https://libxlsxwriter.github.io](https://libxlsxwriter.github.io)
sounds very interesting, and it will be a great hand to help me out with my
first production job with Nim.
However, can you pls provide some directions of how to call a C function (of
libxlsxwriter) within my Nim code ?
I received this from Manning support:
"This title is scheduled for release on May 29th"
Cool ! Awesome and nice job !!
Hello,
I read that there are some arcade / indie games made in Nim.
Is there a list of them ? Any opensource ?
Cheers
Just downloaded my eBook !! It rocks !
Cheers
@pdv, thank you for your support. Can you pls kindly help me to fix my code ? I
tried to rewrite it following the description of the provided branch, but I got
no success. I think I'm missing some key concept. All the best, AN
Greetings,
I'm trying to consume an JSON API, but I need to pass some Headers along my GET
call.
My code is the following:
import httpclient, json
let client = newHttpClient()
client.headers = newHttpHeaders({ "Content-Type": "application/json" })
let body =
Hello,
As my Nim codes are growing in size and in complexity, my echos are no longer
being productive to help me out. So, I need a recommendation about the best way
to debug my stuffs.
Is there any Nim debugger around (for Windows) ? I'm just looking for a way to
inspect variables giving a
Im using Nim 0.15 with -d:release and --opt:speed.
My Python is a 64 bit v2.7.12 without Pypy.
I need SQLite mainly because it is a part of a desktop app, where any other SQL
server is not suitable. And BTW this .db3 is used just for readonly operations.
No CUD is done there.
Thank you for the support guys.
The weird statements surrounding the operations with SQL were created just for
benchmarking's sake with Python.
Anyways, optimizing the handlers of the CSV, due it is not that big, brought no
real gain of performance. Comparing the elapsed time of Nim and
Greetings,
I have a big production SQLite table with 4 Gig+ and around 12M records. (named
mydb.db3)
The code below is looking for 10 records (of lookup_input.csv) at mydb using
the FTS feature available at SQLite.
Given the thread
Surely... will do that. Thanks
Thank you for the kindly comments.
Actually, my final goal is to migrate some of my Python codes to Nim. My
knowledge with C (and Nim) is rudimentary yet.
I do have a plenty number of taylor made functions in Python, which I guess I'm
gonna spend some time migrating to Nim. So, given Nim has a
Hello there,
I have the following C code (this one removes adjacent duplicates in a string):
// myccode.c
const char* change(char *str) {
int i=1;
int j=1;
int k;
int d=0;
while(str[i]!='\0') {
if(str[i-1]==str[i]) {
@all, thanks a lot.
Yeap, I know. What's the best way to implement your proc translate ?
Say I have an input string like "Cédille Français". How can I use the proc with
it ?
Sorry my basic questions, but I am a pretty new with Nim... Cheers
Hello,
I am trying to replace the accented letters in a given text with their
unaccented counterparts.
What is the best way to write the following C code in Nim ?
char p_RemoveAccent(char C)
{
#define ACCENT_CHARS"ÁÀÃÂÇáàãâçÉÊéêÍíÑÓÔÕñóôõÚÜúü"
#define
Yeap, I agree. Very nice job !
@wolf, thank you for your help !
@andrea, I'll have a look at nim-pymod.
Cheers
Yes ! It worked for me as well (in Windows). Thanks a lot Wolf.
However, I noticed the Nim Soundex function
([https://github.com/Skrylar/Skylight](https://github.com/Skrylar/Skylight))
expects for a single token not for a full string. So, I made some chances in
the Python code to properly
I tried with c_wchar_p, as well as, with c_char_p. Either way, didn't work.
mystring = c_char_p("robert james fischer")
test_lib.AmericanSoundex.argtype = c_char_p
test_lib.AmericanSoundex.restype = c_char_p
soundex_res = test_lib.AmericanSoundex(mystring)
print('The
Hello
I made some experiences connecting Nim with Python. At this page
[http://akehrer.github.io/posts/connecting-nim-to-python](http://forum.nim-lang.org///akehrer.github.io/posts/connecting-nim-to-python)/
there are some cool hints about how to do that. However, I got some issues
interfacing
Hello,
I am trying to compile
[https://github.com/wheineman/nrpl](https://github.com/wheineman/nrpl) but I
got the following error: nrpl.nim(116, 42) Error: attempting to call undeclared
routine: 'map'. TCC is installed and in my windows path.
Cheers
Solved: I just copied the latest SQlite 32 & 64 bit DLLs to nimbin folder (and
renamed them to sqlite3_32.dll and sqlite3_64.dll). The native Nim package is
using dated DLLs.
BTW, there are typos in my former code. The correct is the following:
import db_sqlite, math
let
65 matches
Mail list logo