Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • May 27 06:08
    User @Mitzi-Laszlo unbanned @in1t3r
  • May 23 06:49
    @Mitzi-Laszlo banned @in1t3r
  • May 16 09:49
    @Mitzi-Laszlo banned @mediaprophet
  • Feb 01 22:04
    User @melvincarvalho unbanned @namedgraph_twitter
  • Feb 01 21:49
    @melvincarvalho banned @namedgraph_twitter
Fabian Cook
@fabiancook
@theWebalyst within your module, maybe completely leave out the rdflib dependency, and instead of a dev/peer dependency, then have provided at runtime
Mark Hughes (happybeing)
@theWebalyst
How would I do that?
Fabian Cook
@fabiancook
By doing this with us much as you can, you can reduce coupling... for example I have an fs compatible implementation provided to one of my modules via an options object...
// These are all the functions we utilise
// If a method requires a specific function that isn't provided
// then the method won't be available
export type FSCompatible = {
  unlink?: typeof fs.unlink,
  lstat?: typeof fs.lstat,
  chmod?: typeof fs.chmod,
  stat: typeof fs.stat,
  rmdir?: typeof fs.rmdir,
  readdir?: typeof fs.readdir,
  readFile?: typeof fs.readFile,
  writeFile?: typeof fs.writeFile
};

export type FSStoreOptions = {
  fs: FSCompatible;
}
It would require you to follow a model where you can pass that options object around though...
Mark Hughes (happybeing)
@theWebalyst
Thanks, I don't understand this. Can you link to the repo so I can see it in context?
I'm not sure if I'll have the flexibility to do something like this, but it will be useful to understand the design pattern regardless.
Mark Hughes (happybeing)
@theWebalyst
Cool, thanks very much!
Fabian Cook
@fabiancook
You'll see the same pattern throughout my projects
The reasoning behind this... I can now run an almost fully solid compatible implementation in the browser, in react native, and on the server, which can also be deployed in a serverless environment, no dependency on express, or node, or even having a persistent filesystem... if you wanted to just use your normal filesystem in node.js, fine, just pass the fs module no problem, if you want to use anywhere else, use hyperdrive
Arne Hassel
@megoth_twitter
That's sounds like a good setup ^_^
Fabian Cook
@fabiancook
Next week will be hooking this all up with the databrowser & making it work without solid...
Because of all of this, you can also compose a setup where there is no auth required, so just query something directly. And once I have implemented this... https://github.com/o-network/http-copy-symlink/blob/master/README.md... I will be able to define a template for a pod externally & just clone it, template could be on git, another pod, or on dat/ipfs/whatever
Arne Hassel
@megoth_twitter
@fabiancook very happy to read about the data browser - let me know if you get any problem with the work we at inrupt has started to improve it ^_^
Fabian Cook
@fabiancook
I would be great if I could have support or recommendations on the copy via symlink front... I think it would be a great addition to solid, and I could build an implementation (this would be true either way) that supports NSS as well as my implementation
(everything I have built can also replace said component within NSS AFAIK with no problem)
Mark Hughes (happybeing)
@theWebalyst

Update on circular dependencies - I tried some of the hacks from StackExchange here without success so far. I don't really understand how all this works well enough, so I might not be applying the right things in the right place but that's nothing new for me with nodejs!

I'm curious though that from the initial responses, people say npm should take care of this. This makes me wonder if the issue is during development because I'm using yarn link rdflib in safenetworkjs. Again I don't understand how node modules are processed well enough to think about this.

I may have to resort to something crude like inserting the functionality on a global object. I wanted to avoid that so that the only change needed to a Solid app would be to use a different solid-auth-client, and not change any of the code itself.

So I'm going back to thinking a Solid app would use a SAFE compatible solid-auth-client as follows:

In browser script:

window.safeJs = require(safenetworkjs).safeJs
auth = require(solid-auth-client).auth

or nodejs:

safeJs = require(safenetworkjs).safeJs
auth = require(solid-auth-client).auth

or in html:

<script src='safenetworkjs.js'></src>
<script src='solid-auth-client.bundle.js'></src>
Scott McWhirter
@konobi
use of link can be handy, but it's a bit of a footgun in my experience, so I've always avoided it
Mark Hughes (happybeing)
@theWebalyst
How do you develop without it?
footgun - not heard that before! :laughing:
Scott McWhirter
@konobi
@theWebalyst I just do? If I have a complex arrangement between various packages, I'd tend to tweak the npm package.json to point directly to the path of where the dependent scratchpad space is rather than just a name
if it's a little further out of a boundary between more than one dev and production env, npm scopes would come into play
Mark Hughes (happybeing)
@theWebalyst
Thanks, will give that a go.
Dmitri Zagidulin
@dmitrizagidulin
Solid Community meeting call is starting: https://www.w3.org/community/solid/wiki/Meetings
Mark Hughes (happybeing)
@theWebalyst
Grrr, your suggestion sounded so promising @konobi but I now get the memory allocation error while doing the 'npm install' of my local rdflib! It may help me isolate the problem all the same and its good to have another tool in the bag, so thanks for the suggestion.
Mitzi László
@Mitzi-Laszlo
@fabiancook the people on the other hemisphere W3C Solid Community Group call were keen to hear more about the conversation you raised last week on "HTTP Signatures & possible deprecation of WebID + TLS and DDI vs HTTP URI for WebID https://w3c-ccg.github.io/did-primer/" @elf-pavlik had some questions. Any chance you could enhance the minutes and explain your thoughts to make sure we're all in sync.
Michael Pigott
@mikepigott
Yes! I am building my own SoLiD server in Scala / Play (unfortunately the rww_play project seems to be abandoned), and of course, the first thing I implemented was WebID-TLS. https://github.com/ironhorsesoftware/webid-tls-jsse So I’m a little biased :-)
I wasn’t sure how I felt about WebID-TLS at the beginning, but I like it a lot more now that I’ve implemented it. So I personally agree it shouldn’t be the primary authentication mechanism ( https://github.com/solid/solid-spec#primary-authentication ), or even a required one, but I’m not sure it should be deprecated and removed from the spec either.
elf Pavlik
@elf-pavlik
@michielbdejong can you point me to your ACL in JSON-LD files? I can take a look at how you use JSON-LD @context
Mitzi László
@Mitzi-Laszlo
@/all Let me know if you would like to join the team working on Solid Content Generation. Last week when I asked about hurdles faced to building on Solid, over half of the answers stated were related to lack of information. The aim of this project is to generate the content suggestions to provide more information about Solid to reduce the hurdles to building on Solid. If you have ideas about content needed or preferred delivery methods please let me know on https://github.com/orgs/solid/projects/6
jaxoncreed
@jaxoncreed
I’d love to join!
Jeff Zucker
@jeff-zucker
@theWebalyst a non-expert tip from a fellow poker and prodder - sometimes the order of the requires or script tags is significant ...
Mark Hughes (happybeing)
@theWebalyst
Thanks Jeff, a good point.
Update regarding the cyclic dependency issue ^^ - I tried local paths in package.json but that didn't help. In fact I notice this creates symbolic links so I'm not sure it is any different than npm link / yarn link.
I have though thought of a workaround that achieves my aim without being to much of a cludge, so am partway through trying that.
Mark Hughes (happybeing)
@theWebalyst
Thanks everyone who chipped in with thoughts, comments and suggestions. It all helps. I've learned several things, and it's good to share the issue and get supportive feedback. :smile:
Ghost
@ghost~57bc59d440f3a6eec060e93b
@Mitzi-Laszlo is there any resources that explore the opportunities and challenges with respect to ‘data harmonisation’
Ghost
@ghost~57bc59d440f3a6eec060e93b

@tjhorton note: https://www.webizen.net.au/about/executive-summary/knowledge-banking-legal-structures/

noting also, imho, there are an array of complex issues that relate to such considerations whilst hoping the link with some of my thoughts is helpful

Raúl R Pearson
@raulrpearson
@Mitzi-Laszlo, I'd like to help out with the solid content generation effort
lin onetwo
@linonetwo
How to escape illegal characters in the filename?
https://forum.solidproject.org/t/how-to-store-file-with-in-its-name/1816
Mitzi László
@Mitzi-Laszlo
@raulrpearson @jaxoncreed great to have you on board the Solid content generation project!
Mitzi László
@Mitzi-Laszlo
Matthias Evering
@ewingson
@Mitzi-Laszlo this gives a 404
Mark Hughes (happybeing)
@theWebalyst

Follow up question (BTW I now have something building, not tested tho) regarding node modules...

If I'm bundling a module using webpack (solid-auth-client in this case), and it depends on another module (safenetworkjs) that supports both nodejs and webified operation, one way to handle this is with conditional requires. rdflib.js does this in fetcher.js for example.

That works, but in a dependent module you end up with a web build looking for modules that are not needed or available for web which leads to 'module not found' errors for things like 'fs' that are built ins for nodejs and so not installed in node_modules.

One way to solve this is to mark those 'missing' modules as 'externals' in the dependent module's webpack.config.js, but I would prefer it if I could do this without touching the dependent module, for example by avoiding conditional requires in the dependency module.

In safentworkjs I was doing this by having a different entry point index-web.js which allows me to build a bundle that only has what it needs. However, when I build a module that depends on safenetworkjs, it picks up index.js and if bundling for web, it will complain and I'll have to go and modify its webpack.config.js.

So TLDR; is there a way for a dependent module to be built for web (webpacked) in a way that picks up the web version of a dependency which has both web and nodejs builds. I wondered if putting the bundle in a './browser' directory was the answer, but it seems not.

Mitzi László
@Mitzi-Laszlo
Ah then the board must only be visible to team members. You can share your ideas here too and I’ll make sure to include them.
The end results will be in the solid/information repo so you can keep an eye on that
Matthias Evering
@ewingson
@Mitzi-Laszlo I hope for now providing the 5.0.1 is sufficient I begin trying to develop using rdflib and will keep my eyes on the things to do deviding in short period / long run
Matthias Evering
@ewingson
is there work going on concerning a)providers b)how-to for debian ?
Mitzi László
@Mitzi-Laszlo
yes, there is the start of content around both identity providers and pod providers that can be found on https://github.com/solid/information#building-on-solid